blob: 040db3b82ffbbbed899723f9d5f646f555c7aa79 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
From b99ef11a68832b2141926c229dd25ea600107ed1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=B6ren=20Tempel?= <soeren+git@soeren-tempel.net>
Date: Sun, 13 Jan 2019 19:07:16 +0100
Subject: [PATCH] adduser: default to /sbin/nologin as shell for system
accounts
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
loginutils/adduser.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/loginutils/adduser.c b/loginutils/adduser.c
index d3c795afa..7ce29fa04 100644
--- a/loginutils/adduser.c
+++ b/loginutils/adduser.c
@@ -235,7 +235,7 @@ int adduser_main(int argc UNUSED_PARAM, char **argv)
usegroup = "nogroup";
}
if (!(opts & OPT_SHELL)) {
- pw.pw_shell = (char *) "/bin/false";
+ pw.pw_shell = (char *) "/sbin/nologin";
}
}
pw.pw_gid = usegroup ? xgroup2gid(usegroup) : -1; /* exits on failure */
|