group.of.nepali.translators team mailing list archive
-
group.of.nepali.translators team
-
Mailing list archive
-
Message #29848
[Bug 984390] Re: $PATH is taken from login.defs not /etc/environment
This bug was fixed in the package shadow - 1:4.5-1ubuntu2
---------------
shadow (1:4.5-1ubuntu2) bionic; urgency=medium
* debian/patches/1013_extrausers_deluser.patch
- add --extrausers option to "userdel" (LP: #1659534)
* debian/patches/2000_fix-su-pam-env-handling.
- fix "su -l" to correctly use pam_getenvlist (LP: #984390)
-- Michael Vogt <michael.vogt@xxxxxxxxxx> Fri, 22 Mar 2019 20:05:38
+0100
** Changed in: shadow (Ubuntu Bionic)
Status: Fix Committed => Fix Released
--
You received this bug notification because you are a member of नेपाली
भाषा समायोजकहरुको समूह, which is subscribed to Xenial.
Matching subscriptions: Ubuntu 16.04 Bugs
https://bugs.launchpad.net/bugs/984390
Title:
$PATH is taken from login.defs not /etc/environment
Status in shadow package in Ubuntu:
Fix Released
Status in shadow source package in Precise:
Won't Fix
Status in shadow source package in Xenial:
Fix Released
Status in shadow source package in Bionic:
Fix Released
Bug description:
TEST CASE:
$PATH isn't sourced from /etc/environment, instead the version in
/etc/login.defs is used. (The example below comes from a precise install.)
| james@panlong:~$ echo $PATH
| /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
| james@panlong:~$ sudo su - buildd
| buildd@panlong:~$ echo $PATH
| /usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
| buildd@panlong:~$ cat /etc/environment
| PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games"
| buildd@panlong:~$ grep PATH /etc/login.defs
| # Three items must be defined: MAIL_DIR, ENV_SUPATH, and ENV_PATH.
| # *REQUIRED* The default PATH settings, for superuser and normal users.
| ENV_SUPATH PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
| ENV_PATH PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
| #CRACKLIB_DICTPATH
| buildd@panlong:~$ sudo sed -i -e "s#^ENV_PATH.*#ENV_PATH PATH=/wtf:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games#" /etc/login.defs
| buildd@panlong:~$ logout
| james@panlong:~$ sudo su - buildd
| buildd@panlong:~$ echo $PATH
| /wtf:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
| buildd@panlong:~$
REGRESSION POTENTIAL:
- medium: it changes (incorrect) existing behaviour so https://xkcd.com/1172/ may apply
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/shadow/+bug/984390/+subscriptions