mirror of
https://github.com/plantroon/acme.sh.git
synced 2024-12-22 21:21:42 +00:00
This commit is contained in:
parent
6f55370ad4
commit
996f53373e
4
acme.sh
4
acme.sh
@ -6649,8 +6649,8 @@ _checkSudo() {
|
|||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
if [ -n "$SUDO_COMMAND" ]; then
|
if [ -n "$SUDO_COMMAND" ]; then
|
||||||
#it's a normal user doing "sudo su", or `sudo -i` or `sudo -s`
|
#it's a normal user doing "sudo su", or `sudo -i` or `sudo -s`, or `sudo su acmeuser1`
|
||||||
_endswith "$SUDO_COMMAND" /bin/su || grep "^$SUDO_COMMAND\$" /etc/shells >/dev/null 2>&1
|
_endswith "$SUDO_COMMAND" /bin/su || _contains "$SUDO_COMMAND" "/bin/su " || grep "^$SUDO_COMMAND\$" /etc/shells >/dev/null 2>&1
|
||||||
return $?
|
return $?
|
||||||
fi
|
fi
|
||||||
#otherwise
|
#otherwise
|
||||||
|
Loading…
Reference in New Issue
Block a user