GRUB badly broken during upgrade
Avi Greenbury
lists at avi.co
Fri Oct 5 23:48:17 UTC 2012
Kevin O'Gorman wrote:
> I also have to say I don't understand your use of the phrase "root's
> password's locked" -- I'm not aware of locking or unlocking it, just
> of setting a password where there did not appear to be one before.
Generally, 'no password' refers to an empty hash, such that submitting
an empty string as a password will authenticate, whereas a 'locked
password' refers to setting the hash in /etc/passwd to something that
no password will ever hash to (normally '!', which is not a character
used in the encoding of the hash), so there is no possible password
that will successfully authenticate.
For what it's worth, if you do ever need to set root's password for
some reason, and you can get as far as a kernel mounting a root
filesystem, you can call it with 'init=/bin/bash' as a command line
argument to get a privileged bash shell without needing to
authenticate, in which you can use 'passwd' (or perhaps an editor
[maybe sed]) to set a password for root. This is _very_ unlikely to be
necessary, though - root-with-a-disabled-password has been around for
quite a long time now, and most eventualities are catered for.
Anyway, we've gone wonderfully far off topic in only about three
emails... :)
--
Avi
More information about the ubuntu-users
mailing list