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