PDA

View Full Version : [ubuntu] Root Back Door


dennismoore1
July 31st, 2008, 04:24 PM
To become root without a password use the following code.
su
(do not type a password)
sudo su

you will be perminant root untill that terminal exits

tamoneya
July 31st, 2008, 04:28 PM
first of all you dont need the first "su". Also this isnt exactly a back door or an exploit. If you are able to use the sudo command you have root privileges anyways.

aysiu
July 31st, 2008, 04:38 PM
To become root without a password use the following code.
su
(do not type a password)
sudo su

you will be perminant root untill that terminal exits
If I type su and don't type a password, I get the error message (circled in red) su: Authentication failure If I then type sudo su I'm prompted for a password (as you can see circled in green).

So, no, this isn't a "root back door."

If you really want to become root without a password, just boot into recovery mode.

dje
July 31st, 2008, 04:41 PM
To become root without a password use the following code.
su
(do not type a password)
sudo su

you will be perminant root untill that terminal exits

what probably happened was you performed a command with sudo a few minutes before (and since it doesn't ask you your password again for 15 minutes after putting in your password using sudo), therefore when you performed 'sudo su' and it did not ask you for your password giving the illusion that it is a 'back door' but it isn't ;)

dje

aysiu
July 31st, 2008, 04:54 PM
what probably happened was you performed a command with sudo a few minutes before (and since it doesn't ask you your password again for 15 minutes after putting in your password using sudo), therefore when you performed 'sudo su' and it did not ask you for your password giving the illusion that it is a 'back door' but it isn't ;)

dje
That still doesn't explain why it's okay to enter no password for su. There should still be an authentication failure for that first command.

dje
July 31st, 2008, 04:58 PM
That still doesn't explain why it's okay to enter no password for su. There should still be an authentication failure for that first command.

maybe it did, it certainly does for me, and he did not explain this in his post?

cdenley
July 31st, 2008, 05:08 PM
what probably happened was you performed a command with sudo a few minutes before (and since it doesn't ask you your password again for 15 minutes after putting in your password using sudo), therefore when you performed 'sudo su' and it did not ask you for your password giving the illusion that it is a 'back door' but it isn't ;)

dje

I agree. Try using "sudo -K", then show us the "back door".

sc0g
July 31st, 2008, 06:20 PM
sudo -i is literally the same as su - on sudo-enabled Debian distros.

The reason you are able to do sudo su is because you probably haven't set a root password. By installation default, there is no root password on Ubuntu/Kubuntu/Xubuntu, etc...

Thorzilla
July 31st, 2008, 10:48 PM
So is there a way to log out after performing all the commands you needed to, so that sudo asks you for a password the next time?

aysiu
July 31st, 2008, 10:50 PM
So is there a way to log out after performing all the commands you needed to, so that sudo asks you for a password the next time?
You can change the sudo timeout to 0 minutes by following these instructions (http://ubuntuforums.org/showthread.php?p=116697#post116697).

Oldsoldier2003
July 31st, 2008, 11:01 PM
sudo -k will revoke the users timestamp and require a password on the next sudo

kevdog
July 31st, 2008, 11:01 PM
sudo su

Type all your commands


exit

Back into normal shell

Gun_Smoke
July 31st, 2008, 11:40 PM
This whole thread could be forgotten if you just give your self root. Use it if you want...

Oldsoldier2003
August 1st, 2008, 12:33 AM
This whole thread could be forgotten if you just give your self root. Use it if you want...
But of course on the Ubuntu Forums we don't advocate enabling the root account, we prefer to educate users on the Ubuntu security model which uses sudo...

Thorzilla
August 1st, 2008, 02:34 PM
You can change the sudo timeout to 0 minutes by following these instructions (http://ubuntuforums.org/showthread.php?p=116697#post116697).

Cool! Thanks.

chaoman
March 20th, 2009, 07:34 PM
If you want to never have to type in a password for sudo more than once, just tell it never time out and keep the terminal window open. Ubuntu rulz. Also, DOWN WITH DA PATRIOT ACT! ](*,)

cariboo907
March 20th, 2009, 11:34 PM
Another nercothread brought back from the dead. You can accomplish the same thing using:

sudo -i

Without having to modifying /etc/sudoers.

To @chaoman, you could have found something a little better for your first post. :)

Jim