Package: sudo
Version: 1.6.8p12-4
Tags: patch

It is nice that the new, tighter sudo now keeps the XAUTHORITY variable,
but there are still X variables that sudo is not respecting, and this
makes it hard for me to run some X11 applications.  sudo should keep the
Xt toolkit variables XAPPLRESDIR, XFILESEARCHPATH, and XUSERFILESEARCHPATH.

The small patch appended restores the environment variables used by Xt.
It is against 1.6.8p12-4, but a similar patch would benefit 1.6.8p7-1.4
in Sarge.

 < Stephen

--- sudo-1.6.8p12/env.c 2006-06-17 17:49:06
+++ env.c       2006-06-17 17:56:18
@@ -372,6 +372,9 @@ rebuild_env(envp, sudo_mode, noexec)
            if (!strncmp (*ep, "DISPLAY=",8)
                || !strncmp (*ep, "XAUTHORITY=", 11)
                || !strncmp (*ep, "XAUTHORIZATION=", 15)
+               || !strncmp (*ep, "XAPPLRESDIR=", 12)
+               || !strncmp (*ep, "XFILESEARCHPATH=", 16)
+               || !strncmp (*ep, "XUSERFILESEARCHPATH=", 20)
                || !strncmp (*ep, "LANG=", 5)
                || !strncmp (*ep, "LANGUAGE=", 9)
                || !strncmp (*ep, "LC_", 3))
--- sudo-1.6.8p12/sudoers.pod   2006-06-17 17:49:06 -0400
+++ sudoers.pod 2006-06-18 19:04:14 -0400
@@ -441,10 +441,12 @@
 If set, B<sudo> will reset the environment to only contain the
 following variables: C<HOME>, C<LOGNAME>, C<PATH>, C<SHELL>, C<TERM>,
 C<DISPLAY>, C<XAUTHORITY>, C<XAUTHORIZATION>,
+C<XAPPLRESDIR>, C<XFILESEARCHPATH>, C<XUSERFILESEARCHPATH>,
 C<LANG>, C<LANGUAGE>, C<LC_*>,
 and C<USER> (in addition to the C<SUDO_*> variables).
 
 Of these, only C<TERM>, C<DISPLAY>, C<XAUTHORITY>, C<XAUTHORIZATION>,
+C<XAPPLRESDIR>, C<XFILESEARCHPATH>, C<XUSERFILESEARCHPATH>,
 C<LANG>, C<LANGUAGE>, and C<LC_*> are copied unaltered from the old 
environment.
 The other variables are set to default values (possibly modified
 by the value of the I<set_logname> option).  If B<sudo> was compiled
--- sudo-1.6.8p12/debian/README.Debian  2006-06-17 17:49:06.000000000 -0400
+++ debian/README.Debian        2006-06-18 19:05:27.000000000 -0400
@@ -3,6 +3,7 @@
 
 This implies that all environment variables are removed, except for
 HOME, LOGNAME, PATH, SHELL, TERM, DISPLAY, XAUTHORITY, XAUTHORIZATION,
+XAPPLRESDIR, XFILESEARCHPATH, XUSERFILESEARCHPATH,
 LANG, LANGUAGE, LC_*, and USER.
 
 In case you want sudo to preserve more environment variables, you must


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to