upgrade
This commit is contained in:
parent
f59529bd69
commit
79c2e98279
8 changed files with 117 additions and 157 deletions
|
@ -1,3 +1,4 @@
|
||||||
shadow-4.0.17-login.defs
|
shadow-4.0.17-login.defs
|
||||||
shadow-4.0.18.1-useradd
|
shadow-4.0.18.1-useradd
|
||||||
shadow-4.1.1.tar.bz2
|
shadow-4.1.1.tar.bz2
|
||||||
|
shadow-4.1.2.tar.bz2
|
||||||
|
|
|
@ -1,26 +0,0 @@
|
||||||
diff -up shadow-4.1.1/src/newgrp.c.audit shadow-4.1.1/src/newgrp.c
|
|
||||||
--- shadow-4.1.1/src/newgrp.c.audit 2008-04-03 15:20:25.000000000 +0200
|
|
||||||
+++ shadow-4.1.1/src/newgrp.c 2008-04-03 15:22:00.000000000 +0200
|
|
||||||
@@ -53,6 +53,10 @@ static GETGROUPS_T *grouplist;
|
|
||||||
static char *Prog;
|
|
||||||
static int is_newgrp;
|
|
||||||
|
|
||||||
+#ifdef WITH_AUDIT
|
|
||||||
+ char audit_buf[80];
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
/* local function prototypes */
|
|
||||||
static void usage (void);
|
|
||||||
static void check_perms (const struct group *grp,
|
|
||||||
@@ -349,10 +353,9 @@ int main (int argc, char **argv)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef WITH_AUDIT
|
|
||||||
- char audit_buf[80];
|
|
||||||
-
|
|
||||||
audit_help_open ();
|
|
||||||
#endif
|
|
||||||
+
|
|
||||||
setlocale (LC_ALL, "");
|
|
||||||
bindtextdomain (PACKAGE, LOCALEDIR);
|
|
||||||
textdomain (PACKAGE);
|
|
|
@ -1,17 +0,0 @@
|
||||||
diff -up shadow-4.1.1/libmisc/salt.c.saltSize shadow-4.1.1/libmisc/salt.c
|
|
||||||
--- shadow-4.1.1/libmisc/salt.c.saltSize 2008-05-20 13:36:06.000000000 +0200
|
|
||||||
+++ shadow-4.1.1/libmisc/salt.c 2008-05-20 13:39:30.000000000 +0200
|
|
||||||
@@ -90,9 +90,10 @@ static void seedRNG (void)
|
|
||||||
*/
|
|
||||||
static unsigned int SHA_salt_size (void)
|
|
||||||
{
|
|
||||||
- double rand_rounds = 9 * random ();
|
|
||||||
- rand_rounds /= RAND_MAX;
|
|
||||||
- return 8 + rand_rounds;
|
|
||||||
+ unsigned int rand_rounds;
|
|
||||||
+ seedRNG ();
|
|
||||||
+ rand_rounds = random () % 9;
|
|
||||||
+ return 8 + rand_rounds;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* ! Arguments evaluated twice ! */
|
|
|
@ -1,7 +1,7 @@
|
||||||
diff -up shadow-4.1.0/libmisc/chkname.c.goodname shadow-4.1.0/libmisc/chkname.c
|
diff -up shadow-4.1.2/libmisc/chkname.c.goodname shadow-4.1.2/libmisc/chkname.c
|
||||||
--- shadow-4.1.0/libmisc/chkname.c.goodname 2007-11-11 00:45:59.000000000 +0100
|
--- shadow-4.1.2/libmisc/chkname.c.goodname 2008-04-27 02:40:13.000000000 +0200
|
||||||
+++ shadow-4.1.0/libmisc/chkname.c 2007-12-12 13:57:20.000000000 +0100
|
+++ shadow-4.1.2/libmisc/chkname.c 2008-05-26 14:37:09.000000000 +0200
|
||||||
@@ -18,16 +18,24 @@
|
@@ -50,16 +50,24 @@
|
||||||
static int good_name (const char *name)
|
static int good_name (const char *name)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
|
@ -33,7 +33,7 @@ diff -up shadow-4.1.0/libmisc/chkname.c.goodname shadow-4.1.0/libmisc/chkname.c
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -43,10 +51,9 @@ int check_user_name (const char *name)
|
@@ -75,10 +83,9 @@ int check_user_name (const char *name)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -46,7 +46,7 @@ diff -up shadow-4.1.0/libmisc/chkname.c.goodname shadow-4.1.0/libmisc/chkname.c
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
return good_name (name);
|
return good_name (name);
|
||||||
@@ -54,11 +61,13 @@ int check_user_name (const char *name)
|
@@ -86,11 +93,13 @@ int check_user_name (const char *name)
|
||||||
|
|
||||||
int check_group_name (const char *name)
|
int check_group_name (const char *name)
|
||||||
{
|
{
|
||||||
|
@ -65,29 +65,29 @@ diff -up shadow-4.1.0/libmisc/chkname.c.goodname shadow-4.1.0/libmisc/chkname.c
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
return good_name (name);
|
return good_name (name);
|
||||||
diff -up shadow-4.1.0/man/groupadd.8.goodname shadow-4.1.0/man/groupadd.8
|
diff -up shadow-4.1.2/man/groupadd.8.goodname shadow-4.1.2/man/groupadd.8
|
||||||
--- shadow-4.1.0/man/groupadd.8.goodname 2007-12-12 13:51:43.000000000 +0100
|
--- shadow-4.1.2/man/groupadd.8.goodname 2008-05-26 14:37:09.000000000 +0200
|
||||||
+++ shadow-4.1.0/man/groupadd.8 2007-12-12 14:00:29.000000000 +0100
|
+++ shadow-4.1.2/man/groupadd.8 2008-05-26 14:40:51.000000000 +0200
|
||||||
@@ -126,9 +126,7 @@ Shadow password suite configuration\.
|
@@ -150,9 +150,7 @@ Shadow password suite configuration\&.
|
||||||
.RE
|
.RE
|
||||||
.SH "CAVEATS"
|
.SH "CAVEATS"
|
||||||
.PP
|
.PP
|
||||||
-Groupnames must begin with a lower case letter or an underscore, and only lower case letters, underscores, dashes, and dollar signs may follow\. In regular expression terms: [a\-z_][a\-z0\-9_\-]*[$]
|
-Groupnames must begin with a lower case letter or an underscore, and only lower case letters, underscores, dashes, and dollar signs may follow\&. In regular expression terms: [a\-z_][a\-z0\-9_\-]*[$]
|
||||||
-.PP
|
-.PP
|
||||||
-Groupnames may only be up to 16 characters long\.
|
-Groupnames may only be up to 16 characters long\&.
|
||||||
+Groupnames may only be up to 32 characters long\.
|
+Groupnames may only be up to 32 characters long\&.
|
||||||
.PP
|
.PP
|
||||||
You may not add a NIS or LDAP group\. This must be performed on the corresponding server\.
|
You may not add a NIS or LDAP group\&. This must be performed on the corresponding server\&.
|
||||||
.PP
|
.PP
|
||||||
diff -up shadow-4.1.0/man/useradd.8.goodname shadow-4.1.0/man/useradd.8
|
diff -up shadow-4.1.2/man/useradd.8.goodname shadow-4.1.2/man/useradd.8
|
||||||
--- shadow-4.1.0/man/useradd.8.goodname 2007-12-12 13:51:43.000000000 +0100
|
--- shadow-4.1.2/man/useradd.8.goodname 2008-05-26 14:37:09.000000000 +0200
|
||||||
+++ shadow-4.1.0/man/useradd.8 2007-12-12 14:01:36.000000000 +0100
|
+++ shadow-4.1.2/man/useradd.8 2008-05-26 14:41:48.000000000 +0200
|
||||||
@@ -242,8 +242,6 @@ You may not add a user to a NIS or LDAP
|
@@ -293,8 +293,6 @@ You may not add a user to a NIS or LDAP
|
||||||
Similarly, if the username already exists in an external user database such as NIS or LDAP,
|
Similarly, if the username already exists in an external user database such as NIS or LDAP,
|
||||||
\fBuseradd\fR
|
\fBuseradd\fR
|
||||||
will deny the user account creation request\.
|
will deny the user account creation request\&.
|
||||||
-.PP
|
-.PP
|
||||||
-Usernames must begin with a lower case letter or an underscore, and only lower case letters, underscores, dashes, and dollar signs may follow\. In regular expression terms: [a\-z_][a\-z0\-9_\-]*[$]
|
-Usernames must begin with a lower case letter or an underscore, and only lower case letters, underscores, dashes, and dollar signs may follow\&. In regular expression terms: [a\-z_][a\-z0\-9_\-]*[$]
|
||||||
.SH "CONFIGURATION"
|
.SH "CONFIGURATION"
|
||||||
.PP
|
.PP
|
||||||
The following configuration variables in
|
The following configuration variables in
|
|
@ -1,7 +1,7 @@
|
||||||
diff -up shadow-4.1.1/libmisc/find_new_ids.c.redhat shadow-4.1.1/libmisc/find_new_ids.c
|
diff -up shadow-4.1.2/libmisc/find_new_ids.c.redhat shadow-4.1.2/libmisc/find_new_ids.c
|
||||||
--- shadow-4.1.1/libmisc/find_new_ids.c.redhat 2008-04-03 12:18:51.000000000 +0200
|
--- shadow-4.1.2/libmisc/find_new_ids.c.redhat 2008-04-22 00:00:19.000000000 +0200
|
||||||
+++ shadow-4.1.1/libmisc/find_new_ids.c 2008-04-03 13:30:44.000000000 +0200
|
+++ shadow-4.1.2/libmisc/find_new_ids.c 2008-05-26 14:18:43.000000000 +0200
|
||||||
@@ -26,11 +26,11 @@ int find_new_uid (int sys_user, uid_t *u
|
@@ -56,11 +56,11 @@ int find_new_uid (int sys_user, uid_t *u
|
||||||
assert (uid != NULL);
|
assert (uid != NULL);
|
||||||
|
|
||||||
if (sys_user == 0) {
|
if (sys_user == 0) {
|
||||||
|
@ -15,7 +15,7 @@ diff -up shadow-4.1.1/libmisc/find_new_ids.c.redhat shadow-4.1.1/libmisc/find_ne
|
||||||
uid_max = getdef_unum ("SYS_UID_MAX", uid_max);
|
uid_max = getdef_unum ("SYS_UID_MAX", uid_max);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -108,11 +108,11 @@ int find_new_gid (int sys_group, gid_t *
|
@@ -139,11 +139,11 @@ int find_new_gid (int sys_group, gid_t *
|
||||||
assert (gid != NULL);
|
assert (gid != NULL);
|
||||||
|
|
||||||
if (sys_group == 0) {
|
if (sys_group == 0) {
|
||||||
|
@ -29,10 +29,10 @@ diff -up shadow-4.1.1/libmisc/find_new_ids.c.redhat shadow-4.1.1/libmisc/find_ne
|
||||||
gid_max = getdef_unum ("SYS_GID_MAX", gid_max);
|
gid_max = getdef_unum ("SYS_GID_MAX", gid_max);
|
||||||
}
|
}
|
||||||
|
|
||||||
diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
diff -up shadow-4.1.2/src/useradd.c.redhat shadow-4.1.2/src/useradd.c
|
||||||
--- shadow-4.1.1/src/useradd.c.redhat 2008-03-08 23:42:05.000000000 +0100
|
--- shadow-4.1.2/src/useradd.c.redhat 2008-05-19 22:31:52.000000000 +0200
|
||||||
+++ shadow-4.1.1/src/useradd.c 2008-04-03 14:07:32.000000000 +0200
|
+++ shadow-4.1.2/src/useradd.c 2008-05-26 14:18:43.000000000 +0200
|
||||||
@@ -82,7 +82,7 @@
|
@@ -85,7 +85,7 @@
|
||||||
static gid_t def_group = 100;
|
static gid_t def_group = 100;
|
||||||
static const char *def_gname = "other";
|
static const char *def_gname = "other";
|
||||||
static const char *def_home = "/home";
|
static const char *def_home = "/home";
|
||||||
|
@ -41,7 +41,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
static const char *def_template = SKEL_DIR;
|
static const char *def_template = SKEL_DIR;
|
||||||
static const char *def_create_mail_spool = "no";
|
static const char *def_create_mail_spool = "no";
|
||||||
|
|
||||||
@@ -94,7 +94,7 @@ static char def_file[] = USER_DEFAULTS_F
|
@@ -97,7 +97,7 @@ static char def_file[] = USER_DEFAULTS_F
|
||||||
#define VALID(s) (strcspn (s, ":\n") == strlen (s))
|
#define VALID(s) (strcspn (s, ":\n") == strlen (s))
|
||||||
|
|
||||||
static const char *user_name = "";
|
static const char *user_name = "";
|
||||||
|
@ -50,7 +50,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
static uid_t user_id;
|
static uid_t user_id;
|
||||||
static gid_t user_gid;
|
static gid_t user_gid;
|
||||||
static const char *user_comment = "";
|
static const char *user_comment = "";
|
||||||
@@ -130,6 +130,7 @@ static int
|
@@ -133,6 +133,7 @@ static int
|
||||||
kflg = 0, /* specify a directory to fill new user directory */
|
kflg = 0, /* specify a directory to fill new user directory */
|
||||||
lflg = 0, /* do not add user to lastlog database file */
|
lflg = 0, /* do not add user to lastlog database file */
|
||||||
mflg = 0, /* create user's home directory if it doesn't exist */
|
mflg = 0, /* create user's home directory if it doesn't exist */
|
||||||
|
@ -58,7 +58,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
Nflg = 0, /* do not create a group having the same name as the user, but add the user to def_group (or the group specified with -g) */
|
Nflg = 0, /* do not create a group having the same name as the user, but add the user to def_group (or the group specified with -g) */
|
||||||
oflg = 0, /* permit non-unique user ID to be specified with -u */
|
oflg = 0, /* permit non-unique user ID to be specified with -u */
|
||||||
rflg = 0, /* create a system account */
|
rflg = 0, /* create a system account */
|
||||||
@@ -653,6 +654,7 @@ static void usage (void)
|
@@ -656,6 +657,7 @@ static void usage (void)
|
||||||
" faillog databases\n"
|
" faillog databases\n"
|
||||||
" -m, --create-home create home directory for the new user\n"
|
" -m, --create-home create home directory for the new user\n"
|
||||||
" account\n"
|
" account\n"
|
||||||
|
@ -66,7 +66,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
" -N, --no-user-group do not create a group with the same name as\n"
|
" -N, --no-user-group do not create a group with the same name as\n"
|
||||||
" the user\n"
|
" the user\n"
|
||||||
" -o, --non-unique allow create user with duplicate\n"
|
" -o, --non-unique allow create user with duplicate\n"
|
||||||
@@ -883,7 +885,7 @@ static void process_flags (int argc, cha
|
@@ -886,7 +888,7 @@ static void process_flags (int argc, cha
|
||||||
{NULL, 0, NULL, '\0'}
|
{NULL, 0, NULL, '\0'}
|
||||||
};
|
};
|
||||||
while ((c =
|
while ((c =
|
||||||
|
@ -75,7 +75,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
long_options, NULL)) != -1) {
|
long_options, NULL)) != -1) {
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case 'b':
|
case 'b':
|
||||||
@@ -1023,6 +1025,10 @@ static void process_flags (int argc, cha
|
@@ -1026,6 +1028,10 @@ static void process_flags (int argc, cha
|
||||||
case 'm':
|
case 'm':
|
||||||
mflg++;
|
mflg++;
|
||||||
break;
|
break;
|
||||||
|
@ -86,7 +86,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
case 'N':
|
case 'N':
|
||||||
Nflg++;
|
Nflg++;
|
||||||
break;
|
break;
|
||||||
@@ -1076,6 +1082,9 @@ static void process_flags (int argc, cha
|
@@ -1079,6 +1085,9 @@ static void process_flags (int argc, cha
|
||||||
Uflg = getdef_bool ("USERGROUPS_ENAB");
|
Uflg = getdef_bool ("USERGROUPS_ENAB");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -96,7 +96,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
/*
|
/*
|
||||||
* Certain options are only valid in combination with others.
|
* Certain options are only valid in combination with others.
|
||||||
* Check it here so that they can be specified in any order.
|
* Check it here so that they can be specified in any order.
|
||||||
@@ -1625,6 +1634,14 @@ int main (int argc, char **argv)
|
@@ -1628,6 +1637,14 @@ int main (int argc, char **argv)
|
||||||
}
|
}
|
||||||
#endif /* USE_PAM */
|
#endif /* USE_PAM */
|
||||||
|
|
||||||
|
@ -111,7 +111,7 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
/*
|
/*
|
||||||
* See if we are messing with the defaults file, or creating
|
* See if we are messing with the defaults file, or creating
|
||||||
* a new user.
|
* a new user.
|
||||||
@@ -1724,27 +1741,22 @@ int main (int argc, char **argv)
|
@@ -1727,27 +1744,22 @@ int main (int argc, char **argv)
|
||||||
("%s: warning: the home directory already exists.\n"
|
("%s: warning: the home directory already exists.\n"
|
||||||
"Not copying any file from skel directory into it.\n"),
|
"Not copying any file from skel directory into it.\n"),
|
||||||
Prog);
|
Prog);
|
||||||
|
@ -154,33 +154,30 @@ diff -up shadow-4.1.1/src/useradd.c.redhat shadow-4.1.1/src/useradd.c
|
||||||
|
|
||||||
close_files ();
|
close_files ();
|
||||||
|
|
||||||
diff -up shadow-4.1.1/src/groupadd.c.redhat shadow-4.1.1/src/groupadd.c
|
diff -up shadow-4.1.2/man/useradd.8.redhat shadow-4.1.2/man/useradd.8
|
||||||
diff -up shadow-4.1.1/man/useradd.8.redhat shadow-4.1.1/man/useradd.8
|
--- shadow-4.1.2/man/useradd.8.redhat 2008-05-25 01:20:26.000000000 +0200
|
||||||
--- shadow-4.1.1/man/useradd.8.redhat 2008-04-03 00:43:14.000000000 +0200
|
+++ shadow-4.1.2/man/useradd.8 2008-05-26 14:26:14.000000000 +0200
|
||||||
+++ shadow-4.1.1/man/useradd.8 2008-04-03 14:20:23.000000000 +0200
|
@@ -27,7 +27,7 @@ option, the
|
||||||
@@ -25,9 +25,9 @@ When invoked without the
|
|
||||||
\fB\-D\fR
|
|
||||||
option, the
|
|
||||||
\fBuseradd\fR
|
\fBuseradd\fR
|
||||||
-command creates a new user account using the values specified on the command line plus the default values from the system\. Depending on command line options, the
|
command creates a new user account using the values specified on the command line plus the default values from the system\&. Depending on command line options, the
|
||||||
+command creates a new user account using the values specified on the command line and the default values from the system. Depending on command line options, the
|
|
||||||
\fBuseradd\fR
|
\fBuseradd\fR
|
||||||
-command will update system files and may also create the new user\'s home directory and copy initial files\.
|
-command will update system files and may also create the new user\'s home directory and copy initial files\&.
|
||||||
+command will update system files and may also create the new user's home directory and copy initial files. The version provided with Red Hat Linux will create a group for each user added to the system by default.
|
+command will update system files and may also create the new user\'s home directory and copy initial files\&. The version provided with Red Hat Linux will create a group for each user added to the system by default\&.
|
||||||
.SH "OPTIONS"
|
.SH "OPTIONS"
|
||||||
.PP
|
.PP
|
||||||
The options which apply to the
|
The options which apply to the
|
||||||
@@ -84,7 +84,7 @@ The number of days after a password expi
|
@@ -84,8 +84,7 @@ The number of days after a password expi
|
||||||
.PP
|
.PP
|
||||||
\fB\-g\fR, \fB\-\-gid\fR \fIGROUP\fR
|
\fB\-g\fR, \fB\-\-gid\fR \fIGROUP\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
-The group name or number of the user\'s initial login group\. The group name must exist\. A group number must refer to an already existing group\. The default group number is 1 or whatever is specified in
|
-The group name or number of the user\'s initial login group\&. The group name must exist\&. A group number must refer to an already existing group\&. The default group number is 1 or whatever is specified in
|
||||||
+The group name or number of the user\'s initial login group\. The group name must exist\. A group number must refer to an already existing group\.
|
-\fI/etc/default/useradd\fR\&.
|
||||||
\fI/etc/default/useradd\fR\.
|
+The group name or number of the user\'s initial login group\&. The group name must exist\&. A group number must refer to an already existing group\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
@@ -100,6 +100,13 @@ option\. The default is for the user to
|
\fB\-G\fR, \fB\-\-groups\fR \fIGROUP1\fR[\fI,GROUP2,\&.\&.\&.\fR[\fI,GROUPN\fR]]]
|
||||||
Display help message and exit\.
|
@@ -143,6 +142,13 @@ Do not add the user to the lastlog and f
|
||||||
|
By default, the user\'s entries in the lastlog and faillog databases are resetted to avoid reusing the entry from a previously deleted user\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
+\fB-M\fR
|
+\fB-M\fR
|
||||||
|
@ -192,9 +189,9 @@ diff -up shadow-4.1.1/man/useradd.8.redhat shadow-4.1.1/man/useradd.8
|
||||||
+.PP
|
+.PP
|
||||||
\fB\-m\fR, \fB\-\-create\-home\fR
|
\fB\-m\fR, \fB\-\-create\-home\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
The user\'s home directory will be created if it does not exist\. The files contained in
|
Create the user\'s home directory if it does not exist\&. The files and directories contained in the skeleton directory (which can be defined with the
|
||||||
@@ -174,6 +181,19 @@ The encrypted password, as returned by
|
@@ -195,6 +201,19 @@ range, defined in
|
||||||
\fBcrypt\fR(3)\. The default is to disable the account\.
|
counterparts for the creation of groups)\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
+\fB-r\fR
|
+\fB-r\fR
|
||||||
|
@ -212,18 +209,18 @@ diff -up shadow-4.1.1/man/useradd.8.redhat shadow-4.1.1/man/useradd.8
|
||||||
+.PP
|
+.PP
|
||||||
\fB\-s\fR, \fB\-\-shell\fR \fISHELL\fR
|
\fB\-s\fR, \fB\-\-shell\fR \fISHELL\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
The name of the user\'s login shell\. The default is to leave this field blank, which causes the system to select the default login shell\.
|
The name of the user\'s login shell\&. The default is to leave this field blank, which causes the system to select the default login shell\&.
|
||||||
@@ -244,6 +264,8 @@ The name of a new user\'s login shell\.
|
@@ -265,6 +284,8 @@ The name of a new user\'s login shell\&.
|
||||||
The system administrator is responsible for placing the default user files in the
|
The system administrator is responsible for placing the default user files in the
|
||||||
\fI/etc/skel/\fR
|
\fI/etc/skel/\fR
|
||||||
directory\.
|
directory\&.
|
||||||
+.br
|
+.br
|
||||||
+This version of useradd was modified by Red Hat to suit Red Hat user/group conventions\.
|
+This version of useradd was modified by Red Hat to suit Red Hat user/group conventions\&.
|
||||||
.SH "CAVEATS"
|
.SH "CAVEATS"
|
||||||
.PP
|
.PP
|
||||||
You may not add a user to a NIS or LDAP group\. This must be performed on the corresponding server\.
|
You may not add a user to a NIS or LDAP group\&. This must be performed on the corresponding server\&.
|
||||||
@@ -381,6 +403,11 @@ Secure user account information\.
|
@@ -407,6 +428,11 @@ Group account information\&.
|
||||||
Group account information\.
|
Secure group account information\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
+\fI/etc/gshadow\fR
|
+\fI/etc/gshadow\fR
|
||||||
|
@ -233,10 +230,10 @@ diff -up shadow-4.1.1/man/useradd.8.redhat shadow-4.1.1/man/useradd.8
|
||||||
+.PP
|
+.PP
|
||||||
\fI/etc/default/useradd\fR
|
\fI/etc/default/useradd\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
Default values for account creation\.
|
Default values for account creation\&.
|
||||||
diff -up shadow-4.1.1/man/groupadd.8.redhat shadow-4.1.1/man/groupadd.8
|
diff -up shadow-4.1.2/man/groupadd.8.redhat shadow-4.1.2/man/groupadd.8
|
||||||
--- shadow-4.1.1/man/groupadd.8.redhat 2008-04-03 00:42:54.000000000 +0200
|
--- shadow-4.1.2/man/groupadd.8.redhat 2008-05-25 01:20:05.000000000 +0200
|
||||||
+++ shadow-4.1.1/man/groupadd.8 2008-04-03 14:27:04.000000000 +0200
|
+++ shadow-4.1.2/man/groupadd.8 2008-05-26 14:35:49.000000000 +0200
|
||||||
@@ -14,7 +14,7 @@
|
@@ -14,7 +14,7 @@
|
||||||
groupadd \- create a new group
|
groupadd \- create a new group
|
||||||
.SH "SYNOPSIS"
|
.SH "SYNOPSIS"
|
||||||
|
@ -247,26 +244,26 @@ diff -up shadow-4.1.1/man/groupadd.8.redhat shadow-4.1.1/man/groupadd.8
|
||||||
.PP
|
.PP
|
||||||
The
|
The
|
||||||
@@ -34,11 +34,22 @@ This option causes the command to simply
|
@@ -34,11 +34,22 @@ This option causes the command to simply
|
||||||
is turned off)\.
|
is turned off)\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
+\fB-r\fR
|
+\fB-r\fR
|
||||||
+.RS 4
|
+.RS 4
|
||||||
+This flag instructs
|
+This flag instructs
|
||||||
+\fBgroupadd\fR
|
+\fBgroupadd\fR
|
||||||
+to add a system account\. The first available
|
+to add a system account\. The first available
|
||||||
+\fIgid\fR
|
+\fIgid\fR
|
||||||
+lower than 499 will be automatically selected unless the
|
+lower than 500 will be automatically selected unless the
|
||||||
+\fB-g\fR
|
+\fB-g\fR
|
||||||
+option is also given on the command line\. This is an option added by Red Hat\.
|
+option is also given on the command line\. This is an option added by Red Hat\.
|
||||||
+.RE
|
+.RE
|
||||||
+.PP
|
+.PP
|
||||||
\fB\-g\fR, \fB\-\-gid\fR \fIGID\fR
|
\fB\-g\fR, \fB\-\-gid\fR \fIGID\fR
|
||||||
.RS 4
|
.RS 4
|
||||||
The numerical value of the group\'s ID\. This value must be unique, unless the
|
The numerical value of the group\'s ID\&. This value must be unique, unless the
|
||||||
\fB\-o\fR
|
\fB\-o\fR
|
||||||
-option is used\. The value must be non\-negative\. The default is to use the smallest ID value greater than 999 and greater than every other group\. Values between 0 and 999 are typically reserved for system accounts\.
|
-option is used\&. The value must be non\-negative\&. The default is to use the smallest ID value greater than 999 and greater than every other group\&. Values between 0 and 999 are typically reserved for system accounts\&.
|
||||||
+option is used\. The value must be non\-negative\. The default is to use the smallest ID value greater than 499 and greater than every other group\. Values between 0 and 500 are typically reserved for system accounts\.
|
+option is used\&. The value must be non\-negative\&. The default is to use the smallest ID value greater than 499 and greater than every other group\&. Values between 0 and 500 are typically reserved for system accounts\&.
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
\fB\-h\fR, \fB\-\-help\fR
|
\fB\-h\fR, \fB\-\-help\fR
|
|
@ -1,7 +1,7 @@
|
||||||
diff -up shadow-4.1.1/libmisc/find_new_ids.c.sysAccountDownhill shadow-4.1.1/libmisc/find_new_ids.c
|
diff -up shadow-4.1.2/libmisc/find_new_ids.c.sysAccountDownhill shadow-4.1.2/libmisc/find_new_ids.c
|
||||||
--- shadow-4.1.1/libmisc/find_new_ids.c.sysAccountDownhill 2008-04-04 21:46:08.000000000 +0200
|
--- shadow-4.1.2/libmisc/find_new_ids.c.sysAccountDownhill 2008-05-26 14:52:49.000000000 +0200
|
||||||
+++ shadow-4.1.1/libmisc/find_new_ids.c 2008-04-04 21:50:04.000000000 +0200
|
+++ shadow-4.1.2/libmisc/find_new_ids.c 2008-05-26 14:58:55.000000000 +0200
|
||||||
@@ -22,6 +22,7 @@ int find_new_uid (int sys_user, uid_t *u
|
@@ -52,6 +52,7 @@ int find_new_uid (int sys_user, uid_t *u
|
||||||
{
|
{
|
||||||
const struct passwd *pwd;
|
const struct passwd *pwd;
|
||||||
uid_t uid_min, uid_max, user_id;
|
uid_t uid_min, uid_max, user_id;
|
||||||
|
@ -9,7 +9,7 @@ diff -up shadow-4.1.1/libmisc/find_new_ids.c.sysAccountDownhill shadow-4.1.1/lib
|
||||||
|
|
||||||
assert (uid != NULL);
|
assert (uid != NULL);
|
||||||
|
|
||||||
@@ -32,6 +33,8 @@ int find_new_uid (int sys_user, uid_t *u
|
@@ -62,6 +63,8 @@ int find_new_uid (int sys_user, uid_t *u
|
||||||
uid_min = getdef_unum ("SYS_UID_MIN", 1);
|
uid_min = getdef_unum ("SYS_UID_MIN", 1);
|
||||||
uid_max = getdef_unum ("UID_MIN", 500) - 1;
|
uid_max = getdef_unum ("UID_MIN", 500) - 1;
|
||||||
uid_max = getdef_unum ("SYS_UID_MAX", uid_max);
|
uid_max = getdef_unum ("SYS_UID_MAX", uid_max);
|
||||||
|
@ -18,7 +18,7 @@ diff -up shadow-4.1.1/libmisc/find_new_ids.c.sysAccountDownhill shadow-4.1.1/lib
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( (NULL != preferred_uid)
|
if ( (NULL != preferred_uid)
|
||||||
@@ -61,8 +64,24 @@ int find_new_uid (int sys_user, uid_t *u
|
@@ -91,12 +94,28 @@ int find_new_uid (int sys_user, uid_t *u
|
||||||
pw_rewind ();
|
pw_rewind ();
|
||||||
while ( ((pwd = getpwent ()) != NULL)
|
while ( ((pwd = getpwent ()) != NULL)
|
||||||
|| ((pwd = pw_next ()) != NULL)) {
|
|| ((pwd = pw_next ()) != NULL)) {
|
||||||
|
@ -33,19 +33,23 @@ diff -up shadow-4.1.1/libmisc/find_new_ids.c.sysAccountDownhill shadow-4.1.1/lib
|
||||||
+ /* create index of occupied system accounts UIDs */
|
+ /* create index of occupied system accounts UIDs */
|
||||||
+ if (pwd->pw_uid <= uid_max)
|
+ if (pwd->pw_uid <= uid_max)
|
||||||
+ index[pwd->pw_uid] = 1;
|
+ index[pwd->pw_uid] = 1;
|
||||||
+ }
|
}
|
||||||
+ }
|
}
|
||||||
+
|
endpwent ();
|
||||||
|
|
||||||
+ /* find free system account */
|
+ /* find free system account */
|
||||||
+ if(sys_user) {
|
+ if(sys_user) {
|
||||||
+ for( user_id = uid_max; (user_id >= uid_min) && index[user_id]; user_id--);
|
+ for( user_id = uid_max; (user_id >= uid_min) && index[user_id]; user_id--);
|
||||||
+ if ( user_id < uid_min ) {
|
+ if ( user_id < uid_min ) {
|
||||||
+ fputs (_("Can't get unique UID (no more available UIDs)\n"), stderr);
|
+ fputs (_("Can't get unique UID (no more available UIDs)\n"), stderr);
|
||||||
+ return -1;
|
+ return -1;
|
||||||
}
|
+ }
|
||||||
}
|
+ }
|
||||||
|
+
|
||||||
@@ -104,6 +123,7 @@ int find_new_gid (int sys_group, gid_t *
|
/*
|
||||||
|
* If a user with UID equal to UID_MAX exists, the above algorithm
|
||||||
|
* will give us UID_MAX+1 even if not unique. Search for the first
|
||||||
|
@@ -135,6 +154,7 @@ int find_new_gid (int sys_group, gid_t *
|
||||||
{
|
{
|
||||||
const struct group *grp;
|
const struct group *grp;
|
||||||
gid_t gid_min, gid_max, group_id;
|
gid_t gid_min, gid_max, group_id;
|
||||||
|
@ -53,7 +57,7 @@ diff -up shadow-4.1.1/libmisc/find_new_ids.c.sysAccountDownhill shadow-4.1.1/lib
|
||||||
|
|
||||||
assert (gid != NULL);
|
assert (gid != NULL);
|
||||||
|
|
||||||
@@ -114,6 +134,8 @@ int find_new_gid (int sys_group, gid_t *
|
@@ -145,6 +165,8 @@ int find_new_gid (int sys_group, gid_t *
|
||||||
gid_min = getdef_unum ("SYS_GID_MIN", 1);
|
gid_min = getdef_unum ("SYS_GID_MIN", 1);
|
||||||
gid_max = getdef_unum ("GID_MIN", 500) - 1;
|
gid_max = getdef_unum ("GID_MIN", 500) - 1;
|
||||||
gid_max = getdef_unum ("SYS_GID_MAX", gid_max);
|
gid_max = getdef_unum ("SYS_GID_MAX", gid_max);
|
||||||
|
@ -62,31 +66,32 @@ diff -up shadow-4.1.1/libmisc/find_new_ids.c.sysAccountDownhill shadow-4.1.1/lib
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( (NULL != preferred_gid)
|
if ( (NULL != preferred_gid)
|
||||||
@@ -142,11 +164,27 @@ int find_new_gid (int sys_group, gid_t *
|
@@ -173,12 +195,28 @@ int find_new_gid (int sys_group, gid_t *
|
||||||
gr_rewind ();
|
gr_rewind ();
|
||||||
while ( ((grp = getgrent ()) != NULL)
|
while ( ((grp = getgrent ()) != NULL)
|
||||||
|| ((grp = gr_next ()) != NULL)) {
|
|| ((grp = gr_next ()) != NULL)) {
|
||||||
- if ((grp->gr_gid >= group_id) && (grp->gr_gid <= gid_max)) {
|
- if ((grp->gr_gid >= group_id) && (grp->gr_gid <= gid_max)) {
|
||||||
- group_id = grp->gr_gid + 1;
|
- group_id = grp->gr_gid + 1;
|
||||||
+ if (sys_group == 0) {
|
+ if (sys_group == 0) {
|
||||||
+ if ((grp->gr_gid >= group_id) && (grp->gr_gid <= gid_max)) {
|
+ if ((grp->gr_gid >= group_id) && (grp->gr_gid <= gid_max)) {
|
||||||
+ group_id = grp->gr_gid + 1;
|
+ group_id = grp->gr_gid + 1;
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
+ else {
|
+ else {
|
||||||
+ /* create index of occupied system accounts GIDs */
|
+ /* create index of occupied system accounts GIDs */
|
||||||
+ if (grp->gr_gid <= gid_max)
|
+ if (grp->gr_gid <= gid_max)
|
||||||
+ index[grp->gr_gid] = 1;
|
+ index[grp->gr_gid] = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
endgrent ();
|
||||||
|
|
||||||
+ /* find free system account */
|
+ /* find free system account */
|
||||||
+ if(sys_group) {
|
+ if(sys_group) {
|
||||||
+ for( group_id = gid_max; (group_id >= gid_min) && index[group_id]; group_id--);
|
+ for( group_id = gid_max; (group_id >= gid_min) && index[group_id]; group_id--);
|
||||||
+ if ( group_id < gid_min ) {
|
+ if ( group_id < gid_min ) {
|
||||||
+ fputs (_("Can't get unique GID (no more available GIDs)\n"), stderr);
|
+ fputs (_("Can't get unique GID (no more available GIDs)\n"), stderr);
|
||||||
+ return -1;
|
+ return -1;
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
/*
|
/*
|
|
@ -4,20 +4,18 @@
|
||||||
|
|
||||||
Summary: Utilities for managing accounts and shadow password files
|
Summary: Utilities for managing accounts and shadow password files
|
||||||
Name: shadow-utils
|
Name: shadow-utils
|
||||||
Version: 4.1.1
|
Version: 4.1.2
|
||||||
Release: 2%{?dist}
|
Release: 1%{?dist}
|
||||||
Epoch: 2
|
Epoch: 2
|
||||||
URL: http://pkg-shadow.alioth.debian.org/
|
URL: http://pkg-shadow.alioth.debian.org/
|
||||||
Source0: ftp://pkg-shadow.alioth.debian.org/pub/pkg-shadow/shadow-%{version}.tar.bz2
|
Source0: ftp://pkg-shadow.alioth.debian.org/pub/pkg-shadow/shadow-%{version}.tar.bz2
|
||||||
Source1: shadow-4.0.17-login.defs
|
Source1: shadow-4.0.17-login.defs
|
||||||
Source2: shadow-4.0.18.1-useradd
|
Source2: shadow-4.0.18.1-useradd
|
||||||
|
|
||||||
Patch0: shadow-4.1.1-redhat.patch
|
Patch0: shadow-4.1.2-redhat.patch
|
||||||
Patch1: shadow-4.1.1-audit.patch
|
Patch1: shadow-4.1.2-goodname.patch
|
||||||
Patch3: shadow-4.1.0-goodname.patch
|
Patch2: shadow-4.1.1-selinux.patch
|
||||||
Patch4: shadow-4.1.1-selinux.patch
|
Patch3: shadow-4.1.2-sysAccountDownhill.patch
|
||||||
Patch5: shadow-4.1.1-sysAccountDownhill.patch
|
|
||||||
Patch6: shadow-4.1.1-saltSize.patch
|
|
||||||
|
|
||||||
License: BSD
|
License: BSD
|
||||||
Group: System Environment/Base
|
Group: System Environment/Base
|
||||||
|
@ -43,11 +41,9 @@ are used for managing group accounts.
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n shadow-%{version}
|
%setup -q -n shadow-%{version}
|
||||||
%patch0 -p1 -b .redhat
|
%patch0 -p1 -b .redhat
|
||||||
%patch1 -p1 -b .audit
|
%patch1 -p1 -b .goodname
|
||||||
%patch3 -p1 -b .goodname
|
%patch2 -p1 -b .selinux
|
||||||
%patch4 -p1 -b .selinux
|
%patch3 -p1 -b .sysAccountDownhill
|
||||||
%patch5 -p1 -b .sysAccountDownhill
|
|
||||||
%patch6 -p1 -b .saltSize
|
|
||||||
|
|
||||||
|
|
||||||
rm po/*.gmo
|
rm po/*.gmo
|
||||||
|
@ -188,6 +184,9 @@ rm -rf $RPM_BUILD_ROOT
|
||||||
%{_mandir}/man8/vigr.8*
|
%{_mandir}/man8/vigr.8*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon May 26 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.2-1
|
||||||
|
- upgrade
|
||||||
|
|
||||||
* Tue May 20 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.1-2
|
* Tue May 20 2008 Peter Vrabec <pvrabec@redhat.com> 2:4.1.1-2
|
||||||
- fix salt size problem (#447136)
|
- fix salt size problem (#447136)
|
||||||
|
|
||||||
|
|
1
sources
1
sources
|
@ -1,3 +1,4 @@
|
||||||
e91727c55dbafc9915250e31535f13bb shadow-4.0.17-login.defs
|
e91727c55dbafc9915250e31535f13bb shadow-4.0.17-login.defs
|
||||||
ebdf46b79f9b414353c9ae8aba4d55cc shadow-4.0.18.1-useradd
|
ebdf46b79f9b414353c9ae8aba4d55cc shadow-4.0.18.1-useradd
|
||||||
b1aa30abb3cce16a37b53e45e1ec70a4 shadow-4.1.1.tar.bz2
|
b1aa30abb3cce16a37b53e45e1ec70a4 shadow-4.1.1.tar.bz2
|
||||||
|
ce90cbe9cba7f6673cb10cad49083c1c shadow-4.1.2.tar.bz2
|
||||||
|
|
Loading…
Reference in a new issue