| Author |
Message |
zunzun
Joined: 18 Feb 2005
Posts: 178
Location: Birmingham, Alabama USA
|
| Posted: Thu Jan 24, 2008 8:23 pm Post subject: Mystery infestation strikes Linux/Apache Web sites |
|
|
Quote: "According to cPanel, if you are unable to create a directory name beginning with a numeral -- as in mkdir 1 -- you're infected. Another test is to monitor the packets from the server with the following tcpdump command:
tcpdump -nAs 2048 src port 80 | grep "[a-zA-Z]\{5\}\.js'"
One great unknown thus far is how the servers come to be infected. Absent any forensic evidence of break-ins, the current thinking is that the malware authors gained access to the servers using stolen root passwords."
http://www.linux.com/feature/125548
James |
|
| Back to top |
|
cz9qvh
Joined: 19 Jan 2008
Posts: 14
|
| Posted: Fri Jan 25, 2008 2:22 pm Post subject: |
|
|
| scary stuff. time to go back to work on my firewall script, heh. |
|
| Back to top |
|
rjp
Joined: 15 Aug 2003
Posts: 102
|
| Posted: Mon Jan 28, 2008 9:40 am Post subject: |
|
|
| I can't help but think that successful SSH brute-force password attacks are at least part of the problem. My systems get hammered with bruteforcers daily (never mind that I disable passwords in favor of keys for SSH access). |
|
| Back to top |
|
blogpuzzles
Joined: 19 Feb 2008
Posts: 16
|
| Posted: Wed Feb 20, 2008 8:30 pm Post subject: Disable root login. |
|
|
| Yet another compelling reason to disable root logins via SSH. :) |
|
| Back to top |
|
Risar
Joined: 29 Apr 2008
Posts: 7
|
| Posted: Sat May 03, 2008 2:01 pm Post subject: |
|
|
| http://denyhosts.sourceforge.net/ |
|
| Back to top |
|
Deckert
Joined: 24 Mar 2007
Posts: 42
Location: South Africa
|
| Posted: Sun May 04, 2008 5:43 pm Post subject: |
|
|
Or just rate-limit incoming connections to your SSH server. I've seen excellent results with this:
Code:
# rate limit incomig port 22 connections
iptables -I INPUT -p tcp --dport 22 -i eth0 -m state --state NEW -m recent --set
iptables -I INPUT -p tcp --dport 22 -i eth0 -m state --state NEW -m recent --update --seconds 60 --hitcount 2 -j DROP
That will limit the number of connections coming from one IP to two per minute. Anything more and it gets blocked. If they keep on hitting it, it stays blocked. Best of all, access from your own IP is not affected.
--deckert |
|
| Back to top |
|
ravasolutions
Joined: 21 May 2008
Posts: 4
Location: Stamford, CT
|
| Posted: Sun Jun 15, 2008 11:08 pm Post subject: fail2ban + fwbuilder |
|
|
- get fail2ban to take care of any future bruteforce attacks
- get fwbuilder to manage your IP tables with ease
- make sure you dont run your apache as root
- read milion other tips on google about securing your apache webserver |
|
| Back to top |
|
| |