From d6662ec62f42f9f9a61b7cd641a420cf01dbb36d Mon Sep 17 00:00:00 2001 From: jwise Date: Tue, 1 Aug 2000 14:28:32 +0000 Subject: [PATCH] Change name of precmd from start_precmd to sshd_precmd. While it worked fine as was, the result was the line `start_precmd=start_precmd' which looked odd. Pointed out by Bernd Ernesti. While here, add NetBSD RCS Id. BTW, to clarify, as people have asked: this script does not support pkgsrc/security/sshd -- that package comes with a perfectly fine rc script which in addition to supporting /etc/rc.d can also be used with 1.4.X. This script will not trivially work with the ssh package as it a.) calls the ssh commands at the pathnames they will be installed at by usr.bin/ssh, and b.) generates a DSA key as well as an RSA key. --- etc/rc.d/sshd | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/etc/rc.d/sshd b/etc/rc.d/sshd index cb1e1f55ad55..bd2e4a846e45 100755 --- a/etc/rc.d/sshd +++ b/etc/rc.d/sshd @@ -1,5 +1,7 @@ #!/bin/sh # +# $NetBSD: sshd,v 1.5 2000/08/01 14:28:32 jwise Exp $ +# # PROVIDE: ssh # REQUIRE: NETWORK @@ -32,7 +34,7 @@ sshd_keygen() { fi } -start_precmd() { +sshd_precmd() { if [ ! -f /etc/ssh_host_key -o ! -f /etc/ssh_host_dsa_key ] then /etc/rc.d/sshd keygen @@ -40,7 +42,7 @@ start_precmd() { } keygen_cmd=sshd_keygen -start_precmd=start_precmd +start_precmd=sshd_precmd load_rc_config $name run_rc_command "$1"