[Pkg-samba-maint] r1567 - in trunk/samba/debian: . patches
vorlon at alioth.debian.org
vorlon at alioth.debian.org
Wed Nov 14 20:46:00 UTC 2007
Author: vorlon
Date: 2007-11-14 20:46:00 +0000 (Wed, 14 Nov 2007)
New Revision: 1567
Added:
trunk/samba/debian/patches/chgpasswd.patch
Modified:
trunk/samba/debian/changelog
trunk/samba/debian/patches/series
Log:
Update Samba to explicitly use the C locale when doing password changes, to
account for Linux-PAM's recently adopted i18n support. Closes: #451272.
Modified: trunk/samba/debian/changelog
===================================================================
--- trunk/samba/debian/changelog 2007-11-14 19:37:13 UTC (rev 1566)
+++ trunk/samba/debian/changelog 2007-11-14 20:46:00 UTC (rev 1567)
@@ -15,6 +15,9 @@
members of the admin group; no equivalent handling is done on Debian,
because there doesn't seem to be an appropriate template group we can use
that wouldn't be considered a privilege escalation for those users.
+ * Update Samba to explicitly use the C locale when doing password changes,
+ to account for Linux-PAM's recently adopted i18n support.
+ Closes: #451272.
[ Debconf translations ]
* Hebrew added. Closes: #444054
@@ -29,7 +32,7 @@
reporting and contributions from Launchpad's #156686
Closes: #449422
- -- Steve Langasek <vorlon at debian.org> Tue, 13 Nov 2007 11:55:48 -0800
+ -- Steve Langasek <vorlon at debian.org> Wed, 14 Nov 2007 11:36:57 -0800
samba (3.0.26a-1) unstable; urgency=low
Added: trunk/samba/debian/patches/chgpasswd.patch
===================================================================
--- trunk/samba/debian/patches/chgpasswd.patch (rev 0)
+++ trunk/samba/debian/patches/chgpasswd.patch 2007-11-14 20:46:00 UTC (rev 1567)
@@ -0,0 +1,51 @@
+Goal: Recent versions of Linux-PAM support localization of user prompts,
+so Samba must use the C locale when invoking PAM (directly or via
+/usr/bin/passwd) to ensure that password chat values match the prompts in a
+locale-invariant fashion.
+
+Authors: Mathias Gug <mathiaz at ubuntu.com>,
+ Steve Langasek <vorlon at debian.org>
+
+Upstream status: submitted in bugzilla bug #5082
+
+Index: samba-3.0.26a/source/smbd/chgpasswd.c
+===================================================================
+--- samba-3.0.26a.orig/source/smbd/chgpasswd.c
++++ samba-3.0.26a/source/smbd/chgpasswd.c
+@@ -126,6 +126,7 @@
+ struct termios stermios;
+ gid_t gid;
+ uid_t uid;
++ char *eptrs[1] = { NULL };
+
+ if (pass == NULL)
+ {
+@@ -222,7 +223,7 @@
+ passwordprogram));
+
+ /* execl() password-change application */
+- if (execl("/bin/sh", "sh", "-c", passwordprogram, NULL) < 0)
++ if (execle("/bin/sh", "sh", "-c", passwordprogram, NULL, eptrs) < 0)
+ {
+ DEBUG(3, ("Bad status returned from %s\n", passwordprogram));
+ return (False);
+@@ -498,6 +499,9 @@
+ #ifdef WITH_PAM
+ if (lp_pam_password_change()) {
+ BOOL ret;
++#ifdef HAVE_SETLOCALE
++ char *prevlocale = setlocale(LC_MESSAGES, "C");
++#endif
+
+ if (as_root)
+ become_root();
+@@ -511,6 +515,9 @@
+ if (as_root)
+ unbecome_root();
+
++#ifdef HAVE_SETLOCALE
++ setlocale(LC_MESSAGES, prevlocale);
++#endif
+ return ret;
+ }
+ #endif
Modified: trunk/samba/debian/patches/series
===================================================================
--- trunk/samba/debian/patches/series 2007-11-14 19:37:13 UTC (rev 1566)
+++ trunk/samba/debian/patches/series 2007-11-14 20:46:00 UTC (rev 1567)
@@ -24,3 +24,4 @@
smbpasswd-syslog.patch
get_global_sam_sid-non-root.patch
usershare.patch
+chgpasswd.patch
More information about the Pkg-samba-maint
mailing list