sudo2shell
by KrishnaSSH
A Linux privilege escalation. You become root.
Reproduce
- Open a terminal.
- Type
sudo -sand press Enter. - Enter your root password and press Enter.
- You are root.
$ sudo -s [sudo] password for user: # whoami root
Notes
This only works if you have the password and are allowed to use sudo, so it is the intended behavior of sudo and not a vulnerability. It won't get a CVE number.
Mitigation
Don't give people the root password, or remove them from sudoers.