Security Warning: Active attacks using stolen SSH keys

Billy Crook billycrook at gmail.com
Tue Aug 26 19:11:52 CDT 2008


If you haven't replaced your Debian-generated SSH keys yet, it's
really time to do so immediately if they were generated from
ssh-keygen during that year and a half that it was vulnerable in
Debian.  It's also not a bad idea to just check to see if yours are on
the list anyway.  See
http://wiki.debian.org/SSLkeys#head-d841ac769390d013577ce3fd2be24b8cf5a74cfb

From: http://isc.sans.org/diary.html?storyid=4937&rss

The US-CERT is reporting that there is active attacks against Linux
environments using stolen SSH keys.  There is a new rootkit out,
Phalanx2 which is dropped by attackers which, among the usual rootkit
tasks, steal any SSH key on a system.  The attackers then, presumably,
use those stolen keys (the ones without passwords/passphrases at
least) to get into other machines.

Sources of compromised keys could include the weak key vulnerability
in Debian-based systems a few months ago, so if you haven't updated
and replaced those keys, you ought to do so now.

The biggest defense is to have any keys, especially those used to
authenticate to remote machines and certainly internet facing ones,
require a passphrase to use.  Check your logs, especially if you use
SSH key-based auth, to identify accesses from remote machines that
have no business accessing you.  If you have IPs, that would be good.

To detect if you have Phalanx2, look for /etc/khubd.p2/ (access by cd,
not ls) or any directory that is called "khubd.p2".  /dev/shm/ may
contain files from the attack as well.  Tripwire, AIDE and friends
should also be able to detect filesystem changes.

--
John Bambenek
bambenek /at/ gmail \dot\ com


More information about the Kclug mailing list