From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Taylor, Grant" Subject: Re: Prevent traceroutes Date: Fri, 20 May 2005 10:34:49 -0500 Message-ID: <428E0399.6020703@riverviewtech.net> References: <20050519232314.GA9369@bender.817west.com> <20050519233347.GA9462@bender.817west.com> <428D8638.4040301@riverviewtech.net> <428D954E.1010105@riverviewtech.net> <20050520152021.GA11737@bender.817west.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20050520152021.GA11737@bender.817west.com> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: netfilter-bounces@lists.netfilter.org Errors-To: netfilter-bounces@lists.netfilter.org Content-Type: text/plain; charset="us-ascii"; format="flowed" To: netfilter@lists.netfilter.org > please do this in -t mangle PREROUTING and not -t nat. filtering in > -t nat is poor form, and i know lots of people are probably emulating > your scripts. No problem. You heard him people, the mangle table is a better place to do this, so here is an updated script: iptables -t mangle -A PREROUTING -i $LAN -p udp -m recent --name Drop_Traceroute --update --seconds 200 --rdest -j DROP iptables -t mangle -A PREROUTING -i $LAN -p udp -m recent --name Drop_Traceroute --set --rdest -m ttl --ttl-eq 1 -j DROP iptables -t mangle -A PREROUTING -i $LAN -p icmp -m recent --name Drop_Traceroute --update --seconds 200 --rdest -j DROP iptables -t mangle -A PREROUTING -i $LAN -p icmp -m recent --name Drop_Traceroute --set --rdest -m ttl --ttl-eq 1 -j DROP I have just tested this and found it to be fully functional on my home router too. Have fun. :) Grant. . . .