2006-10-04 23:05:48 +03:00
|
|
|
#!/bin/sh /etc/rc.common
|
2006-06-27 03:36:13 +03:00
|
|
|
# Copyright (C) 2006 OpenWrt.org
|
2007-05-10 13:38:53 +03:00
|
|
|
START=50
|
2006-06-27 03:36:13 +03:00
|
|
|
|
2006-10-04 23:05:48 +03:00
|
|
|
start() {
|
2007-01-08 23:31:29 +02:00
|
|
|
if [ \! -f /etc/passwd ] || \
|
|
|
|
awk -F: '/^root:/ && ($2 != "") && ($2 !~ /\!/) {exit 1}' /etc/passwd 2>/dev/null || \
|
2008-08-09 12:50:12 +03:00
|
|
|
( [ \! -x /usr/sbin/dropbear ] && [ \! -x /usr/sbin/sshd ] )
|
2007-01-08 23:31:29 +02:00
|
|
|
then \
|
2009-04-04 12:35:55 +03:00
|
|
|
telnetd -l /bin/login.sh
|
2007-01-08 23:31:29 +02:00
|
|
|
fi
|
2006-10-04 23:05:48 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
stop() {
|
|
|
|
killall telnetd
|
|
|
|
}
|