From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ben Russo Subject: Re: snmptraps incomming on udp port 162 REDIRECT to 4162 not working? Date: 05 Nov 2002 14:13:46 -0500 Sender: netfilter-admin@lists.netfilter.org Message-ID: <1036523634.8715.58.camel@ben.mis.tnsi.com> References: <1036512998.8715.44.camel@ben.mis.tnsi.com> <200211051829.gA5ITOe19773@vulcan.rissington.net> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <200211051829.gA5ITOe19773@vulcan.rissington.net> Errors-To: netfilter-admin@lists.netfilter.org List-Help: List-Post: List-Subscribe: , List-Id: List-Unsubscribe: , List-Archive: Content-Type: text/plain; charset="us-ascii" To: Antony Stone Cc: netfilter@lists.netfilter.org On Tue, 2002-11-05 at 13:29, Antony Stone wrote: > On Tuesday 05 November 2002 4:16 pm, Ben Russo wrote: > > > Hi, > > > > I tried the following: > > > > iptables -t nat -p udp -m udp --dport 162 -j REDIRECT --to-ports 4162 > > > > Any ideas on how to make this work? > > You should have a "-A PREROUTING" in there. I'm not sure about the "-m udp" > - I presume this is something to do with loading modules for different > protocol support ? (I don't use modules, but I've seen this sort of thing > in other people's rules before.) > > Antony. Thanks Antony and Joel, I'm sorry I was a little confusing there... I had the "-A PREROUTING" in there when I typed it on the host, just not in the e-mail I sent to the list. Hopefully this will clear it up a little.... It still doesn't seem to work, but here is the output of the "iptables-save" # Generated by iptables-save v1.2.5 on Mon Nov 4 16:06:52 2002 *nat :PREROUTING ACCEPT [11:2077] :POSTROUTING ACCEPT [0:0] :OUTPUT ACCEPT [0:0] -A PREROUTING -p udp -m udp --dport 162 -j REDIRECT --to-ports 4162 COMMIT # Completed on Mon Nov 4 16:06:52 2002 # Generated by iptables-save v1.2.5 on Mon Nov 4 16:06:52 2002 *filter :INPUT ACCEPT [1814:266793] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [1073:147564] COMMIT # Completed on Mon Nov 4 16:06:52 2002 -Ben.