1 diff -Nur shadow-4.1.4.2_orig/libmisc/find_new_gid.c shadow-4.1.4.2/libmisc/find_new_gid.c
2 --- shadow-4.1.4.2_orig/libmisc/find_new_gid.c 2009-07-17 23:53:42.000000000 +0000
3 +++ shadow-4.1.4.2/libmisc/find_new_gid.c 2009-08-03 18:16:37.000000000 +0000
8 - gid_min = (gid_t) getdef_ulong ("GID_MIN", 1000UL);
9 + gid_min = (gid_t) getdef_ulong ("GID_MIN", 500UL);
10 gid_max = (gid_t) getdef_ulong ("GID_MAX", 60000UL);
12 gid_min = (gid_t) getdef_ulong ("SYS_GID_MIN", 101UL);
13 - gid_max = (gid_t) getdef_ulong ("GID_MIN", 1000UL) - 1;
14 + gid_max = (gid_t) getdef_ulong ("GID_MIN", 500UL) - 1;
15 gid_max = (gid_t) getdef_ulong ("SYS_GID_MAX", (unsigned long) gid_max);
17 used_gids = alloca (sizeof (bool) * (gid_max +1));
18 diff -Nur shadow-4.1.4.2_orig/libmisc/find_new_uid.c shadow-4.1.4.2/libmisc/find_new_uid.c
19 --- shadow-4.1.4.2_orig/libmisc/find_new_uid.c 2009-07-17 23:53:43.000000000 +0000
20 +++ shadow-4.1.4.2/libmisc/find_new_uid.c 2009-08-03 18:17:20.000000000 +0000
25 - uid_min = (uid_t) getdef_ulong ("UID_MIN", 1000UL);
26 + uid_min = (uid_t) getdef_ulong ("UID_MIN", 500UL);
27 uid_max = (uid_t) getdef_ulong ("UID_MAX", 60000UL);
29 uid_min = (uid_t) getdef_ulong ("SYS_UID_MIN", 101UL);
30 - uid_max = (uid_t) getdef_ulong ("UID_MIN", 1000UL) - 1;
31 + uid_max = (uid_t) getdef_ulong ("UID_MIN", 500UL) - 1;
32 uid_max = (uid_t) getdef_ulong ("SYS_UID_MAX", (unsigned long) uid_max);
34 used_uids = alloca (sizeof (bool) * (uid_max +1));
35 diff -Nur shadow-4.1.4.2_orig/src/useradd.c shadow-4.1.4.2/src/useradd.c
36 --- shadow-4.1.4.2_orig/src/useradd.c 2009-06-05 22:16:58.000000000 +0000
37 +++ shadow-4.1.4.2/src/useradd.c 2009-08-03 18:26:31.000000000 +0000
39 static gid_t def_group = 100;
40 static const char *def_gname = "other";
41 static const char *def_home = "/home";
42 -static const char *def_shell = "";
43 +static const char *def_shell = "/sbin/nologin";
44 static const char *def_template = SKEL_DIR;
45 static const char *def_create_mail_spool = "no";
48 #define VALID(s) (strcspn (s, ":\n") == strlen (s))
50 static const char *user_name = "";
51 -static const char *user_pass = "!";
52 +static const char *user_pass = "!!";
54 static gid_t user_gid;
55 static const char *user_comment = "";
58 while ((c = getopt_long (argc, argv,
60 - "b:c:d:De:f:g:G:k:K:lmMNop:rs:u:UZ:",
61 + "b:c:d:De:f:g:G:k:K:lmMnNop:rs:u:UZ:",
63 - "b:c:d:De:f:g:G:k:K:lmMNop:rs:u:U",
64 + "b:c:d:De:f:g:G:k:K:lmMnNop:rs:u:U",
66 long_options, NULL)) != -1) {