The SHELL environment variable was preserved from the user's
environment instead of being reset based on the passwd database when the "env_reset" option was used. Now it is reset as it should be.
This commit is contained in:
2
env.c
2
env.c
@@ -341,7 +341,7 @@ rebuild_env(sudo_mode, envp)
|
||||
if (!(didvar & DID_HOME))
|
||||
*nep++ = format_env("HOME", user_dir);
|
||||
if (!(didvar & DID_SHELL))
|
||||
*nep++ = format_env("SHELL", user_shell);
|
||||
*nep++ = format_env("SHELL", sudo_user.pw->pw_shell);
|
||||
if (!(didvar & DID_LOGNAME))
|
||||
*nep++ = format_env("LOGNAME", user_name);
|
||||
if (!(didvar & DID_USER))
|
||||
|
Reference in New Issue
Block a user