opnsense-src/sys/netinet
Eugene Grosbein 1a356b8b90 ipfw nat and natd support multiple aliasing instances with "nat global" feature
that chooses right alias_address for outgoing packets that already have
corresponding state in one of aliasing instances. This feature works just fine
for ICMP, UDP, TCP and SCTP packes but not for others. For example,
outgoing PPtP/GRE packets always get alias_address of latest configured
instance no matter whether such packets have corresponding state or not.

This change unbreaks translation of transit PPtP/GRE connections
for "nat global" case fixing a bug in static ProtoAliasOut() function
that ignores its "create" argument and performs translation
regardless of its value. This static function is called only
by LibAliasOutLocked() function and only for packers other than
ICMP, UDP, TCP and SCTP. LibAliasOutLocked() passes its "create"
argument unmodified.

We have only two consumers of LibAliasOutLocked() in the source tree
calling it with "create" unequal to 1: "ipfw nat global" code and similar
natd code having same problem. All other consumers of LibAliasOutLocked()
call it with create = 1 and the patch is "no-op" for such cases.

PR:		218968
Approved by:	ae, vsevolod (mentor)
MFC after:	1 week
2017-05-10 19:41:52 +00:00
..
cc
khelp
libalias ipfw nat and natd support multiple aliasing instances with "nat global" feature 2017-05-10 19:41:52 +00:00
tcp_stacks When a SYN-ACK is received in SYN-SENT state, RFC 793 requires the 2017-04-26 06:20:58 +00:00
accf_data.c
accf_dns.c
accf_http.c
icmp6.h
icmp_var.h
if_ether.c
if_ether.h
igmp.c
igmp.h
igmp_var.h
in.c
in.h
in_cksum.c
in_debug.c
in_fib.c
in_fib.h
in_gif.c
in_jail.c
in_kdtrace.c
in_kdtrace.h
in_mcast.c
in_pcb.c
in_pcb.h
in_pcbgroup.c
in_prot.c
in_proto.c
in_rmx.c
in_rss.c
in_rss.h
in_systm.h
in_var.h
ip.h
ip6.h
ip_carp.c
ip_carp.h
ip_divert.c
ip_divert.h
ip_dummynet.h
ip_ecn.c
ip_ecn.h
ip_encap.c
ip_encap.h
ip_fastfwd.c
ip_fw.h
ip_gre.c
ip_icmp.c
ip_icmp.h
ip_id.c
ip_input.c
ip_mroute.c
ip_mroute.h
ip_options.c
ip_options.h
ip_output.c
ip_reass.c
ip_var.h
pim.h
pim_var.h
raw_ip.c
sctp.h
sctp_asconf.c
sctp_asconf.h
sctp_auth.c
sctp_auth.h
sctp_bsd_addr.c
sctp_bsd_addr.h
sctp_cc_functions.c
sctp_constants.h
sctp_crc32.c
sctp_crc32.h
sctp_dtrace_declare.h
sctp_dtrace_define.h
sctp_header.h
sctp_indata.c
sctp_indata.h
sctp_input.c
sctp_input.h
sctp_lock_bsd.h
sctp_os.h
sctp_os_bsd.h
sctp_output.c Set the DF bit for responses to out-of-the-blue packets. 2017-04-28 15:38:34 +00:00
sctp_output.h
sctp_pcb.c Allow SCTP to use the hostcache. 2017-04-29 19:20:50 +00:00
sctp_pcb.h
sctp_peeloff.c
sctp_peeloff.h
sctp_ss_functions.c
sctp_structs.h
sctp_syscalls.c
sctp_sysctl.c
sctp_sysctl.h
sctp_timer.c Don't set the DF-bit on timer based retransmissions. 2017-04-29 09:57:27 +00:00
sctp_timer.h
sctp_uio.h
sctp_usrreq.c Allow SCTP to use the hostcache. 2017-04-29 19:20:50 +00:00
sctp_var.h Use consistently uint32_t for mtu values. 2017-04-26 19:26:40 +00:00
sctputil.c Allow SCTP to use the hostcache. 2017-04-29 19:20:50 +00:00
sctputil.h Allow SCTP to use the hostcache. 2017-04-29 19:20:50 +00:00
siftr.c
tcp.h
tcp_debug.c
tcp_debug.h
tcp_fastopen.c
tcp_fastopen.h
tcp_fsm.h
tcp_hostcache.c
tcp_hostcache.h
tcp_input.c When a SYN-ACK is received in SYN-SENT state, RFC 793 requires the 2017-04-26 06:20:58 +00:00
tcp_lro.c Flush the LRO ctrl as soon as lro_mbufs fills up. There is no need to 2017-04-24 22:35:00 +00:00
tcp_lro.h
tcp_offload.c
tcp_offload.h
tcp_output.c
tcp_pcap.c
tcp_pcap.h
tcp_reass.c
tcp_sack.c
tcp_seq.h
tcp_subr.c
tcp_syncache.c
tcp_syncache.h
tcp_timer.c
tcp_timer.h
tcp_timewait.c
tcp_usrreq.c
tcp_var.h
tcpip.h
toecore.c
toecore.h
udp.h
udp_usrreq.c
udp_var.h
udplite.h