Handle DHCP replies with NAT44 forwarding enabled 72/11672/3
authorMatthew Smith <mgsmith@netgate.com>
Tue, 10 Apr 2018 20:29:55 +0000 (15:29 -0500)
committerOle Trøan <otroan@employees.org>
Thu, 12 Apr 2018 06:33:09 +0000 (06:33 +0000)
commit8eaa96d976338420e590eaa4672420b91e2161b5
treea0c82a725045fa3355e839b70ada75baa01cb02e
parent17225df81b6fbfedc49dbf1fccb6d68df5a44ce0
Handle DHCP replies with NAT44 forwarding enabled

When NAT44 forwarding is disabled, if a DHCP server-to-
client packet arrives on an outside interface, it is
handled correctly by setting the next node to the next
feature on the ip4-unicast feature arc, where it can be
processed.

When NAT44 forwarding is enabled, if a DHCP server-to-
client packet arrives, it is not handled any differently
than other packets and ends up going to ip4-lookup
which results in the packet being dropped.

Move the check for DHCP server-to-client packets outside
of the block that is executed if forwarding is disabled so
DHCP replies will be processed in either case.

Change-Id: Ia795cce3fd459f3252c2c17d53bb88ceaeaafca4
Signed-off-by: Matthew Smith <mgsmith@netgate.com>
src/plugins/nat/out2in.c