LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 04-08-2007, 08:53 AM   #1
SPEEDEX
LQ Newbie
 
Registered: Apr 2007
Posts: 22

Rep: Reputation: 0
Post Dos Attack on SSH Tunnel


Hello Guys
I have a small anonymizer service on the web , I have a squid server listening on 127.0.0.1 port 3128. and a ssh server which users connect to it and use it as a tunnel to connect to squid server. very simple setup.
recently I have encountered a problem I have no idea how to solve it. one or some of my users are infected by a worm , and they start to send lots of request for big zip or wmv files through ssh tunnel to my squid server. and it causes my incoming traffic to go very high. in fact it is a ddos attack. but I can not know which user or IP is attacking , because they come from ssh tunnel and in squid log all of requests come from IP 127.0.0.1 like this :

1176020701.378 12063 127.0.0.1 TCP_MISS/200 109973 GET h**p://a1327.r.akareal.net/ondemand/7/1327/2110/973023381/voice.download.akamai.com/2110/wm/voa/nenaf/pers/video/PERSIAN_LATEEDITION1830v0407.wmv? - DIRECT/80.15.236.205 application/octet-stream

do you have any idea how to debug this problem ?
 
Old 04-08-2007, 11:15 AM   #2
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 116Reputation: 116
Why not set up SSH to log connections, then match the offender by time stamps, then block the IP?
 
Old 04-08-2007, 11:21 AM   #3
SPEEDEX
LQ Newbie
 
Registered: Apr 2007
Posts: 22

Original Poster
Rep: Reputation: 0
I already have the SSH log , you mean to check when a user is connected and then check the time of start of attacks ? I have many users , so in 5 minutes could be lots of logins. also I can not be sure the attacker starts to attack in the exact time which he is connected , may be it starts to attack some minutes after connnecting. isnt there a more reliable solution ?
 
Old 04-08-2007, 11:58 AM   #4
jiml8
Senior Member
 
Registered: Sep 2003
Posts: 3,171

Rep: Reputation: 116Reputation: 116
SSH keeps a table mapping localhost ports to actual IP addresses. It has to do that otherwise it couldn't forward. You need to access that table. Try netstat and see what that gives you.
 
  


Reply

Tags
ddos, debug, ssh


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
is this a Dos Attack?? xtremeclones Linux - Security 8 09-27-2006 01:40 AM
Attack on sshd caused near-DOS The MCP Linux - Security 2 02-14-2006 09:06 PM
Linux DOS Attack Possibility chereth Linux - Security 2 02-09-2006 12:26 PM
detecting a DOS attack ignus Linux - Security 4 07-29-2004 02:17 PM
Are we under DOS attack? sarmadys Linux - Security 2 02-06-2002 09:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 09:32 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration