The branch main has been updated by tuexen:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=de8fb1b3835758998a53d772deeebcdb71bbb823

commit de8fb1b3835758998a53d772deeebcdb71bbb823
Author:     Michael Tuexen <tue...@freebsd.org>
AuthorDate: 2025-06-13 20:53:42 +0000
Commit:     Michael Tuexen <tue...@freebsd.org>
CommitDate: 2025-06-13 20:53:42 +0000

    tcp: fix local blackholing
    
    The sysctl-variable net.inet.tcp.blackhole_local should affect
    TCP segments from an IPv6 address of the local host, not of a host
    on the local area network.
    Thanks to cc@ for pointing me to the issue.
    
    Reviewed by:            cc
    MFC after:              1 week
    Sponsored by:           Netflix, Inc.
    Differential Revision:  https://reviews.freebsd.org/D50828
---
 sys/netinet/tcp_input.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/netinet/tcp_input.c b/sys/netinet/tcp_input.c
index c00a102e8520..1c617b85ef89 100644
--- a/sys/netinet/tcp_input.c
+++ b/sys/netinet/tcp_input.c
@@ -1385,7 +1385,7 @@ dropwithreset:
            ((V_blackhole == 1 && (thflags & TH_SYN)) || V_blackhole > 1))) &&
            (V_blackhole_local || (
 #ifdef INET6
-           isipv6 ? !in6_localaddr(&ip6->ip6_src) :
+           isipv6 ? !in6_localip(&ip6->ip6_src) :
 #endif
 #ifdef INET
            !in_localip(ip->ip_src)

Reply via email to