LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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-07-2004, 03:54 PM   #1
tvynr
Member
 
Registered: Apr 2004
Distribution: Debian
Posts: 143

Rep: Reputation: 15
Question BitTorrent Tracker Behaving Strangely When Run Through Linux Iptables Firewall


I am a novice Linux user maintaining my own firewall/router system which acts as a gateway for the little network I call home. The firewall works well for the most part; I can hit webpages like this one, play Starcraft on Battle.Net and run simple servers like FTP servers on the inside network, making them available to the outside world by tweaking the script properly.

I am attempting to run a BitTorrent tracker using the BitTorrent client Azureus. I have configured Azureus to use the IP address of the external machine and to run on port 6969. On the firewall/router, I have added the following lines to my rc.firewall script:

for protocol in tcp udp;
do
$IPTABLES -A $CHAIN -p $protocol --dport 6969 -j ACCEPT
$IPTABLES -t nat -A PREROUTING -d $EXT_IP -p $protocol --dport 6969 -j DNAT --to $NESTOR_IP
$IPTABLES -t nat -A POSTROUTING -s $NESTOR_IP -p $protocol --sport 6969 -j SNAT --to $EXT_IP
done
echo -n "*"

...where $EXT_IP is the firewall's external IP, $NESTOR_IP is the IP of the internal machine running the tracker, and $CHAIN is the name of a chain which later gets added to the INPUT, OUTPUT, and FORWARD chains. I've built this from a pattern I've established to work for most of my purposes.

In this case, however, it is not working. The tracker sees any BitTorrent client which does not force its IP address as having the internal IP address of the firewall. BitTorrent clients which force their IP addresses work fine.

Am I misconfigured somehow? I'm not sure if this is a firewall configuration problem or an issue I'm having with the BitTorrent protocol. Any advice is much appreciated.

The machine is based on a custom install of Slackware 9.0 with an upgrade to module-init-tools 3.0 and the Linux 2.6.5 kernel.

Thank you for your time, and cheers!
 
  


Reply


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
Second X Server behaving (at least to me) strangely exitsfunnel Linux - Software 2 05-13-2005 05:52 PM
Linux bittorrent tracker? robot5x Linux - Networking 3 10-09-2004 03:12 PM
PPP behaving strangely since network change. joe83 Slackware 5 09-25-2004 09:30 PM
ATI Drivers (or something) behaving strangely... doxxan Linux - Hardware 3 02-19-2004 02:37 PM
Unix/Perl/Sendmail behaving strangely! stephbock Linux - General 6 01-21-2003 03:56 PM

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

All times are GMT -5. The time now is 09:08 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