2012-04-23 12:39:21 +00:00
|
|
|
diff -up yp-tools-2.12/src/yppasswd.c.adjunct yp-tools-2.12/src/yppasswd.c
|
|
|
|
--- yp-tools-2.12/src/yppasswd.c.adjunct 2012-04-23 13:17:47.000988833 +0200
|
|
|
|
+++ yp-tools-2.12/src/yppasswd.c 2012-04-23 13:18:01.209802938 +0200
|
2016-11-28 13:14:30 +00:00
|
|
|
@@ -450,6 +450,7 @@
|
2012-04-23 12:39:21 +00:00
|
|
|
passwdlen = get_passwd_len (pwd->pw_passwd);
|
|
|
|
if (pwd->pw_passwd[0]
|
2016-11-28 13:14:30 +00:00
|
|
|
&& 0 != strcmp (pwd->pw_passwd, "x") /* don't check shadow passwords */
|
|
|
|
+ && 0 != strncmp (pwd->pw_passwd, "##", 2) /* don't check passwords using passwd.adjunct feature */
|
2012-04-23 12:39:21 +00:00
|
|
|
&& uid)
|
|
|
|
{
|
|
|
|
char *crypted = crypt(pwdstr, pwd->pw_passwd);
|
2016-11-28 13:14:30 +00:00
|
|
|
@@ -774,6 +775,7 @@
|
|
|
|
/* We can't check the password with shadow passwords enabled. We
|
|
|
|
* leave the checking to yppasswdd */
|
|
|
|
if (uid != 0 && strcmp (pwd->pw_passwd, "x") != 0 &&
|
|
|
|
+ 0 != strncmp (pwd->pw_passwd, "##", 2) && /* don't check passwords using passwd.adjunct feature */
|
|
|
|
strcmp (pwd->pw_passwd, hashpass ) != 0)
|
|
|
|
{
|
|
|
|
int passwdlen = get_passwd_len (pwd->pw_passwd);
|