Re:Analysis of the Linux backdoor used in Freenode IRC netwo...
by kibwen on Tuesday October 14, 2014 @01:18PM
(#8454514)
Say the persistence mechanism wasn't there. How would you go about detecting this rootkit?
[ Parent
| on HN ]
Re:Analysis of the Linux backdoor used in Freenode IRC netwo...
by Sanddancer on Tuesday October 14, 2014 @01:25PM
(#8454550)
If the persistence mechanism wasn't there, you'd be able to detect it from the added files -- /bin/dh and ipt_ip_udp.so in your modules directory. Tools like tripwire work by hashing the files on your system so you can tell at a glance when one changes.
Re:Analysis of the Linux backdoor used in Freenode IRC netwo...
by blibble on Tuesday October 14, 2014 @01:35PM
(#8454612)
there's nothing to stop it hooking opendir() and friends to hide it from ls!
Re:Analysis of the Linux backdoor used in Freenode IRC netwo...
by Sanddancer on Tuesday October 14, 2014 @04:33PM
(#8455617)
True, if the tool has been built with dynamic linking. Statically linking your security tools makes it a lot harder to hide your naughtyware. Depending on how deep the rabbit hole led in your infection, there are of course other things that could be done, like a malicious kernel module overriding the getdirentries(2) syscall, which would mean even more fun manually parsing the directory entries.
Then again, the best course of action is to pull that server down and build a new clean box, and do all the analysis offline. Boot from some sort of read-only media to minimize the threat, and analyze from a known good kernel, making sure to not run anything from the infected box unless you're goddamn sure what you're doing.