We have a Linux box (Ubuntu, but that shouldn't matter), say,
somemachine.example.com, and a user that has access to that machine,
I can SSH into that machine either by explicitly provided a password for
someuser like so:
ssh email@example.com Password: *****
...or by providing a PEM file (public key):
ssh -i ~/path/to/somemachine.pem firstname.lastname@example.org
Today I had to change the password for
someuser on that box (using the
passwd command), and was a little surprised to learn that I didn't have to also regenerate new keypairs (thus, new PEM file) for that user as well.
I'm wondering: why? Is there simply no connection between
someuser's password and the public/private key? If so, does Linux maintain, for each user, a set of credentials, which could either be passwords or public keys? How does Linux associate keys and passwords with particular users?