force specific shell environment variable on process using /etc/pam.d/ rules
1
vote
0
answers
119
views
I am using slim login manager, and it has its own pam rules file:
/etc/pam.d/slim
.
auth requisite pam_nologin.so
auth required pam_env.so readenv=1
auth required pam_env.so readenv=1 envfile=/etc/default/locale
@include common-auth
@include common-account
session required pam_limits.so
session required pam_loginuid.so
@include common-session
@include common-password
it seems that the pam_env.so
rules are setting the environment variables for the running process, such as: USER
, HOME
, PWD
, SHELL
, ...
Is it possible, after these have been set, to force SHELL
to be /bin/sh
?
I mean, regardless what shell user has specified in /etc/passwd
, I want to force to use /bin/sh
for slim process.
Asked by Martin Vegter
(598 rep)
Aug 25, 2020, 04:18 AM