seahorse-agent upon startup appears to sniff through my ~/.ssh
directory, find any SSH identity keys, and automagically add them to
ssh-agent. This appears to be default behavior, and is really, really
wrong.
I have a peculiar setup here. I regularly connect to a remote
server in two ways: password-authenticated (no key exchange), and key-
authenticated without passphrase. The password-authenticated mode I use
for interactive sessions.
The key-without-passphrase mode I use to fetch mail from the
remote IMAP server ('fetchmail' is configured to launch the tunnel).
The remote host is configured, when receiving that particular key, to
launch imapd (and only imapd). Thus, the IMAP session is secure against
snoopers.
But then seahorse-agent waltzes in, sees an identity key in
~/.ssh and, without so much as a peep, adds it to the ssh-agent. This
means that, when attempting an interactive session, ssh-agent will
helpfully provide the SSH key bound to imapd, and I end up staring at an
IMAP protocol banner.
Further, when I attempt to remove the cached key via
'ssh-add -D', seahorse-agent (presumably) adds it right back again.
After some Googling around, I discovered this broken behavior
can be disabled via seahorse-preferences, so my immediate issue is
solved. Nevertheless, I contend this, at the very least, should not be
default behavior, and in fact should be seriously reconsidered. There
is absolutely no way for seahorse-agent to know the policy
considerations attached to any keys it may find lurking in ~/.ssh, and
therefore should not -- by default, anyway -- be trying to do anything
"clever" or "helpful" with them.
Please investigate this matter.
Thanks,
Schwab