summaryrefslogtreecommitdiff
path: root/templates/service/ssh/node.def
diff options
context:
space:
mode:
Diffstat (limited to 'templates/service/ssh/node.def')
-rw-r--r--templates/service/ssh/node.def10
1 files changed, 2 insertions, 8 deletions
diff --git a/templates/service/ssh/node.def b/templates/service/ssh/node.def
index 55f94551..7117a2fd 100644
--- a/templates/service/ssh/node.def
+++ b/templates/service/ssh/node.def
@@ -2,13 +2,7 @@ priority: 500 # After syslog and logins
help: Secure SHell (SSH) protocol
delete:sudo /usr/sbin/invoke-rc.d ssh stop
sudo sh -c "echo 'SSHD_OPTS=' > /etc/default/ssh"
-end: if [ -z "$VAR(port/@)" ]; then exit 0; fi;
- case $VAR(protocol-version/@) in
- v2) VER=2;;
- v1) VER=1;;
- all) VER="1,2";;
- *) VER=2;;
- esac;
- STR="SSHD_OPTS=\"-p $VAR(port/@) -o Protocol=${VER}\""
+end: if [ -z "$VAR(port/@)" ]; then exit 0; fi
+ STR="SSHD_OPTS=\"-p $VAR(port/@)\""
sudo sh -c "echo '$STR' > /etc/default/ssh"
sudo /usr/sbin/invoke-rc.d ssh restart