nat table and perl problem

B

bjohnsme

I have a perl script that I use to mangle packets by hand rather than
using iptables to redirect for me. When I'm not using the perl script
though, I want to have ipmasquerading turned on. My problem is this:

My script runs fine so long as I don't ever run "iptables -t nat -F"
(or for that matter, anything that uses -t nat). I'm sending packets
using Net::RawSock.

Once one of those commands are run, is there a way to undo them? I've
tried stopping the service, but then running /etc/init.d/iptables
status still returns info.

How can I go about changing the rules so that it acts like a machine
without iptables running at all? I set the default policies to
accept, but this is no help either. Does anybody know if RawSock
does something funky when it sends out packets that could be
interfering with iptables? Any thoughts would be greatly
appreciated.
 
B

bjohnsme

I've found some more information out about this... the problem stems
from messing with the flag/offset bits in the packets. If I don't
muck with those, the packets go out fine... does anybody have any
ideas on how I could sneak these manipulated packets through NAT?
They seem get dropped no matter what...

thanks,
brad
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,432
Messages
2,571,680
Members
48,796
Latest member
Greg L.

Latest Threads

Top