Date: Tue, 25 Feb 2025 10:04:53 +0000 From: bugzilla-noreply@freebsd.org To: pf@FreeBSD.org Subject: [Bug 284946] pf: af-to fails when IPv4 nexthop is an IPv6 address Message-ID: <bug-284946-16861-mCFx85q6TR@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-284946-16861@https.bugs.freebsd.org/bugzilla/> References: <bug-284946-16861@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D284946 --- Comment #3 from commit-hook@FreeBSD.org --- A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=3D41265f65a549d919363e322a39cbf3ce0= 34c5de9 commit 41265f65a549d919363e322a39cbf3ce034c5de9 Author: Kristof Provost <kp@FreeBSD.org> AuthorDate: 2025-02-21 15:49:45 +0000 Commit: Kristof Provost <kp@FreeBSD.org> CommitDate: 2025-02-25 08:32:34 +0000 pf: cope with IPv6 gateways for an IPv4 route in nat64 It's possible for an IPv4 next hop to be specified as an IPv6 address. = This broke pf's route lookup in pf_route(), which is required for nat64. Handle this case just like ip_tryforward(): use the struct sockaddr from the struct nhop_object, and mark a struct route to indicate if_output() has= to use the gateway. Add a test case for this. PR: 284946 Reviewed by: zlei Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D49095 sys/netpfil/pf/pf.c | 40 +++++++++++++++------------- tests/sys/netpfil/pf/nat64.sh | 62 +++++++++++++++++++++++++++++++++++++++= ++++ 2 files changed, 83 insertions(+), 19 deletions(-) --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-284946-16861-mCFx85q6TR>