git: f23fa56df5df - stable/15 - tcp md5: fix accounting of ACK with bad signatures

From: Michael Tuexen <tuexen_at_FreeBSD.org>
Date: Fri, 23 Oct 2026 17:38:32 UTC
The branch stable/15 has been updated by tuexen:

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

commit f23fa56df5df61f967dcf7d5307cb6181a766776
Author:     Michael Tuexen <tuexen@FreeBSD.org>
AuthorDate: 2026-09-04 07:24:40 +0000
Commit:     Michael Tuexen <tuexen@FreeBSD.org>
CommitDate: 2026-10-23 17:37:21 +0000

    tcp md5: fix accounting of ACK with bad signatures
    
    When processing the ACK of the initial TCP handshake using the
    SYN cookie, don't increment the counter for unexpected
    signatures (tcps_sig_err_sigopt). The correct
    counter (tcps_sig_rcvbadsig) for bad signatures is already
    incremented in TCPMD5_INPUT().
    
    Reported by:            Hannes Elfert
    Reviewed by:            rscheff
    Differential Revision:  https://reviews.freebsd.org/D59302
    
    (cherry picked from commit 2fb53436cd05f65164d166ef3ab33660fe451470)
---
 sys/netinet/tcp_syncache.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/sys/netinet/tcp_syncache.c b/sys/netinet/tcp_syncache.c
index 7c1c1f95856a..9209970eee5a 100644
--- a/sys/netinet/tcp_syncache.c
+++ b/sys/netinet/tcp_syncache.c
@@ -1145,7 +1145,6 @@ syncache_expand(struct in_conninfo *inc, struct tcpopt *to, struct tcphdr *th,
 				    s, __func__);
 				free(s, M_TCPLOG);
 			}
-			TCPSTAT_INC(tcps_sig_err_sigopt);
 			return (-1); /* Do not send RST */
 		}
 #endif /* TCP_SIGNATURE */