Re-enable +::::::::: wildcards that I had previously disallowed.

Note: if you put +::0:0:::::: in /etc/master.passwd as your only NIS
entry, it will cause all NIS uids and gids to be remapped to zero. This
is *intentional*. That's the way it's supposed to work. Enabling NIS with
no remapping at all is done with +:::::::::, not +::0:0::::::. Similarly,
+:::::::::/bin/csh will remap the shells of all NIS users to /bin/csh.
Or, you could do +wpaul:::::::::/bin/csh to remap NIS user wpaul's shell
to /bin/csh but leave everyone else alone.
This commit is contained in:
Bill Paul 1995-03-23 22:31:11 +00:00
parent e17334c329
commit d038db90e8
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=7291

View File

@ -179,7 +179,7 @@ main(argc, argv)
data.data = (u_char *)buf;
key.data = (u_char *)tbuf;
for (cnt = 1; scan(fp, &pwd); ++cnt) {
if(pwd.pw_name[0] == '+')
if(pwd.pw_name[0] == '+' pwd.pw_name[0] == '-')
yp_enabled = 1;
#define COMPACT(e) t = e; while (*p++ = *t++);
/* Create insecure data. */
@ -225,8 +225,7 @@ main(argc, argv)
error("put");
/* Store insecure special plus and special minus */
if ((pwd.pw_name[0] == '+' || pwd.pw_name[0] == '-')
&& pwd.pw_name[1]) {
if (pwd.pw_name[0] == '+' || pwd.pw_name[0] == '-') {
tbuf[0] = (pwd.pw_name[0] == '+') ?
_PW_KEYPLUSBYNUM : _PW_KEYMINUSBYNUM;
memmove(tbuf + 1, (pwd.pw_name[0] == '+') ?
@ -335,8 +334,7 @@ main(argc, argv)
error("put");
/* Store secure special plus and special minus */
if ((pwd.pw_name[0] == '+' || pwd.pw_name[0] == '-')
&& pwd.pw_name[1]) {
if (pwd.pw_name[0] == '+' || pwd.pw_name[0] == '-') {
tbuf[0] = (pwd.pw_name[0] == '+') ?
_PW_KEYPLUSBYNUM : _PW_KEYMINUSBYNUM;
memmove(tbuf + 1, (pwd.pw_name[0] == '+') ?