summaryrefslogtreecommitdiffstats
path: root/adduser/adduser.sh
diff options
context:
space:
mode:
authorMike Makonnen <mtm@FreeBSD.org>2004-08-28 14:32:10 +0000
committerMike Makonnen <mtm@FreeBSD.org>2004-08-28 14:32:10 +0000
commit2058b1bd835f65e05f7a007ce764bc32fb388c04 (patch)
tree9dcc05007710a5b476add81c0a96999bc60d04e4 /adduser/adduser.sh
parent4549965523e2dd89ffd90c383df858779b170913 (diff)
downloadpw-darwin-2058b1bd835f65e05f7a007ce764bc32fb388c04.tar.gz
pw-darwin-2058b1bd835f65e05f7a007ce764bc32fb388c04.tar.zst
pw-darwin-2058b1bd835f65e05f7a007ce764bc32fb388c04.zip
Also, match the full path to the special nologin shell.
Previously, it would recognize it as a valid shell only if the basename (nologin) was specified. Now, it will recognize both the basename and the full path. NOTE: The full path as adduser(8) understands it is /usr/sbin/nologin. There is a symlink, /sbin/nologin, but that's deprecated and only there for backwards compatibility.
Diffstat (limited to 'adduser/adduser.sh')
-rw-r--r--adduser/adduser.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/adduser/adduser.sh b/adduser/adduser.sh
index 7e21cb5..050f2b1 100644
--- a/adduser/adduser.sh
+++ b/adduser/adduser.sh
@@ -142,7 +142,8 @@ fullpath_from_shell() {
done
# /usr/sbin/nologin is a special case
- if [ "$_shell" = "${NOLOGIN}" ]; then
+ if [ "$_shell" = "${NOLOGIN}" -o \
+ "$_shell" = "${NOLOGIN_PATH}" ]; then
echo ${NOLOGIN_PATH}
return 0;
fi