diff --git a/module/ssh.module.sh b/module/ssh.module.sh index e0d4cfa..f6dd11f 100755 --- a/module/ssh.module.sh +++ b/module/ssh.module.sh @@ -11,7 +11,7 @@ source /cis/core/base.module.sh # There are limitations of characters which are allowed to build the command. So try to express the task in a simple way. function ssh.onHostRun() { local _REMOTE_HOST _COMMAND - base.set _REMOTE_HOST "${1:?"FQDN of server missing: e.g. host.example.net[:port]"}" '^([a-zA-Z0-9][a-zA-Z0-9@.-]*)+(:[0-9]+)?$' + base.set _REMOTE_HOST "${1:?"FQDN of server missing: e.g. host.example.net[:port]"}" "${REGEX[SSH_ADDRESS]}" base.set _COMMAND "${2:?"COMMAND missing"}" "${REGEX[COMMAND]}" local _REMOTE_USER _REMOTE_HOSTNAME_FQDN _REMOTE_PORT _SOCKET