mirror of
https://github.com/Kicksecure/security-misc.git
synced 2024-10-01 08:25:45 -04:00
fix case when user "user" does not exists
This commit is contained in:
parent
18c726c3ee
commit
660837dc38
5
debian/security-misc.preinst
vendored
5
debian/security-misc.preinst
vendored
@ -165,6 +165,11 @@ legacy() {
|
|||||||
|
|
||||||
user_to_be_created=user
|
user_to_be_created=user
|
||||||
|
|
||||||
|
if ! id "$user_to_be_created" &>/dev/null ; then
|
||||||
|
true "INFO: user '$user_to_be_created' does not exist. Skipping addgroup console and pam-auth-update."
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
|
|
||||||
addgroup "$user_to_be_created" console
|
addgroup "$user_to_be_created" console
|
||||||
|
|
||||||
pam-auth-update --enable console-lockdown-security-misc
|
pam-auth-update --enable console-lockdown-security-misc
|
||||||
|
Loading…
Reference in New Issue
Block a user