From: Gert Doering Date: Wed, 12 Nov 2025 10:39:05 +0100 Message-ID: <20251112093911.24196-1-gert@...1296...> In-Reply-To: References: MIME-Version: 1.0 Subject: [Openvpn-devel] [PATCH v3] iservice: validate config path case-insensitive List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit To: openvpn-devel@lists.sourceforge.net From: Heiko Hund Windows filesystems do not differentiate by case, so we shouldn't either. Reported-by: stephan@...2953... Change-Id: I4d905da3add9b8a3daf349eb1bc830a017cf493d Signed-off-by: Heiko Hund Acked-by: Lev Stipakov Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1362 --- This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master. Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1362 This mail reflects revision 3 of this Change. Acked-by according to Gerrit (reflected above): Lev Stipakov diff --git a/src/openvpnserv/validate.c b/src/openvpnserv/validate.c index b3189b7..3381503 100644 --- a/src/openvpnserv/validate.c +++ b/src/openvpnserv/validate.c @@ -78,7 +78,7 @@ res = PathCchCanonicalize(config_path, _countof(config_path), fname); } - return res == S_OK && wcsncmp(config_path, s->config_dir, wcslen(s->config_dir)) == 0; + return res == S_OK && wcsnicmp(config_path, s->config_dir, wcslen(s->config_dir)) == 0; }