cleanup & fix logic not to depend on dropbearkey if keys exist
[openwrt.git] / openwrt / package / dropbear / files / S50dropbear
1 #!/bin/sh
2
3 for type in rsa dss; do {
4 # check for keys
5 key=/tmp/dropbear/dropbear_${type}_host_key
6 [ ! -f $key ] && {
7 # generate missing keys
8 mkdir -p /tmp/dropbear
9 [ -x /usr/bin/dropbearkey ] && {
10 /usr/bin/dropbearkey -t $type -f $key 2>&- >&- && exec $0 $*
11 } &
12 exit 0
13 }
14 }; done
15
16 umask 077
17 /usr/sbin/dropbear
This page took 0.04069 seconds and 5 git commands to generate.