Closed isrgish closed 1 year ago
Looks like your sudo
binary doesn't have set-uid bit set. Run
chmod u+s /usr/bin/sudo
(Inside proot
's fake_id0
any set-uid exec sets uid to root)
That message indicates that sudo isn't running with root effective uid. While it is true that inside proot prctl(PR_GET_NO_NEW_PRIVS, 0, 0, 0, 0)
reports true, that thing in itself appears to not have caused problems so far
@michalbednarski Thanks this worked.
Now when I use sudo I get a message
sudo: unable to send audit message: Operation not permitted
Even after this message whatever I'm trying to do works. I was just wondering why I get the message.
Problem description
When I use proot either with -i uid:gid or using -0 and then login in as different user I can't use sudo. I get the following message
sudo: The "no new privileges" flag is set, which prevents sudo from running as root. sudo: If sudo is running in a container, you may need to adjust the container configuration to disable the flag.
I have been able in the past to use sudo but I don't know what I might have done differently. This I;m sure of that I didn't start proot from a root user.
Steps to reproduce
I'm running the following script
Then I try
sudo test
This is where I get the error message.Expected behavior
Expected that sudo works
Additional information