I'm looking for a script or program to facilitate the following scenario:

In our home network, there are lots of devices I can SSH in (all running a flavour of Linux). There are mobile phones, VCRs, our router, various laptops, NAS, VPS and so on, some 20 devices altogether.

I'm looking for a tool that lets me manage my family member's SSH keys on the devices easily, i.e.

  • Display whose public key is on which account on which device
  • Let me easily replace an old key with a new one across all devices
  • Install a new key across several devices

We don't have LDAP or NIS in place, because I don't have root on all devices (phones, VPS).

I believe that this is a common problem / scenario that already has multiple solutions, but I was unable to find suitable stuff on the internet. Config management tools (puppet, chef, …) seem like to much overhead, although I haven't looked into them yet. Manually scripting something would be my last resort, but as stated above, I'm sure there are already tools out there.

I prefer commandline tools (perhaps curses-based), but I'd also happily run any other stuff, be it Python, Perl or Ruby scripts, a Rails or GNOME app, whatever.

Since you probably will distribute the SSH public keys via SSH, you will either need to rely on previously installed public keys or passwords.

So I suggest to use OpenSSH's ssh-copy-id tool for copying keys to remote systems, either directly or as backend for a to-be-written tool. It though doesn't do much than adding keys. It can't remove keys as far as I know.

There are some other implementations of similar tools, e.g. ESR's ssh-installkeys or pushkey, but none of them seem to be able to list or remove keys from remote systems.

  • 2
    Yes, I thought of writing the initial pubkey via ssh using a password. Your last phrase describes the shortcomings of those tools and the reason why I look for something different. – Jan Jan 18 '15 at 18:57

Your Answer


By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.