Go Back   nV News Forums > Linux Support Forums > General Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 09-14-07, 09:15 AM   #1
evilghost
Registered User
 
Join Date: Jul 2005
Posts: 3,606
Default iptables port forward (multi dport)

I need to forward incoming UDP 514 to UDP 514 and UDP 5141 using iptables. Any ideas? I've already tried tcprewrite/tcpreplay and I can see the traffic over tcpdump but the listening socket on 5141 never gets it, even tried with nc -l -u -p 5141.

tcpdump -s0 -w - -U "host 10.1.99.182 and udp dst port 514"|tcprewrite --portmap=514:5141 --infile=- --outfile=-|tcpreplay --intf1=eth0 -
evilghost is offline   Reply With Quote
Old 09-15-07, 12:41 PM   #2
Q
 
Join Date: Sep 2004
Posts: 7,808
Default Re: iptables port forward (multi dport)

Quote:
Originally Posted by evilghost
I need to forward incoming UDP 514 to UDP 514 and UDP 5141 using iptables. Any ideas? I've already tried tcprewrite/tcpreplay and I can see the traffic over tcpdump but the listening socket on 5141 never gets it, even tried with nc -l -u -p 5141.

tcpdump -s0 -w - -U "host 10.1.99.182 and udp dst port 514"|tcprewrite --portmap=514:5141 --infile=- --outfile=-|tcpreplay --intf1=eth0 -
What sort of hardware do you have between the origin and destination. Made sure you didn't have any limiting policies on a switch or anything?
Q is offline   Reply With Quote
Old 09-15-07, 01:59 PM   #3
evilghost
Registered User
 
Join Date: Jul 2005
Posts: 3,606
Default Re: iptables port forward (multi dport)

Lets just say Splunk is crap and that I had to use another solution even more horrific than above.
evilghost is offline   Reply With Quote
Old 09-15-07, 02:06 PM   #4
Q
 
Join Date: Sep 2004
Posts: 7,808
Default Re: iptables port forward (multi dport)

Quote:
Originally Posted by evilghost
Lets just say Splunk is crap and that I had to use another solution even more horrific than above.
You didn't have to touch a Windows app, did you?
Q is offline   Reply With Quote
Old 09-15-07, 07:11 PM   #5
evilghost
Registered User
 
Join Date: Jul 2005
Posts: 3,606
Default Re: iptables port forward (multi dport)

That God no, but I did have to force Splunk to tail a hard file versus a FIFO because it can't keep up (pathetic) and had to abandon my efforts at a UDP listener because it bound to the external interface instead of ANY.
evilghost is offline   Reply With Quote
Reply


Thread Tools

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 On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 10:58 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.