All of lore.kernel.org
 help / color / mirror / Atom feed
* Preliminary NetBIOS datagram NAT filter
@ 2005-02-24  4:38 Constantine Sapuntzakis
  2005-03-01 10:02 ` Harald Welte
  0 siblings, 1 reply; 2+ messages in thread
From: Constantine Sapuntzakis @ 2005-02-24  4:38 UTC (permalink / raw)
  To: netfilter-devel

http://suif.stanford.edu/~csapuntz/ip_nat_netbios.c

Using this, I was able to join a Windows NT domain and login into the
domain from behind a NAT.

I had a hard time understanding all the parameters to the various
methods, so I probably got it wrong for anything except for source NAT
(which I tested). I'd appreciate any help from more experienced
developers.

Here's the problem with NetBIOS. NetBIOS datagrams contain the source
IP address and
source port as bytes 4-9 of the UDP payload. These need to be
rewritten while traversing a NAT.

Here are some questions:

- the HOWTO seems to indicate you want to override
hlpr->tuple.dst.u.udp.port but all the examples override
hlpr->tuple.src.u.udp.port  to filter all traffic to a port. Which is
right?

- will this NAT helper work with two computers with different IP
addresses behind a NAT? i.e. if both computers send packets with
source port 138 and destination port 138, will it correctly move the
source port number of one of the packets. Or do I have to call some
extra functions.

- will this code work for other things that rewrite the source
address? What do I need to do to make it work?

Thanks,
-Costa

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-03-01 10:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-02-24  4:38 Preliminary NetBIOS datagram NAT filter Constantine Sapuntzakis
2005-03-01 10:02 ` Harald Welte

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.