]> git.ipfire.org Git - people/ms/ipfire-3.x.git/blob - shadow-utils/patches/shadow-4.1.4.2-ipfire.patch
glibc: Update to 2.20
[people/ms/ipfire-3.x.git] / shadow-utils / patches / shadow-4.1.4.2-ipfire.patch
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
4 @@ -58,11 +58,11 @@
5 assert (gid != NULL);
6
7 if (!sys_group) {
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);
11 } else {
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);
16 }
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
21 @@ -58,11 +58,11 @@
22 assert (uid != NULL);
23
24 if (!sys_user) {
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);
28 } else {
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);
33 }
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
38 @@ -90,7 +90,7 @@
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";
46
47 @@ -102,7 +102,7 @@
48 #define VALID(s) (strcspn (s, ":\n") == strlen (s))
49
50 static const char *user_name = "";
51 -static const char *user_pass = "!";
52 +static const char *user_pass = "!!";
53 static uid_t user_id;
54 static gid_t user_gid;
55 static const char *user_comment = "";
56 @@ -989,9 +989,9 @@
57 };
58 while ((c = getopt_long (argc, argv,
59 #ifdef WITH_SELINUX
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:",
62 #else
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",
65 #endif
66 long_options, NULL)) != -1) {
67 switch (c) {
68 @@ -1141,6 +1141,7 @@
69 case 'M':
70 Mflg = true;
71 break;
72 + case 'n':
73 case 'N':
74 Nflg = true;
75 break;