NATting broadcasts

Thomas van Gulick list@utumno.student.utwente.nl
Sun, 9 Apr 2000 17:52:02 +0200


I'm trying to forward smb broadcast to a host behind my masquerading
gateway, thus

*:137-139 -> gateway -> hiddenhost

and

hiddenhost -> *:137-139 -> gateway

for this I added the rule:

iptables -t nat -A PREROUTING -j DNAT -p udp -i eth0 --dport 137:139 --to
hiddenhost:137-139

but this doesn't seem to work. Packets come in and  get counting for this
rule, and tcpdump shows the translated destination address, but packets
don't jup over to the other ethernet card on eth0, though I have the
following rule:

iptables -A FORWARD -j ACCEPT -i eth0 -o eth1 -s ! hiddennet -d hiddennet

I've read one message concerning broadcasts in the archives but I'm unsure
if it's about the same problem I'm facing ...

Could anyone explain how to 'tunnel' broadcast for a particular range of
ports through a gateway?

Thomas
--
Calslaan 40-31
7522 ME Enschede
053-4895047 (flat)
http://utumno.student.utwente.nl/