From 09cf8097c6bdf0011cf78c6000c6dcbdb7618cf0 Mon Sep 17 00:00:00 2001 From: Timo Weingärtner Date: Fri, 22 Jun 2012 10:35:36 +0200 Subject: Imported Debian patch 0.99-5 --- debian/patches/regular_crypt | 22 ++++++++++++++++++++++ debian/patches/series | 2 ++ debian/patches/visibility | 23 +++++++++++++++++++++++ 3 files changed, 47 insertions(+) create mode 100644 debian/patches/regular_crypt create mode 100644 debian/patches/series create mode 100644 debian/patches/visibility (limited to 'debian/patches') 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 +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'")); diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 0000000..fb3fb12 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1,2 @@ +visibility +regular_crypt diff --git a/debian/patches/visibility b/debian/patches/visibility new file mode 100644 index 0000000..d121a1e --- /dev/null +++ b/debian/patches/visibility @@ -0,0 +1,23 @@ +Description: Mark the pam_sm_* functions as __attribute__((visibility("default"))) +Author: Peter Palfrader +Bug-Debian: http://bugs.debian.org/499203 +Last-Update: 2012-06-20 + +--- libpam-pwdfile-0.99.orig/pam_pwdfile.c ++++ libpam-pwdfile-0.99/pam_pwdfile.c +@@ -222,6 +222,7 @@ + } + + /* expected hook for auth service */ ++__attribute__((visibility("default"))) + PAM_EXTERN int pam_sm_authenticate(pam_handle_t *pamh, int flags, + int argc, const char **argv) { + int retval, pcnt, pwdfilename_found; +@@ -408,6 +409,7 @@ + } + + /* another expected hook */ ++__attribute__((visibility("default"))) + PAM_EXTERN int pam_sm_setcred(pam_handle_t *pamh, int flags, + int argc, const char **argv) + { -- cgit v1.2.3