From patchwork Wed Dec 2 15:16: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: 5838 Return-Path: Delivered-To: patchwork@openvpn.net Received: by 2002:a05:6022:91c9:10b0:11b:d6c:f273 with SMTP id tl9-n1csp16429555lad; Wed, 2 Dec 2026 07:16:37 -0800 (PST) X-Forwarded-Encrypted: i=2; AL+hErHKAtlJdAXKy0yhWuEI91hawUViLKg8PpoFzD0d/2GW9ySYGHKqDSSaVs9SjyfGyxnWjjZh9pm+sE0=@openvpn.net X-Received: by 2002:a05:7301:6181:10b0:386:b2ac:1f17 with SMTP id 5a478bee46e88-386b2ac2832mr31410720eec.7.1796224597408; Wed, 02 Dec 2026 07:16:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1796224597; cv=none; d=google.com; s=arc-20260327; b=jvPtVc4lg0gtR3HrGRzh9EVCd9DD2fjinI44nSD/aVqoRbxQjshtZaeec+/mRBjgrW QXAPNBZP8w2cx4G+wWGA9/EmaUvKWCqqAeA4qIRcNJjoN9os18PP+JWa81Iey0hW10ll eBLqHAySvko8Eb3RHIrS7nyqeKn0U8bC7ygwIb9y/IzVtHmhslbny9/oiKRBOiXk2NEa L9Crl42wnBxoc7qcx2fAKM/G8esWvc1UikuTNbN205ZevXMPVY4NguDLdZhzLL+rmL6H VAk+mQbfvqSqVsIfh0d9dFvAw4+jRiAbiWS3JOynWKt+aLA4UdKXus/iONrZleUt0fW/ P++w== 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=JqZ/digftli+lG/W2cNWEzkgCvKjKtmesNymwl+08ZM=; fh=4NbAC/LsuMLI0S0hprUlLSLCiHwg6SCAifhH718Jh0Q=; b=K2DzOJzLzTBQbgA0ZRGhSCFEqmctThE5AFSftft8qXWZeqnr2NACT5cJEvTTkxW6V9 XFPGlZO6ifR9MGO3WgQSPi6IUMFEQ/qTnFUgDTUhPpD6WVQNlV21K3MsjMpGT4xGHqDf OrT9Q26HGjqGkUkoaQzFyPB6pekzfucGNEI/w+gFgr477i230swzJhCgFBrwy94dm4xb ZIZDMDHZznwPT5h5dzUTb0bxKBji1qvcJBzsQb41T/3j1YDGXwCWb9O4W02MNr5Xn7xJ TBdtV3aGxsDJB+ENkg3zTsKbK4gIuqFOo4XRgFGQ9CO7F3//JjFnWx39MvuUY06o46mh 7GMQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lists.sourceforge.net header.s=beta header.b=REQp9uDF; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=UrK+VQNv; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=a3R93Fa0; 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 5a478bee46e88-385673cc055si100925708eec.32.2026.12.02.07.16.36 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 02 Dec 2026 07:16: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=REQp9uDF; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b=UrK+VQNv; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=a3R93Fa0; 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=JqZ/digftli+lG/W2cNWEzkgCvKjKtmesNymwl+08ZM=; b=REQp9uDF+8ZbUz O3BjCEV31P8xC7gLWX8yuOY8y+NwqXY2bYzzV13LFNlPQn/EiIyM+ZSmfGdm9NneJQk0rc+coSvI0 QM5z1kW8P53B9deJL5hnpssItwXfg5ikQDEPpLe1/nyiSV5amvMI5dfBCtNZlvIo9solW1WO20o3o GkA=; 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 1xYm4Q-000000003Ez-3rvi; Wed, 02 Dec 2026 15:16: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 1xYm4P-000000003Ek-18EN for openvpn-devel@lists.sourceforge.net; Wed, 02 Dec 2026 15:16: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=LP1GQYtDC+Wg58d6ilV0p/B8zVZ62+ESuhwQKl1xjhE=; b=UrK+VQNv5fbr7ALn/ZWIoUEnvR 3AeMMPvdP8vHzLy7b2FKm31Jy6stHkHAWTYIjjymlstHgLLdfu3Ub26BmVbnjLm+bixzTmIAaWE5X CteJrywmVfMTaD3Etcyvyk+tm8dTmChFN4UMgH+cSUI03ve5ASzC3dxi+UaeSAY7CkV8=; 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=LP1GQYtDC+Wg58d6ilV0p/B8zVZ62+ESuhwQKl1xjhE=; b=a3R93Fa02gbqIwFbdojdjcj6GD wsgo3TDiOJlYyORL/6guyHGkBrXiZercT2oh3k+XOXu01Sit7SorSRBb6neMdBDMstY7wrqRqPJW9 kjznbLGjQDhdEoRWPYKO7rY7Y/fkfbGFEb3qPS9amUNu5dgczdEvVfZh2xSBwXX0YZuo=; 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 1xYm4N-000000007BT-1Ocb for openvpn-devel@lists.sourceforge.net; Wed, 02 Dec 2026 15:16: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 6B2FGOdf021496 for ; Wed, 2 Dec 2026 16:16:24 +0100 Received: (from gert@localhost) by blue.greenie.muc.de (8.18.2/8.18.1/Submit) id 6B2FGOln021495 for openvpn-devel@lists.sourceforge.net; Wed, 2 Dec 2026 16:16:24 +0100 From: Gert Doering To: openvpn-devel@lists.sourceforge.net Date: Wed, 2 Dec 2026 16:16:18 +0100 Message-ID: <20261202151624.21484-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: Razvan Cojocaru A UDP packet from 0.0.0.0 (sent to 255.255.255.255) or from :: crashed the receiving process before any authentication: - p2p without --remote: link_socket_bad_incoming_addr() dereferenced the NULL remote_list - server: the stateless HMAC reset reply was sent to the unspecified address and hit the ASSERT in process_out [...] 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: 1xYm4N-000000007BT-1Ocb Subject: [Openvpn-devel] [PATCH v2] forward: drop datagrams from an unspecified source address 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: 1883478003440771490 X-GMAIL-MSGID: 1883478003440771490 From: Razvan Cojocaru A UDP packet from 0.0.0.0 (sent to 255.255.255.255) or from :: crashed the receiving process before any authentication: - p2p without --remote: link_socket_bad_incoming_addr() dereferenced the NULL remote_list - server: the stateless HMAC reset reply was sent to the unspecified address and hit the ASSERT in process_outgoing_link(); 2.5 crashed like p2p instead tls-auth/tls-crypt don't prevent it on a server, since a replayed client reset is answered. Such packets can be sent by hosts on the same link, and by authenticated clients of a TAP server through their tunnel. Drop them right after reading, before any other processing. CVE: 2026-142094 Change-Id: I625256cd3a3054cf94510137f3f4579fc5e8098c Signed-off-by: Razvan Cojocaru Acked-by: Ralf Lici Gerrit URL: https://gerrit.openvpn.net/c/openvpn-private/+/2387 --- This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to release/2.6. Gerrit URL: https://gerrit.openvpn.net/c/openvpn-private/+/2387 This mail reflects revision 2 of this Change. Acked-by according to Gerrit (reflected above): Ralf Lici diff --git a/src/openvpn/forward.c b/src/openvpn/forward.c index 2255951..eb43944 100644 --- a/src/openvpn/forward.c +++ b/src/openvpn/forward.c @@ -986,6 +986,15 @@ /* Remove socks header if applicable */ socks_postprocess_incoming_link(c); + /* A datagram from an unspecified source address (0.0.0.0 or ::) + * cannot be answered, and later processing assumes a defined peer */ + if (c->c2.buf.len > 0 && proto_is_udp(c->c2.link_socket->info.proto) + && !link_socket_actual_defined(&c->c2.from)) + { + msg(D_LINK_ERRORS, "UDP: dropping packet from unspecified source address"); + c->c2.buf.len = 0; + } + perf_pop(); }