The public component of SSH keys theoretically don't need to be kept private. It was therefore to my surprise that I was unable to read the public key of another user on the system:
andreas:~$ cat /home/bob/.ssh/id_rsa.pub
cat: /home/bob/.ssh/id_rsa.pub: Permission denied
The permissions of the key file allow me to read the id_rsa.pub file (644), the problem is the .ssh directory has the permission 700.
Is there any system in place for listing the public keys of other users on the system without having to be root or logging in as each user individually?
ssh-keyscanfor host keys. I wasn't sure if there was something vaguely similar for user keys. – IQAndreas Dec 29 '15 at 02:35