Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 107559 Details for
Bug 145839
net-mail/poppassd_ceti does not handle pam_ldap correctly
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
poppassd.c-5.patch
poppassd.c-5.patch (text/plain), 2.43 KB, created by
Warren Howard
on 2007-01-20 16:36:32 UTC
(
hide
)
Description:
poppassd.c-5.patch
Filename:
MIME Type:
Creator:
Warren Howard
Created:
2007-01-20 16:36:32 UTC
Size:
2.43 KB
patch
obsolete
>--- ../4/poppassd.c 2007-01-17 18:46:12.000000000 +0530 >+++ poppassd.c 2007-01-17 11:17:41.000000000 +0530 >@@ -92,6 +92,16 @@ > > char **pamstrings[2]; // 0 - oldpass, 1 - newpass > >+// The default PAM strings for old and new passwords >+char *oldstr[] = { "Password: ", >+ "Enter login(LDAP) password: " }; >+ >+char *newstr[] = { "New password: ", >+ "Re-enter new password: ", >+ "Enter new UNIX password: ", >+ "Retype new UNIX password: ", >+ "New UNIX password: " }; >+ > void WriteToClient (char *fmt, ...) > { > va_list ap; >@@ -136,9 +146,12 @@ > > void setstrings(int argc, char **argv) > { >- int old=0, new=0, c; >+ int old, new, c; > extern int opterr; > >+ old = sizeof(oldstr) / sizeof(oldstr[0]); >+ new = sizeof(newstr) / sizeof(newstr[0]); >+ > opterr = 0; > while(1) > { >@@ -162,6 +175,14 @@ > } > optind = 1; > >+ // add the default PAM strings present in oldstr and newstr to the end of pamstrings >+ for(c = 0 ; c < (sizeof(oldstr) / sizeof(oldstr[0])) ; c++) >+ pamstrings[POP_OLDPASS][--old] = oldstr[c]; >+ >+ for(c = 0 ; c < (sizeof(newstr) / sizeof(newstr[0])) ; c++) >+ pamstrings[POP_NEWPASS][--new] = newstr[c]; >+ >+ // add the cli PAM arguments infront of the default ones (added above) > while(1) > { > c = getopt(argc, argv, "n:o:"); >@@ -175,31 +196,16 @@ > { > char **pammsg; > >- /* Interpret possible PAM messages (not including errors) */ >+ // check if PAM is asking for old password > for(pammsg = pamstrings[POP_OLDPASS] ; *pammsg ; pammsg++) > if(!strcmp(msg, *pammsg)) > return POP_OLDPASS; > >- if(!strcmp(msg, "Password: ")) >- return POP_OLDPASS; >- if(!strcmp(msg, "Enter login(LDAP) password: ")) >- return POP_OLDPASS; >- >+ // check if PAM is asking for new password > for(pammsg = pamstrings[POP_NEWPASS] ; *pammsg ; pammsg++) > if(!strcmp(msg, *pammsg)) > return POP_NEWPASS; > >- if(!strcmp(msg, "New password: ")) >- return POP_NEWPASS; >- if(!strcmp(msg, "Re-enter new password: ")) >- return POP_NEWPASS; >- if(!strcmp(msg, "Enter new UNIX password: ")) >- return POP_NEWPASS; >- if(!strcmp(msg, "Retype new UNIX password: ")) >- return POP_NEWPASS; >- if(!strcmp(msg, "New UNIX password: ")) >- return POP_NEWPASS; >- > WriteToClient("Unknown PAM Message: %s", msg); // We should not ever reach here. > > return POP_SKIPASS;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 145839
:
95639
|
107552
|
107554
|
107556
|
107557
| 107559 |
671578