From patchwork Mon Mar 25 14:30:49 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "plaisthos (Code Review)" X-Patchwork-Id: 3670 Return-Path: Delivered-To: patchwork@openvpn.net Received: by 2002:a05:7000:c315:b0:55c:c090:46f0 with SMTP id jk21csp2464918mab; Mon, 25 Mar 2024 07:31:21 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCUrjY3WW39y5CKCB99zhg8V5k3rsmBLs4VfNQQdJCP87yiZg2HDgfDQts5UtSb2zK49HWYe8WwbiW848trxbg0fMpV5in8= X-Google-Smtp-Source: AGHT+IFVMBuko14JtONA0B0B1O4BoYplsVD6QZj1JKgwIGX/bV1IMCAQRUovC0IzCoyyNF9mX8ui X-Received: by 2002:a05:6a00:84ca:b0:6ea:b1f5:8aa with SMTP id gl10-20020a056a0084ca00b006eab1f508aamr1298228pfb.3.1711377081190; Mon, 25 Mar 2024 07:31:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1711377081; cv=none; d=google.com; s=arc-20160816; b=DbzxX1Ayta2Orrcbdwl0RniEAgqRYOpru+d9L+zhlK2kvKa9UvGtff+SxFSkoXs216 uzRYri7JfFMR6TocI1sTqrfFfVXXhni8qxc50OLAq5Ghv2bTg6XKgWKySmJpXLRCspPn aJT2VViBS19f8J0vAJt3Br7S+2cNw7SWj+wkuAyJMCr3oia7uVNnyd3Fdam/701e9WOi p+GxRPXiQhU+Pe41oKEI6wQtUCSF5nIpnPAzPLESVq+jXz/N9rtBx/AvgFQJmslW3pMT saiD4/ktrWUeO3TId6daWf3zQUXwJMY8NRbrW1B6INikWCkn9+rRCNRbnwmY8j7BcXu5 vKlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:cc:reply-to:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence:subject:user-agent :mime-version:message-id:references:auto-submitted:to:date:from :dkim-signature:dkim-signature:dkim-signature; bh=kwvjpQSQGWx4OijrFTEzIOI6zrSe1R78HG9aHsB7Bi4=; fh=GFP4qDxgyJ2WEPo/oeLZg3Mj4NqvY1j2nTvTt7psNwg=; b=ewWqcdiViKe0+oD5mTIXh8YUCIWguu5KSgvBw69z9DdSFnPGEyap5dN3pUX7M1JbhB z9L83z0hFP0A2krL7OmZ/ybIusB3NUq0E8APnUb8kjXfCgYEE8PY5gxrlarusIXOOca4 q34W4WubfZ09dsC0buVV7Bd1l4roSx29deeByVqvMvm19YVJsF+nA1rZfHfHeXDzrVY8 CkyO7Le+N1LKGiFvNcEugJc20GxFJV0VbBM5z79iN0swNQ468HxXcHEnSBwqWPAdViv2 RQQI1naFkivyUgL40wM+GY47fJCec7k6UEHV919ce/1VrFf6nqA2dF0uqv3xaPKDZnQI FSAQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=QIACsbsZ; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=Ze+VFQ0r; dkim=neutral (body hash did not verify) header.i=@openvpn.net header.s=google header.b="CclQr5b/"; 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=openvpn.net Received: from lists.sourceforge.net (lists.sourceforge.net. [216.105.38.7]) by mx.google.com with ESMTPS id cm17-20020a056a00339100b006e55bb4a15csi5419488pfb.125.2024.03.25.07.31.20 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 25 Mar 2024 07:31:21 -0700 (PDT) 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=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=QIACsbsZ; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=Ze+VFQ0r; dkim=neutral (body hash did not verify) header.i=@openvpn.net header.s=google header.b="CclQr5b/"; 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=openvpn.net 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.95) (envelope-from ) id 1rolLm-0005Tr-Vs; Mon, 25 Mar 2024 14:30:59 +0000 Received: from [172.30.20.202] (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.95) (envelope-from ) id 1rolLl-0005Tc-ID for openvpn-devel@lists.sourceforge.net; Mon, 25 Mar 2024 14:30:58 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=Content-Type:Content-Transfer-Encoding:MIME-Version :Message-ID:Reply-To:References:Subject:List-Unsubscribe:List-Id:Cc:To:Date: From:Sender:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:List-Help: List-Subscribe:List-Post:List-Owner:List-Archive; bh=BJQO0+sYYUZgMezcFYV9svwv5HoE2YQIqxHcnPASWGc=; b=QIACsbsZ18JE5lJVcK7cUyAQec EbMNVI3iHch/sw7m4X8fOyzOhdoS6HzqCn4zeNptyN5fAJPkc4YJ12pK8va0Y+a2GD4TkElBT73pN fZOzjMeirS9WzMa0V86+EvL1Q86IsAgK8V8IegVwePSTJ9YTy7EAwCsV1sGQrkc9FW2w=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Content-Type:Content-Transfer-Encoding:MIME-Version:Message-ID:Reply-To: References:Subject:List-Unsubscribe:List-Id:Cc:To:Date:From:Sender:Content-ID :Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To: Resent-Cc:Resent-Message-ID:In-Reply-To:List-Help:List-Subscribe:List-Post: List-Owner:List-Archive; bh=BJQO0+sYYUZgMezcFYV9svwv5HoE2YQIqxHcnPASWGc=; b=Z e+VFQ0r2isfdo77wQvdintTVPNbCd7B2ADf/bZlSzWl586gMyHW24rOwl77yV06fMlRdrGFbIOJdE utKUykMsTyBkjwwH8S1n+Z5EKKC2GQ4v3VaxRjvKZCacR4fJUyHmXoMGNmJYrr93MIa4VSkhCx5Ms 2NLpInXMU91m9Fmc=; Received: from mail-wm1-f42.google.com ([209.85.128.42]) by sfi-mx-2.v28.lw.sourceforge.com with esmtps (TLS1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.95) id 1rolLk-0003Ze-Um for openvpn-devel@lists.sourceforge.net; Mon, 25 Mar 2024 14:30:58 +0000 Received: by mail-wm1-f42.google.com with SMTP id 5b1f17b1804b1-4148a139b1bso4845765e9.2 for ; Mon, 25 Mar 2024 07:30:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=openvpn.net; s=google; t=1711377051; x=1711981851; darn=lists.sourceforge.net; h=user-agent:content-disposition:content-transfer-encoding :mime-version:message-id:reply-to:references:subject :list-unsubscribe:list-id:auto-submitted:cc:to:date:from:from:to:cc :subject:date:message-id:reply-to; bh=BJQO0+sYYUZgMezcFYV9svwv5HoE2YQIqxHcnPASWGc=; b=CclQr5b/9Jt6Mvl2/mgSDajiaB6ZKozVFOIBeJ2+ffirzDu1+7BWAcp/LFxzOfneTB ZlYXFcr9g25wZUS7YyWn9wf82Yd/KeLGoRfNSyhdIvWkvvoTAS4MgetD7FhVqkemSqIF LTf+D8nrX4soIpIx00BOWC9IXSepu5TT1hnJYL6TMGsohKU2CtdDwnH/6XvfqV6ZEXnv 2QKWejpwYGI8NpDppED+mRgv8WD7WA0ZIlnSJb1z0WgsTsnzzGAODdGbbeHwnh53uMIT j9eAdC2FYG/+WVn9L4hlSokVDTDAwUjA6y7NujrdruPi+bqgMRk5Z0Fw1LlGaTwvQF4X yF5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711377051; x=1711981851; h=user-agent:content-disposition:content-transfer-encoding :mime-version:message-id:reply-to:references:subject :list-unsubscribe:list-id:auto-submitted:cc:to:date:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=BJQO0+sYYUZgMezcFYV9svwv5HoE2YQIqxHcnPASWGc=; b=kumbzrRKUIhcZ/BLx08b37Uu0Vh+4HWU+NFeAeFd9DkfKrzmOAmqH5LKPvdiuxK022 KephtVcSjOrBKbnuPGOBh/jRpd9K5Yctqj7//474+qIdXyI5v3ZX0AQ0IU8YBs84bqsi QYEHKk2JKLxhv4JM8kag1nBDJhDzbGA731GujE11WCGB/XEZUGm0w17R+5e8GSpdlxjY S7gL+Zsh+g15zrWiGu0Ge5dWSpwN0oirq6t99qZPcAyAemMu9SQgZd8zGMRi1uZx/cB9 FEXRXL3PRggxeZImvuuuk2hmHYgDoe0+hhFOI2Fy2JjzJ0GtfehYhQaHHAGFejcewvG/ KDWg== X-Gm-Message-State: AOJu0Yy6PMaMurPbHguKfBcTZZIJBdBSRSlrB5XQcjniEQybIIAtczFl AMrY4q8S3qSQGmmcE7//E2awNMKO1RJwxXmDrUc2Hxfzq7i8gzkUsaAe6gu+ksQ= X-Received: by 2002:a5d:6d86:0:b0:341:d3b0:ae7d with SMTP id l6-20020a5d6d86000000b00341d3b0ae7dmr140863wrs.45.1711377050476; Mon, 25 Mar 2024 07:30:50 -0700 (PDT) Received: from gerrit.openvpn.in (ec2-18-159-0-78.eu-central-1.compute.amazonaws.com. [18.159.0.78]) by smtp.gmail.com with ESMTPSA id dv13-20020a0560000d8d00b0033e25c39ac3sm9639674wrb.80.2024.03.25.07.30.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Mar 2024 07:30:50 -0700 (PDT) From: "flichtenheld (Code Review)" X-Google-Original-From: "flichtenheld (Code Review)" X-Gerrit-PatchSet: 1 Date: Mon, 25 Mar 2024 14:30:49 +0000 To: plaisthos Auto-Submitted: auto-generated X-Gerrit-MessageType: newchange X-Gerrit-Change-Id: If0dcdde30879fd6185efb2ad31399c1629c04d22 X-Gerrit-Change-Number: 548 X-Gerrit-Project: openvpn X-Gerrit-ChangeURL: X-Gerrit-Commit: 13faa309cb58b658cae5c62b03e8ecaa1324e19e References: Message-ID: <8be38848bbb0b6931888dfd560d9f6c45897274d-HTML@gerrit.openvpn.net> MIME-Version: 1.0 User-Agent: Gerrit/3.8.2 X-Spam-Score: -0.2 (/) X-Spam-Report: Spam detection software, running on the system "util-spamd-1.v13.lw.sourceforge.com", 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: Attention is currently required from: plaisthos. Hello plaisthos, I'd like you to do a code review. Please visit Content analysis details: (-0.2 points, 6.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.128.42 listed in wl.mailspike.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.128.42 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 WEIRD_PORT URI: Uses non-standard port number for HTTP 0.0 HTML_MESSAGE BODY: HTML included in message -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.0 T_KAM_HTML_FONT_INVALID Test for Invalidly Named or Formatted Colors in HTML X-Headers-End: 1rolLk-0003Ze-Um Subject: [Openvpn-devel] [XS] Change in openvpn[master]: mbedtls: avoid warning with GCC 13+ 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: , Reply-To: frank@lichtenheld.com, arne-openvpn@rfc2549.org, openvpn-devel@lists.sourceforge.net Cc: openvpn-devel Errors-To: openvpn-devel-bounces@lists.sourceforge.net X-getmail-retrieved-from-mailbox: Inbox X-GMAIL-THRID: =?utf-8?q?1794508934248370251?= X-GMAIL-MSGID: =?utf-8?q?1794508934248370251?= X-getmail-filter-classifier: gerrit message type newchange Attention is currently required from: plaisthos. Hello plaisthos, I'd like you to do a code review. Please visit http://gerrit.openvpn.net/c/openvpn/+/548?usp=email to review the following change. Change subject: mbedtls: avoid warning with GCC 13+ ...................................................................... mbedtls: avoid warning with GCC 13+ crypto_mbedtls.c:568:1: error: conflicting types for ‘cipher_ctx_init’ due to enum/integer mismatch; have ‘void(mbedtls_cipher_context_t *, const uint8_t *, const char *, const mbedtls_operation_t)’ [...] [-Werror=enum-int-mismatch] crypto_backend.h:341:6: note: previous declaration of ‘cipher_ctx_init’ with type ‘void(cipher_ctx_t *, const uint8_t *, const char *, int)’ [...] Previous compiler versions did not complain. Change-Id: If0dcdde30879fd6185efb2ad31399c1629c04d22 Signed-off-by: Frank Lichtenheld --- M src/openvpn/crypto_mbedtls.c 1 file changed, 2 insertions(+), 1 deletion(-) git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/48/548/1 diff --git a/src/openvpn/crypto_mbedtls.c b/src/openvpn/crypto_mbedtls.c index 1a39752..91485cb 100644 --- a/src/openvpn/crypto_mbedtls.c +++ b/src/openvpn/crypto_mbedtls.c @@ -566,11 +566,12 @@ void cipher_ctx_init(mbedtls_cipher_context_t *ctx, const uint8_t *key, - const char *ciphername, const mbedtls_operation_t operation) + const char *ciphername, int enc) { ASSERT(NULL != ciphername && NULL != ctx); CLEAR(*ctx); + const mbedtls_operation_t operation = (mbedtls_operation_t)enc; const mbedtls_cipher_info_t *kt = cipher_get(ciphername); ASSERT(kt); size_t key_bitlen = mbedtls_cipher_info_get_key_bitlen(kt);