summaryrefslogtreecommitdiff
path: root/debian/patches/regular_crypt
diff options
context:
space:
mode:
authorTimo Weingärtner <timo@tiwe.de>2012-06-22 10:35:36 +0200
committerTimo Weingärtner <timo@tiwe.de>2012-11-08 08:21:50 +0100
commit09cf8097c6bdf0011cf78c6000c6dcbdb7618cf0 (patch)
tree9771fc04b4222e83699a672cf08031cb5f3a0f59 /debian/patches/regular_crypt
parent65b4c91edbadc3e63bea9c5e6fb91e28aa2fe663 (diff)
downloadlibpam-pwdfile-debian/0.99-5.tar.gz
Imported Debian patch 0.99-5debian/0.99-5
Diffstat (limited to 'debian/patches/regular_crypt')
-rw-r--r--debian/patches/regular_crypt22
1 files changed, 22 insertions, 0 deletions
diff --git a/debian/patches/regular_crypt b/debian/patches/regular_crypt
new file mode 100644
index 0000000..9895e33
--- /dev/null
+++ b/debian/patches/regular_crypt
@@ -0,0 +1,22 @@
+Description: Use libc's crypt in the regular way
+ * That should support newer crypt types.
+ * We do the check before the weird stuff but keep it to not break setups
+ using broken md5 hashing or bigcrypt.
+ * CRYPTED_BCPWD_LEN as an upper limit seems to be ok by now.
+Author: Timo Weingärtner <timo@tiwe.de>
+Forwarded: no
+Last-Update: 2012-06-20
+
+--- libpam-pwdfile-0.99.orig/pam_pwdfile.c
++++ libpam-pwdfile-0.99/pam_pwdfile.c
+@@ -348,6 +348,10 @@ PAM_EXTERN int pam_sm_authenticate(pam_h
+
+ temp_result = 0;
+
++ if (strcmp(crypt(password, stored_crypted_password), stored_crypted_password) == 0) {
++ D(_pam_log(LOG_ERR,"password matched using the systems crypt()"));
++ temp_result = 1;
++ }
+ /* Extract the salt and set the passwd length, depending on MD5 or DES */
+ if (strncmp(stored_crypted_password, "$1$", 3) == 0) {
+ D(_pam_log(LOG_ERR,"password hash type is 'md5'"));