aboutsummaryrefslogtreecommitdiffstats
path: root/package/base-files/files/bin/login.sh
blob: ff5d3660e40df8608032d7c6a2e05f8f7adca69f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh
# Copyright (C) 2006 OpenWrt.org

grep '^root:[^!]' /etc/passwd >&- 2>&-
[ "$?" = "0" -a -z "$FAILSAFE" ]  &&  
{
    echo "Login failed."
    exit 0
} || {
cat << EOF
 === IMPORTANT ============================
  Use 'passwd' to set your login password
  this will disable telnet and enable SSH
 ------------------------------------------
EOF
}

exec /bin/ash --login