From patchwork Sun Nov 8 12:26:25 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gert Doering X-Patchwork-Id: 5610 Return-Path: Delivered-To: patchwork@openvpn.net Received: by 2002:a05:6022:3128:b0:118:2077:975e with SMTP id e40csp1812759laa; Sun, 8 Nov 2026 04:26:45 -0800 (PST) X-Forwarded-Encrypted: i=2; AL+hErEblY/rgsy1DQvN+Du0/zebhTqzP03E5G1f09cCmDKQ6MCYg5dOjz/V9ynDKHja9w8C/k4oHH+7x1A=@openvpn.net X-Received: by 2002:a05:701b:2088:20b0:1b2:4871:b1f7 with SMTP id a92af1059eb24-1b39fece051mr2203634c88.39.1794140804600; Sun, 08 Nov 2026 04:26:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1794140804; cv=none; d=google.com; s=arc-20260327; b=URZYLilPM5e1AKG5NqzlQCM46Czg+zdVzYr7B+2goehZNgj06w4SfA0dUtqXkpD2iZ 7gtH+Qwcoc0An4xbZFi3+ka5JK1nFmCum46v+aJETmkkCRnSflUNAexC11eRyYEP5w6Y TLFs8WuvOkeQJYDdsOXfxQ6+G0DAJohbMnNbmRhhcCWA7IkvWv+hs4pN+RvcqQ3UWmy9 wnRQgmxdkpzRp/LvNZLk6hg2xYpUbWRD4ZpCgOIixsfnDbECW1V+INBHckuyk5DXwdFL 8oayLy04m3/S04TCmB9LY76f8NYMb03meaVnntcrq+p0LtfvCU50BCEf5iEonRa9OpU7 mRUw== 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=Cxp9QCJwx/eslGI0o5XFUOCRbzERhvWRTsVw5vP+fdU=; fh=4NbAC/LsuMLI0S0hprUlLSLCiHwg6SCAifhH718Jh0Q=; b=E8rN5cLUR0rlWZGMbFxeHUpI6vUqEgFhk0HPsegqXTkIW1UV0gx/qT6cA2dnyNdUz4 skj052yTCjX3U7Y3JxhB5XLHbZYBbl9CBDCCMKwRH6Qv0TVnkzeMwpvWbrTrQpFZKGb0 RMif/+exe4puKisFEvsDRRsXolF+vKZ/TB5FF+ZZkjTB8g5hpG6v0Id4Bi4xgjV64PGD frXT2CPA/UsgBsLSYGaAlAN6C4+RQnNlxLpYjKJ0sfD+ANY7vW73EYwfOC+9T2VM8Gn5 MDPpVAqxR2WNUASN8keoI6laOdVA6bM8XtQtKB63lot0C06UyrieN7jEfedVpYEeMWs1 VUXQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lists.sourceforge.net header.s=beta header.b=IzJ+jvuh; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=Hho4udFb; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=cw7WJfaP; 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 a92af1059eb24-1b3752c3f2esi6408449c88.5.2026.11.08.04.26.44 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 08 Nov 2026 04:26:44 -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=IzJ+jvuh; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=Hho4udFb; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=cw7WJfaP; 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=Cxp9QCJwx/eslGI0o5XFUOCRbzERhvWRTsVw5vP+fdU=; b=IzJ+jvuhkpkdQu NjkMXhDgTvcUnMRHv5bk6GuXefGxBFXiCQ27QkVgvUHh2HQQjc0nLDCjrDIRgzTMbEh7n1eC04OrI u1MvwnGOrf7wiD2b3XL0vLI/DjuYIYLJIpxCcgghGMBTSgDpjPfOF+jsPKSGWXm8w4NUzJuSfQ6Va Xn8=; 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 1xQ1ys-000000006cE-0MSh; Sun, 08 Nov 2026 12:26:42 +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 1xQ1yq-000000006bz-0kFx for openvpn-devel@lists.sourceforge.net; Sun, 08 Nov 2026 12:26:40 +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=pCw6sgSphBgrw7AKFTKyp4olw0xW74rLVcPu2/PvL5Q=; b=Hho4udFbWIAGEEUphpbrlE7yAu QCInYXBj8l0xvJxdvWPgL1lpSfrJRzeGsfBQSdR8xeQwjJsIhaKskmXV5CmuZYuG2IShD79j6zO5N rDmtjC5quNLZp1m/qUoNLb+6Raz++PSsXC6+JVuXnqAQCglhW+tRFzULS53Y9LjPD8yw=; 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=pCw6sgSphBgrw7AKFTKyp4olw0xW74rLVcPu2/PvL5Q=; b=cw7WJfaPgNMW0GIrlhhUD2q/u+ WKunvkUID9lAIaLJLcRKpeIDWiBVctY8SyaJzaVFiikKA+5uGyV5CbumeBDGWcEuE4Ate2oqQEUtF Apt96M7x/X+jRaDkwOjkubP4NaCN4+E73jymzTIn87k7K8WTjpBh0PpPpBMEB5ieMWEQ=; Received: from [193.149.48.129] (helo=blue.greenie.muc.de) by sfi-mx-1.v28.lw.sourceforge.com with esmtps (TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.100.1) id 1xQ1yo-000000001P1-3Svv for openvpn-devel@lists.sourceforge.net; Sun, 08 Nov 2026 12:26:40 +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 6A8CQVXG010237 for ; Sun, 8 Nov 2026 13:26:31 +0100 Received: (from gert@localhost) by blue.greenie.muc.de (8.18.2/8.18.1/Submit) id 6A8CQVUI010236 for openvpn-devel@lists.sourceforge.net; Sun, 8 Nov 2026 13:26:31 +0100 From: Gert Doering To: openvpn-devel@lists.sourceforge.net Date: Sun, 8 Nov 2026 13:26:25 +0100 Message-ID: <20261108122630.10223-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-1.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: Alexandre Laroche CLEAR(dco) zeroes the local pointer variable instead of the dco_context_t it points to, so the context keeps the nl_cb and nl_cb_notify pointers that were just released with nl_cb_put(). 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: 1xQ1yo-000000001P1-3Svv Subject: [Openvpn-devel] [PATCH v1] dco_linux: clear the context, not the pointer, in ovpn_dco_uninit_netlink() 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: 1881292988022393475 X-GMAIL-MSGID: 1881292988022393475 From: Alexandre Laroche CLEAR(dco) zeroes the local pointer variable instead of the dco_context_t it points to, so the context keeps the nl_cb and nl_cb_notify pointers that were just released with nl_cb_put(). No functional change today, since close_tun() frees the tuntap right after, but use CLEAR(*dco) as intended. GitHub: closes OpenVPN/openvpn#1143 Assisted-by: Claude Code:claude-opus-5-5 Change-Id: Idb22f731a00158ff020a819081a07e1235d8323d Signed-off-by: Alexandre Laroche Acked-by: Arne Schwabe Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2156 --- 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/+/2156 This mail reflects revision 1 of this Change. Acked-by according to Gerrit (reflected above): Arne Schwabe diff --git a/src/openvpn/dco_linux.c b/src/openvpn/dco_linux.c index 4412ad0..a84e310 100644 --- a/src/openvpn/dco_linux.c +++ b/src/openvpn/dco_linux.c @@ -537,7 +537,7 @@ nl_cb_put(dco->nl_cb); nl_cb_put(dco->nl_cb_notify); - CLEAR(dco); + CLEAR(*dco); } int