diff options
author | John Crispin <blogic@openwrt.org> | 2009-10-08 18:58:15 +0000 |
---|---|---|
committer | John Crispin <blogic@openwrt.org> | 2009-10-08 18:58:15 +0000 |
commit | 6ca9f5f2d7721ab48f7e245a72b0b8f381f8dc7e (patch) | |
tree | bcf6bcfaf4f6da3d2cfc702e4459869487572ca6 /package/dropbear | |
parent | 981db40f8f8bc18c43a0f81adfbaad69b31e334b (diff) | |
download | master-187ad058-6ca9f5f2d7721ab48f7e245a72b0b8f381f8dc7e.tar.gz master-187ad058-6ca9f5f2d7721ab48f7e245a72b0b8f381f8dc7e.tar.bz2 master-187ad058-6ca9f5f2d7721ab48f7e245a72b0b8f381f8dc7e.zip |
#4985 - fixes dropbear banner file, thanks Roman Yepishev
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@18009 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/dropbear')
-rw-r--r-- | package/dropbear/files/dropbear.config | 1 | ||||
-rwxr-xr-x | package/dropbear/files/dropbear.init | 6 |
2 files changed, 6 insertions, 1 deletions
diff --git a/package/dropbear/files/dropbear.config b/package/dropbear/files/dropbear.config index e660ac7356..492d2a1742 100644 --- a/package/dropbear/files/dropbear.config +++ b/package/dropbear/files/dropbear.config @@ -1,3 +1,4 @@ config dropbear option PasswordAuth 'on' option Port '22' +# option BannerFile '/etc/banner' diff --git a/package/dropbear/files/dropbear.init b/package/dropbear/files/dropbear.init index c91d0a7166..30cb44b1b1 100755 --- a/package/dropbear/files/dropbear.init +++ b/package/dropbear/files/dropbear.init @@ -34,10 +34,14 @@ dropbear_start() # B) listen port local port config_get port "${section}" Port + # C) banner file + local bannerfile + config_get bannerfile ${section} BannerFile + [ -f $bannerfile ] || bannerfile='' # concatenate parameters local args - args="${nopasswd:+-s }${port:+-p ${port}} -P /var/run/${NAME}.${PIDCOUNT}.pid" + args="${nopasswd:+-s }${port:+-p ${port} }${bannerfile:+-b $bannerfile }-P /var/run/${NAME}.${PIDCOUNT}.pid" # execute program and return its exit code [ "${verbosed}" -ne 0 ] && echo "${initscript}: section ${section} starting ${PROG} ${args}" |