I know how to set new password of root in ubuntu 10.04 if I don't know root pasword and grub has no password . I want to know that whether I could get the old password which was set before I changed it. Does some file or command can give me access to old password of root
Asked
Active
Viewed 103 times
-1
-
3Only by cracking the password; the whole point of Unix password management is that if you don't provide the right password, you won't be able to get the password program to produce the right hash, and therefore you won't be able to get in. And the intention is that it is computationally infeasible to find the password given just the hashed (not encrypted) form of the password. – Jonathan Leffler Jan 12 '12 at 05:29
1 Answers
2
I'm not sure whether the password is saltet. If not, a rainbow table could help you crack it.
Normally, root should not have a password on Ubuntu at all, but you should use the sudo-mechanism to do sudo-tasks.
sudo grep root /etc/shadow
will show you, whether there is or not.
For me this reveals
root:!:13874:0:99999:7:::
which means, root has no password ("!" in second field, not a long hashcode).
A weak password might be cracked by brute force. A strong, salted password would be too expensive to crack and still last years.
see
man shadow
man 3 crypt
for further details.

user unknown
- 151
- 2
- 7