#! /bin/sh
#
# Copyright (c) 1998 Florian La Roche
#
# use "ssh-keygen -b 1024 -f /etc/ssh_host_key -N ''" to configure sshd
#

PIDFILE=/var/run/sshd.pid

case "$1" in
    start)	echo "Starting ssh daemon."
		/usr/sbin/sshd
		;;
    stop)	if test -f $PIDFILE ; then
			echo "Shutting down ssh daemon."
			killall -TERM -p`cat $PIDFILE` /usr/sbin/sshd
		fi
		;;
    reload)	if test -f $PIDFILE ; then
			killall -HUP  -p`cat $PIDFILE` /usr/sbin/sshd
		fi
		;;
     *)		echo "Usage: $0 {start|stop}"
		exit 1
esac

exit 0
