From patchwork Tue Nov 17 17:25:18 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gert Doering X-Patchwork-Id: 5729 Return-Path: Delivered-To: patchwork@openvpn.net Received: by 2002:a05:7300:cb07:b0:37a:c59:1bbd with SMTP id nc7csp4922942dyb; Tue, 17 Nov 2026 09:25:37 -0800 (PST) X-Forwarded-Encrypted: i=2; AL+hErEBVPN2G94DwFu43Yh2PfQ85Oyn2UY1vdIhQ46bysdllnoPN8XulQLe0SmRG8qLMP8pEFzO75cpmHw=@openvpn.net X-Received: by 2002:a05:6830:91e:b0:862:cc8d:abae with SMTP id 46e09a7af769-862cc8db12cmr7605942a34.13.1794936337545; Tue, 17 Nov 2026 09:25:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1794936337; cv=none; d=google.com; s=arc-20260327; b=ssE/uR4P7HL0NnqMy5r3I0T+1ttpci9O0sAD9qyVc3edUcDXj1nG5rOf1vhSLbSH+s FOLvkROtYo4ga0ufa+tByQhMgXBlkGTTcDUyIUh/V1dZ5i8wyFkdrUs8ZNUg/Hvr67tR oIlL29YiHHSehQdtYDGfejqR5oZHRlUylCjxXlBPaNSso+/CccP76lrlSo7KUMCzUDot 8UzQC2CvWV8k6fwH9ZE4pMmJtRswYCG2RvZ1Vza9GDObzaoL2dlKGdLYcztjSSQslRPY EW3/2+sVmWzuZv1LlXCcXcpjmn7iVdEcJ4WGx5iiL/LIEZCZ7n+Q32HYuJvHmuLhzp+b tRJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=errors-to:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature:dkim-signature:dkim-signature; bh=XbVNSAJTKTbc/SBf/BwTkJmd15mqdz86z/R6WhC9Evs=; fh=4NbAC/LsuMLI0S0hprUlLSLCiHwg6SCAifhH718Jh0Q=; b=p6jBZUdDgsz1UDbLB4lbq+yg+MhHsdeN3px7ZtEdWVjFuE55YZFdsEVFXFjVkH4UYT Pm5DIucd/qrNKZXpDCHc2QTtCnFPBG88BjD0A0m2uJgZ6rcC3LXzA8n+03YmBc+Rnqli HBDb8gs2wLPkylLGp9EvcAbxmaFDsdvwez5fuHozap4rk2s2+NZhuHAmu6AVe9VMo/xq m6a+dluQuFVJ4m3Hg9fkffoqVEMP6lUNhhdwXxDun/2jt5YIWCprAQmxUEx0eD7yh+d5 f0/wJHV6M4pvDvt6XnXipebYWssubtmZdA2WIr4JGIGFIX6OnjQT9LP0Pw/9Qbl3kgbl U4eg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lists.sourceforge.net header.s=beta header.b="Ys6/Mg+S"; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b="W/rpMWtj"; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=CeY7taua; spf=pass (google.com: domain of openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as permitted sender) smtp.mailfrom=openvpn-devel-bounces@lists.sourceforge.net; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=muc.de Received: from lists.sourceforge.net (lists.sourceforge.net. [216.105.38.7]) by mx.google.com with ESMTPS id 46e09a7af769-862f01cd8ecsi42745a34.43.2026.11.17.09.25.37 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 Nov 2026 09:25:37 -0800 (PST) Received-SPF: pass (google.com: domain of openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as permitted sender) client-ip=216.105.38.7; Authentication-Results: mx.google.com; dkim=pass header.i=@lists.sourceforge.net header.s=beta header.b="Ys6/Mg+S"; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b="W/rpMWtj"; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=CeY7taua; spf=pass (google.com: domain of openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as permitted sender) smtp.mailfrom=openvpn-devel-bounces@lists.sourceforge.net; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=muc.de DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.sourceforge.net; s=beta; h=Content-Transfer-Encoding:Content-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: Subject:MIME-Version:References:In-Reply-To:Message-ID:Date:To:From:Sender: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Unsubscribe-Post: List-Owner; bh=XbVNSAJTKTbc/SBf/BwTkJmd15mqdz86z/R6WhC9Evs=; b=Ys6/Mg+SLymYsu vGQnH7gFXJ2okyCoiCnG5QVeZr6pClG8TVV0g5SBxGVS5WbVqWhGXEZPv+uEzrWGjKaqC5rIsjrjV j27dOORrdnEtkNGlnHZB+wM/aShH9wUD2BWQPiCiwlRHc6+BfJVRI6Fxr0zkz3Rc4BfEpzts/02jz cwc=; Received: from [127.0.0.1] (helo=sfs-ml-2.v29.lw.sourceforge.com) by sfs-ml-2.v29.lw.sourceforge.com with esmtp (Exim 4.100.1) (envelope-from ) id 1xTMw2-000000000Zq-3py3; Tue, 17 Nov 2026 17:25:34 +0000 Received: from [172.30.29.66] (helo=mx.sourceforge.net) by sfs-ml-2.v29.lw.sourceforge.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.100.1) (envelope-from ) id 1xTMw1-000000000Zb-1PwK for openvpn-devel@lists.sourceforge.net; Tue, 17 Nov 2026 17:25:33 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=Content-Transfer-Encoding:MIME-Version:References: In-Reply-To:Message-ID:Date:Subject:To:From:Sender:Reply-To:Cc:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Unsubscribe-Post:List-Subscribe:List-Post:List-Owner:List-Archive; bh=/ADB1IGlV8wy2fW0gkIWWRj5UTb4P3qVGo9pEiUyqhM=; b=W/rpMWtjwmgVfrSFTTuAjarfNK KDBgyKMCpmTMnOeZ//SNdVzYwCnChJvFhweMdQBLW4jddyCfLk9WXZHOL2yAzvF9tFp80ih64KBoM kMv36iTa7o3ai+TqtZpjkUL6pic0s6Wb3cPBK+fN2UK0CJyNvy9YnNQcEJNyzdHCaMgY=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To:Message-ID: Date:Subject:To:From:Sender:Reply-To:Cc:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Unsubscribe-Post: List-Subscribe:List-Post:List-Owner:List-Archive; bh=/ADB1IGlV8wy2fW0gkIWWRj5UTb4P3qVGo9pEiUyqhM=; b=CeY7tauauYAXdECcdtsqTaT2x8 Ph9zGlSgbb6IVQCLJ3jpTzkB0XZC81pLnkb/qVBndNtgMHkkz097YNKsHfbjktAx+skWWVGbab9IE T45WGCwfTd6n5V3zSY4UVTji/UwV9sIXsIY83hUiwR4MfoGb4k2B9zeImpAhHvfaunOE=; Received: from [193.149.48.129] (helo=blue.greenie.muc.de) by sfi-mx-2.v28.lw.sourceforge.com with esmtps (TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.100.1) id 1xTMvz-000000004QB-1azT for openvpn-devel@lists.sourceforge.net; Tue, 17 Nov 2026 17:25:33 +0000 Received: from blue.greenie.muc.de (localhost [127.0.0.1]) by blue.greenie.muc.de (8.18.1/8.18.1) with ESMTP id 6AHHPOgg011424 for ; Tue, 17 Nov 2026 18:25:24 +0100 Received: (from gert@localhost) by blue.greenie.muc.de (8.18.2/8.18.1/Submit) id 6AHHPOAJ011423 for openvpn-devel@lists.sourceforge.net; Tue, 17 Nov 2026 18:25:24 +0100 From: Gert Doering To: openvpn-devel@lists.sourceforge.net Date: Tue, 17 Nov 2026 18:25:18 +0100 Message-ID: <20261117172524.11381-1-gert@greenie.muc.de> X-Mailer: git-send-email 2.55.0 In-Reply-To: References: MIME-Version: 1.0 X-Spam-Score: 1.3 (+) X-Spam-Report: Spam detection software, running on the system "sfi-spamd-2.hosts.colo.sdot.me", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: From: Razvan Cojocaru Since 7d46ff17 dropped the -Wsign-conversion pragma, LibreSSL and AWS-LC CI builds fail: their SSL_CTX_set1_groups() takes a size_t length, but glistlen is an int. Content analysis details: (1.3 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.3 RDNS_NONE Delivered to internal network by a host with no rDNS X-Headers-End: 1xTMvz-000000004QB-1azT Subject: [Openvpn-devel] [PATCH v2] ssl_openssl: fix -Wsign-conversion in tls_ctx_set_tls_groups() X-BeenThere: openvpn-devel@lists.sourceforge.net X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: openvpn-devel-bounces@lists.sourceforge.net X-getmail-retrieved-from-mailbox: Inbox X-GMAIL-THRID: 1882127165115912318 X-GMAIL-MSGID: 1882127165115912318 From: Razvan Cojocaru Since 7d46ff17 dropped the -Wsign-conversion pragma, LibreSSL and AWS-LC CI builds fail: their SSL_CTX_set1_groups() takes a size_t length, but glistlen is an int. The buildbot LibreSSL builds pass because the headers also define SSL_CTX_set1_groups as a macro, and clang suppresses warnings in expansions of system header macros. CI includes the libraries with plain -I, so their headers aren't system headers and the warning fires. OpenSSL 1.1.1's macro passes the length to SSL_CTX_ctrl() as a long, so add openssl_groups_len_t to pick the type per library. Change-Id: I33123fe621512376410765031fc9ae68cdd91a6c Signed-off-by: Razvan Cojocaru Acked-by: Frank Lichtenheld Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2214 --- 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/+/2214 This mail reflects revision 2 of this Change. Acked-by according to Gerrit (reflected above): Frank Lichtenheld diff --git a/src/openvpn/openssl_compat.h b/src/openvpn/openssl_compat.h index 8309cee..ae182d2 100644 --- a/src/openvpn/openssl_compat.h +++ b/src/openvpn/openssl_compat.h @@ -61,6 +61,14 @@ typedef uint64_t openssl_opt_t; #endif +/* SSL_CTX_set1_groups() length: size_t in LibreSSL and AWS-LC, passed to + * SSL_CTX_ctrl() as long by OpenSSL 1.1.1's macro */ +#if defined(LIBRESSL_VERSION_NUMBER) || defined(OPENSSL_IS_AWSLC) +typedef size_t openssl_groups_len_t; +#else +typedef long openssl_groups_len_t; +#endif + /* Functionality missing in LibreSSL before 3.5 */ #if defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x3050000fL diff --git a/src/openvpn/ssl_openssl.c b/src/openvpn/ssl_openssl.c index 30ef383..b95de8e 100644 --- a/src/openvpn/ssl_openssl.c +++ b/src/openvpn/ssl_openssl.c @@ -535,7 +535,7 @@ ALLOC_ARRAY_CLEAR_GC(glist, int, groups_count, &gc); /* Parse allowed ciphers, getting IDs */ - int glistlen = 0; + openssl_groups_len_t glistlen = 0; char *tmp_groups = string_alloc(groups, &gc); const char *token;