Register a domain and help support LQ
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 03-04-2004, 05:43 PM   #1
LQ Newbie
Registered: Sep 2003
Posts: 14

Rep: Reputation: 0
Question how to stop a connection to a specific UDP/TCP port?

how to stop a connection to a specific UDP/TCP port?
for ie, I've just seen a connection at port 3765 and want to shut it down
on the fly!
Old 03-04-2004, 08:28 PM   #2
Registered: Sep 2003
Location: Adelaide, Australia
Distribution: Fedora/RH
Posts: 231

Rep: Reputation: 30
if the connection is made to a service then kill the service i guess...
generally a connection can (i could be wrong) only be made to a port that has a service listening.. otherwise the port will appear closed (if you not using iptables to DROP the ports)

I would suggest that if you dont already have a firewall setup DO IT! iptables is very good just learn how to use it

Last edited by chrisfirestar; 03-04-2004 at 08:40 PM.
Old 03-04-2004, 08:37 PM   #3
LQ Guru
Registered: Apr 2003
Location: nottingham england
Distribution: Gentoo
Posts: 2,672

Rep: Reputation: 47
block it in your firewall.

/sbin/iptables -I INPUT -p tcp --dport 3765 -j DROP
/sbin/iptables -I INPUT -p udp --dport 3765 -j DROP

or you can do it graphically with firestarter


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
Setting up router with IP based or TCP/UDP port rules raakjoer Linux - Networking 1 10-24-2005 09:51 AM
tcp/udp and c++ Kroenecker Programming 1 05-10-2005 12:56 PM
TCP Port 53 Open - How to enable UDP 53? stardotstar Linux - Networking 6 03-16-2005 05:49 AM
UDP over TCP The_Nerd Programming 7 07-21-2004 10:45 PM
TCP vs. UDP mikeshn Linux - Networking 5 05-17-2003 05:14 PM

All times are GMT -5. The time now is 12:35 PM.

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