even without -same_ports | -m switch natd tries to allocate the same source port as in the original packet. PKT_ALIAS_SAME_PORTS flag is set up in LibAliasInit function, -m switch can also only set this flag. Probably this default behaviour is actually good, and that's the manpage should be shanged, not libalias :). Fix: Workaround: create and use a config have with same_ports no How-To-Repeat: run natd without -m and inspect incoming and outgoing packet ports with tcpdump.
I can confirm this. IMHO it's not a bug but a feature so it's the man page that should be fixed. Please note that this is a probably a doc bug. A patch for it follows: --- natd.8.old Tue Jun 7 20:12:22 2005 +++ natd.8 Tue Jun 7 20:13:07 2005 @@ -65,8 +65,6 @@ IP address is that of the current machine. For each packet changed in this manner, an internal table entry created to record this fact. -The source port number is also changed to indicate the table ent -applying to the packet. Packets that are received with a target IP of the current host a checked against this internal table. If an entry is found, it is used to determine the correct target @@ -110,8 +108,9 @@ Try to keep the same port number when altering outgoing packets. With this option, protocols such as RPC will have a better chanc of working. +Please note that this is the default behaviour. If it is not possible to maintain the port number, it will be si -changed as per normal. +changed. .It Fl verbose | v Do not call .Xr daemon 3 Best Regards -- Rionda aka Matteo Riondato G.U.F.I. Staff Member (http://www.gufi.org) FreeSBIE Developer (http://www.freesbie.org)
Responsible Changed From-To: freebsd-bugs->matteo I'll handle this
Responsible Changed From-To: matteo->freebsd-doc Reset PR assigned to inactive committer. Hat: gnats-admin
For bugs matching the following criteria: Status: In Progress Changed: (is less than) 2014-06-01 Reset to default assignee and clear in-progress tags. Mail being skipped