bb23691954958944974d09d2264a8de5e1aaee68
[openwrt/svn-archive/archive.git] / openwrt / package / openssh / files / S50sshd
1 #!/bin/sh
2
3 for type in rsa dsa; do {
4 # check for keys
5 key=/etc/ssh/ssh_${type}_host_key
6 [ ! -f $key ] && {
7 # generate missing keys
8 [ -x /usr/bin/ssh-keygen ] && {
9 /usr/bin/ssh-keygen -N '' -t $type -f $key 2>&- >&- && exec $0 $*
10 } &
11 exit 0
12 }
13 }; done
14
15 /usr/sbin/sshd