summaryrefslogtreecommitdiffstats
path: root/package/openssh/files/S50sshd
blob: f1bc83366dc49f53f4040007ef28b16c58b6b02d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh

for type in rsa dsa; do {
  # check for keys
  key=/etc/ssh/ssh_host_${type}_key
  [ ! -f $key ] && {
    # generate missing keys
    [ -x /usr/bin/ssh-keygen ] && {
      /usr/bin/ssh-keygen -N '' -t $type -f $key 2>&- >&- && exec $0 $*
    } &
    exit 0
  }
}; done
mkdir -p /var/emtpy
/usr/sbin/sshd