You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We already have --preserve-environment, it's now ignored for --login, but maybe we can improve it, and make it usable with --login when a list of env.variables is specified, for example
👍
This feature could be useful for any display manager with automatic login and avoiding usage of PAM configuration to set environment. Workaround is to use bash_profile.
* usable with --login to whitelist specified environment variables
* the list is ignored for the core variables like HOME, SHELL, USER,
LOGNAME and PATH (su --login always resets these variables)
Note that su(1) requires password and after successful authentication
user has full control over the session, so he can set arbitrary
environment variables. The whitelist makes things more user friendly
only.
The patch removes unnecessary optimization when allocate environ[]. It
seems better to keep all in glibc hands and just reset the environment
array only.
Addresses: #221
Signed-off-by: Karel Zak <kzak@redhat.com>
This would be similar to sudo's feature
Defaults env_keep += "ENVNAME"
in/etc/sudoers
.The text was updated successfully, but these errors were encountered: