LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
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 02-11-2006, 01:41 AM   #1
~=gr3p=~
Member
 
Registered: Feb 2005
Location: ~h3av3n~
Distribution: RHEL 4, Fedora Core 3,6,7 Centos 5, Ubuntu 7.04
Posts: 227

Rep: Reputation: 30
how to kill active TCP connections


I know one tool called cutter which can be used to kill an active tcp connections from netstat -na output. this is useful incase u want to immediately kill a malicious client connection to ur server. problem is cutter doesn't work on my Fedora C3. dsniff contains tcpkill but dsniff refuses to compile & install on FC3

any alternatives?

TIA
 
Old 02-11-2006, 05:29 AM   #2
nx5000
Senior Member
 
Registered: Sep 2005
Location: Out
Posts: 3,307

Rep: Reputation: 57
This is a bit straightforward but you can cut connectivity on the IP layer:
Code:
iphole.sh:
#!/bin/sh
route add -host $1 gw 127.0.0.1 

#iphole 11.22.33.44
You will cut all connections with this host, not only one!

I've found this on google for dsniff compilation on fc3, you can give it a try
http://www.enzotech.net/dsniff.html
 
Old 02-11-2006, 09:58 AM   #3
ExplodingTurnip
LQ Newbie
 
Registered: May 2005
Location: Los Angeles, CA USA
Distribution: Slackware, Knoppix
Posts: 23

Rep: Reputation: 15
You could also use IPTables which works on all Linux distros.

For dropping traffic from a single host I use:

Code:
iptables -I INPUT -s <ip address> -j DROP
Just replace <ip address> with the address of the host that you want to drop traffic from.
 
  


Reply



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
Need a way to limit TCP connections ewerta Linux - Networking 1 07-25-2005 03:54 PM
how to force kill TCP connections minil Programming 3 04-19-2005 06:04 AM
Active network connections crabboy AIX 1 08-04-2004 03:14 PM
GUI for active connections twistedpair Linux - Networking 3 03-30-2004 03:22 PM
Killing Active Connections Crashed_Again Linux - General 5 05-17-2003 01:48 AM

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

All times are GMT -5. The time now is 12:11 AM.

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