svn commit: r324790 - stable/11/sys/netpfil/ipfw

Andrey V. Elsukov ae at FreeBSD.org
Fri Oct 20 07:40:13 UTC 2017


Author: ae
Date: Fri Oct 20 07:40:11 2017
New Revision: 324790
URL: https://svnweb.freebsd.org/changeset/base/324790

Log:
  MFC r324593:
    Fix regression in handling O_FORWARD_IP opcode after r279948.
  
    To properly handle 'fwd tablearg,port' opcode, copy sin_port value from
    sockaddr_in structure stored in the opcode into corresponding hopstore
    field.
  
    PR:		222953

Modified:
  stable/11/sys/netpfil/ipfw/ip_fw2.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/netpfil/ipfw/ip_fw2.c
==============================================================================
--- stable/11/sys/netpfil/ipfw/ip_fw2.c	Fri Oct 20 04:02:53 2017	(r324789)
+++ stable/11/sys/netpfil/ipfw/ip_fw2.c	Fri Oct 20 07:40:11 2017	(r324790)
@@ -2442,6 +2442,7 @@ do {								\
 						sa6->sin6_len = sizeof(*sa6);
 						sa6->sin6_addr = TARG_VAL(
 						    chain, tablearg, nh6);
+						sa6->sin6_port = sa->sin_port;
 						/*
 						 * Set sin6_scope_id only for
 						 * link-local unicast addresses.
@@ -2455,6 +2456,8 @@ do {								\
 					} else
 #endif
 					{
+						args->hopstore.sin_port =
+						    sa->sin_port;
 						sa = args->next_hop =
 						    &args->hopstore;
 						sa->sin_family = AF_INET;


More information about the svn-src-all mailing list