From: djm@openbsd.org Date: Tue, 25 Nov 2025 00:52:00 +0000 (+0000) Subject: upstream: don't set the PerSourceNetBlockSize IPv6 mask if sscanf X-Git-Url: https://git.feebdaed.xyz/?a=commitdiff_plain;h=6157e1c41071fb0f5621868c38861934284268b1;p=0xmirror%2Fopenssh-portable.git upstream: don't set the PerSourceNetBlockSize IPv6 mask if sscanf didn't decode it. From Mingjie Shen via GHPR598 OpenBSD-Commit-ID: c722014e735cbd87adb2fa968ce4c47b43cf98b0 --- diff --git a/servconf.c b/servconf.c index 6d23c3686..6cdfb3cb6 100644 --- a/servconf.c +++ b/servconf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: servconf.c,v 1.436 2025/11/20 05:10:56 dtucker Exp $ */ +/* $OpenBSD: servconf.c,v 1.437 2025/11/25 00:52:00 djm Exp $ */ /* * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland * All rights reserved @@ -2044,7 +2044,8 @@ process_server_config_line_depth(ServerOptions *options, char *line, filename, linenum, keyword); if (*activep && options->per_source_masklen_ipv4 == -1) { options->per_source_masklen_ipv4 = value; - options->per_source_masklen_ipv6 = value2; + if (n == 2) + options->per_source_masklen_ipv6 = value2; } break;