shadow-utils/shadow-4.6-redhat.patch

42 lines
1.5 KiB
Diff
Raw Normal View History

2018-05-28 13:25:08 +00:00
diff -up shadow-4.6/src/useradd.c.redhat shadow-4.6/src/useradd.c
--- shadow-4.6/src/useradd.c.redhat 2018-04-29 18:42:37.000000000 +0200
+++ shadow-4.6/src/useradd.c 2018-05-28 13:37:16.695651258 +0200
@@ -98,7 +98,7 @@ const char *Prog;
2012-03-20 16:39:28 +00:00
static gid_t def_group = 100;
static const char *def_gname = "other";
static const char *def_home = "/home";
-static const char *def_shell = "";
+static const char *def_shell = "/sbin/nologin";
static const char *def_template = SKEL_DIR;
static const char *def_create_mail_spool = "no";
@@ -108,7 +108,7 @@ static const char *def_expire = "";
2012-03-20 16:39:28 +00:00
#define VALID(s) (strcspn (s, ":\n") == strlen (s))
static const char *user_name = "";
-static const char *user_pass = "!";
+static const char *user_pass = "!!";
static uid_t user_id;
static gid_t user_gid;
static const char *user_comment = "";
2018-05-28 13:25:08 +00:00
@@ -1114,9 +1114,9 @@ static void process_flags (int argc, cha
2012-03-20 16:39:28 +00:00
};
while ((c = getopt_long (argc, argv,
#ifdef WITH_SELINUX
2018-05-28 13:25:08 +00:00
- "b:c:d:De:f:g:G:hk:K:lmMNop:rR:P:s:u:UZ:",
+ "b:c:d:De:f:g:G:hk:K:lmMnNop:rR:P:s:u:UZ:",
2012-03-20 16:39:28 +00:00
#else /* !WITH_SELINUX */
2018-05-28 13:25:08 +00:00
- "b:c:d:De:f:g:G:hk:K:lmMNop:rR:P:s:u:U",
+ "b:c:d:De:f:g:G:hk:K:lmMnNop:rR:P:s:u:U",
2012-03-20 16:39:28 +00:00
#endif /* !WITH_SELINUX */
long_options, NULL)) != -1) {
switch (c) {
2018-05-28 13:25:08 +00:00
@@ -1267,6 +1267,7 @@ static void process_flags (int argc, cha
2012-03-20 16:39:28 +00:00
case 'M':
Mflg = true;
break;
+ case 'n':
case 'N':
Nflg = true;
break;