Find the answer to your Linux question:
Results 1 to 6 of 6
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Block bittorrent download

    Hello all,
    I want to block bittorrent download through my gateway server.
    eth1-------------- local
    eth0------------- internet
    Running FC2

    Pls help me how to block bittorrents?

  2. #2
    Linux Guru Juan Pablo's Avatar
    Join Date
    Mar 2006
    A firewall should do it, My FC5 have a built in firewall that can block individual ports. Block the default bittorrent port ... of course
    Put your hand in an oven for a minute and it will be like an hour, sit beside a beautiful woman for an hour and it will be like a minute, that is relativity. --Albert Einstein
    Linux User #425940

    Don't PM me with questions, instead post in the forums

  3. #3
    Torrent users usually change the port from the default. Some trackers even throttle down clients connecting with the default port. The normal solution corporations use is to get a firewall with DPI (deep packet inspection), and configure it to block BT traffic. I haven't been able to find an open-source firewall with that kind of power.

    Your best bet is to block the other end. Find IPs for popular trackers and block them.

  4. $spacer_open
  5. #4
    My school has blocking systems like that. They are relatively easy to subvert. Anonymous proxies for example. You cant block all the IPs on the internet. Now it is standard for bit torrent programs that can hide the bit torrent protocol inside others.

  6. #5
    copy & past following in your terminal.

    #eth1 is local ip
    #eth0 is public ip

    # For blocking torrent & p2p applications.

    iptables -F FORWARD

    iptables -F -t nat

    iptables -A FORWARD -i eth1 -p tcp --destination-port 5051:65535 -o eth0 -j DROP

    iptables -A FORWARD -i eth1 -p udp --destination-port 5051:65535 -o eth0 -j DROP

    iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE

    #for transparent proxy (If you are using any )
    #if not working, give your public ip on the place of eth0
    iptables -t nat -A PREROUTING -s eth0 -p tcp --dport 80 -j ACCEPT
    iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 3128
    iptables -t nat -A POSTROUTING -j MASQUERADE

  7. #6
    SuperMod (Back again) devils casper's Avatar
    Join Date
    Jun 2006
    Chandigarh, India
    Hi batabai !

    Welcome to the LinuxForums !

    This thread is more than 3 years old. I would suggest you to post suggestions in a bit recent threads.
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts