NAT with Redirect

For removing rules I found something that works 100%. First list all the rules, including their line number.

iptables -t nat -L -n -v --line-number

You find the line number of the rule you want to delete and then execute:

iptables -t nat -D PREROUTING {rule-number-here}

Works like a champ. I’ve never need to do the -F.

I’ve always been looking for a way to have different extractors for different types of devices, but hit a brick wall when I have multiple devices that all want to use udp/514. Now that I have the NAT REDIRECT working, sky is the limit.

Thanks for your help.

2 Likes