From 291b28ac526f43cdb984fe0209ed86b1609358b5 Mon Sep 17 00:00:00 2001 From: nekral-guest Date: Sun, 24 Jan 2010 17:13:40 +0000 Subject: [PATCH] * src/su.c: Do not sanitize the environment. This breaks --preserve-environment. This sanitation was disabled on Debian since quite some time with no reported issues, and sanitize_env() documentation agrees that it should be useless as all modern Unixes will handle setuid executables properly. This Fixes Alioth#312287. --- ChangeLog | 9 +++++++++ src/su.c | 2 -- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index f3944417..e440b310 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2009-01-24 Nicolas François + + * src/su.c: Do not sanitize the environment. This breaks + --preserve-environment. This sanitation was disabled on Debian + since quite some time with no reported issues, and sanitize_env() + documentation agrees that it should be useless as all modern + Unixes will handle setuid executables properly. This Fixes + Alioth#312287. + 2009-01-24 Nicolas François * libmisc/setupenv.c: Fix typo from 2009-11-01. diff --git a/src/su.c b/src/su.c index 97970037..a0ee6d8d 100644 --- a/src/su.c +++ b/src/su.c @@ -409,8 +409,6 @@ int main (int argc, char **argv) #endif #endif /* !USE_PAM */ - sanitize_env (); - (void) setlocale (LC_ALL, ""); (void) bindtextdomain (PACKAGE, LOCALEDIR); (void) textdomain (PACKAGE);