4

I have a really strange problem when using GNOME keyring daemon.

I had an old SSH key which I've now retired and started using a new, stronger keyfile. However, every time I attempt to SSH into one of my servers, SSH tells me

Agent admitted failure to sign using the key.
Permission denied (publickey).
fatal: The remote end hung up unexpectedly

I'm pretty sure that the keyring daemon is trying to use my old key for some strange reason.

How can I reconfigure the keyring daemon to delete any knowledge of my old key?

  • Can you ls -al the contents of your ~/.ssh directory, showing the key files and their permissions? – dg99 Dec 12 '13 at 21:24
2

Personally I use seahorse for managing the gnome keyring.

In seahorse there's a "My personal keys" tab. This will contain all your ssh keys. Right click the one you want to delete and select "delete".

enter image description here


EDIT:

Your comment indicates you tried this and still have the issue. Digging around on your error message turns up a couple of noteworthy hits (this plus a bug report).

The solution seems to be to add your key via ssh-add.

  • Unfortunately I've tried that and it doesn't work. My key shows up in "other keys" and I've tried deleting it and nothing happens, it doesn't even disappear from the GUI. – Naftuli Kay Dec 12 '13 at 20:33
  • "Other keys" is for the public keys of other systems that are present on yours (ie, your authorized_keys file). Not the private keys. – Patrick Dec 12 '13 at 20:35
  • Okay, since I was using PKCS#8 keys, GNOME keyring failed to load the key and just ended up botching everything. Now, with GNOME keyring disabled on startup, I can just use SSH agent to manage my keys. – Naftuli Kay Dec 12 '13 at 23:16
2

GNOME Keyring Daemon doesn't like PKCS#8 keys, so it fails every time and can't import the key.

I was able to fix this by stopping GNOME Keyring Daemon from acting as an SSH agent, and I now use ssh-add instead.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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