Source: pam Version: 1.4.0-10 Severity: normal Tags: patch Hi Sam & Steve,
thanks a lot for fixing #983427! Unfortunately, only the patch in the original message got applied in 1.4.0-10 but I posted an updated patch in message #23 of that bug. I attached a patch containing the remaining required changes. Thanks! cheers, josch
diff -Nru pam-1.4.0/debian/libpam-modules.postinst pam-1.4.0/debian/libpam-modules.postinst --- pam-1.4.0/debian/libpam-modules.postinst 2021-01-30 23:09:52.000000000 +0100 +++ pam-1.4.0/debian/libpam-modules.postinst 2021-08-28 07:49:06.000000000 +0200 @@ -5,16 +5,16 @@ if [ -z "$2" ] || dpkg --compare-versions "$2" lt 0.99.7.1-3 then - if ! [ -f /etc/security/opasswd ]; then + if ! [ -f "$DPKG_ROOT/etc/security/opasswd" ]; then umask 066 - touch /etc/security/opasswd + touch "$DPKG_ROOT/etc/security/opasswd" umask 022 fi fi -if dpkg --compare-versions "$2" lt 0.99.9.0-1 && ! [ -f /etc/environment ] +if dpkg --compare-versions "$2" lt 0.99.9.0-1 && ! [ -f "$DPKG_ROOT/etc/environment" ] then - touch /etc/environment + touch "$DPKG_ROOT/etc/environment" fi if dpkg --compare-versions "$2" lt-nl 1.1.2-1 \ diff -Nru pam-1.4.0/debian/libpam-runtime.postinst pam-1.4.0/debian/libpam-runtime.postinst --- pam-1.4.0/debian/libpam-runtime.postinst 2021-08-26 21:43:23.000000000 +0200 +++ pam-1.4.0/debian/libpam-runtime.postinst 2021-08-28 07:49:06.000000000 +0200 @@ -20,9 +20,9 @@ for configfile in common-auth common-account common-session \ common-password do - if [ -f /etc/pam.d/$configfile ] && \ + if [ -f "$DPKG_ROOT/etc/pam.d/$configfile" ] && \ ! fgrep -q $(calculate_md5sum $configfile) \ - /usr/share/pam/$configfile.md5sums 2>/dev/null + "$DPKG_ROOT/usr/share/pam/$configfile.md5sums" 2>/dev/null then force= fi