Package: libpam-runtime
Version: 1.1.8-3.2
Severity: minor
Tags: patch
Dear Maintainer,
Perl 5.22 now warns about unescaped left curly brackets in regular
expressions.[1] This results in pam_getenv printing the following
warning on stderr on every invocation:
Unescaped left brace in regex is deprecated, passed through in regex; marked by
<-- HERE in m/(?<!\\)\${ <-- HERE ([^}]+)}/ at /usr/sbin/pam_getenv line 78.
The fix is trivial, but I've attached a patch anyway, for clarity.
Best regards,
Kevin
P.S. I tried to check that this isn't in the current development
versions (if there are any) but the Vcs-Bzr control field points to
https://bzr.debian.org/bzr/pkg-pam/debian/sid/ which returns 404 and I
didn't see it on https://anonscm.debian.org/cgit/.
1.
http://search.cpan.org/dist/perl-5.22.0/pod/perldelta.pod#A_literal_%22{%22_should_now_be_escaped_in_a_pattern
-- System Information:
Debian Release: stretch/sid
APT prefers testing
APT policy: (990, 'testing'), (500, 'unstable'), (101, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.3.3+kevinoid1+ (SMP w/4 CPU cores)
Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages libpam-runtime depends on:
ii debconf [debconf-2.0] 1.5.58
ii libpam-modules 1.1.8-3.2
libpam-runtime recommends no packages.
libpam-runtime suggests no packages.
-- debconf information:
libpam-runtime/no_profiles_chosen:
* libpam-runtime/profiles: unix, systemd, consolekit, capability
libpam-runtime/title:
libpam-runtime/conflicts:
libpam-runtime/override: false
diff -Nru pam-1.1.8.orig/debian/local/pam_getenv pam-1.1.8/debian/local/pam_getenv
--- pam-1.1.8.orig/debian/local/pam_getenv 2016-01-12 20:59:37.867325442 -0800
+++ pam-1.1.8/debian/local/pam_getenv 2016-01-12 20:59:52.907461453 -0800
@@ -75,7 +75,7 @@
my ($val) = @_;
return undef unless $val;
die "Cannot handle PAM items\n" if /(?<!\\)\@/;
- $val =~ s/(?<!\\)\${([^}]+)}/$ENV{$1}||""/eg;
+ $val =~ s/(?<!\\)\$\{([^}]+)\}/$ENV{$1}||""/eg;
return $val;
}