From patchwork Wed Aug 19 15:42:58 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Thorpe X-Patchwork-Id: 1396 Return-Path: Delivered-To: patchwork@openvpn.net Delivered-To: patchwork@openvpn.net Received: from director10.mail.ord1d.rsapps.net ([172.30.191.6]) by backend30.mail.ord1d.rsapps.net with LMTP id kGzGBW7VPV9sbQAAIUCqbw for ; Wed, 19 Aug 2020 21:44:14 -0400 Received: from proxy2.mail.ord1d.rsapps.net ([172.30.191.6]) by director10.mail.ord1d.rsapps.net with LMTP id yKW0BW7VPV9hcQAApN4f7A (envelope-from ) for ; Wed, 19 Aug 2020 21:44:14 -0400 Received: from smtp3.gate.ord1c ([172.30.191.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by proxy2.mail.ord1d.rsapps.net with LMTPS id KIQ6BW7VPV9oAgAAfawv4w (envelope-from ) for ; Wed, 19 Aug 2020 21:44:14 -0400 X-Spam-Threshold: 95 X-Spam-Score: 0 X-Spam-Flag: NO X-Virus-Scanned: OK X-Orig-To: openvpnslackdevel@openvpn.net X-Originating-Ip: [216.105.38.7] Authentication-Results: smtp3.gate.ord1c.rsapps.net; iprev=pass policy.iprev="216.105.38.7"; spf=pass smtp.mailfrom="openvpn-devel-bounces@lists.sourceforge.net" smtp.helo="lists.sourceforge.net"; dkim=fail (signature verification failed) header.d=sourceforge.net; dkim=fail (signature verification failed) header.d=sf.net; dkim=fail (signature verification failed) header.d=sparklabs.com; dmarc=none (p=nil; dis=none) header.from=sparklabs.com X-Suspicious-Flag: YES X-Classification-ID: a6427e98-e286-11ea-bbef-842b2b47481a-1-1 Received: from [216.105.38.7] ([216.105.38.7:42542] helo=lists.sourceforge.net) by smtp3.gate.ord1c.rsapps.net (envelope-from ) (ecelerity 4.2.38.62370 r(:)) with ESMTPS (cipher=DHE-RSA-AES256-GCM-SHA384) id 36/87-02642-D65DD3F5; Wed, 19 Aug 2020 21:44:13 -0400 Received: from [127.0.0.1] (helo=sfs-ml-4.v29.lw.sourceforge.com) by sfs-ml-4.v29.lw.sourceforge.com with esmtp (Exim 4.90_1) (envelope-from ) id 1k8Zbx-0007a0-82; Thu, 20 Aug 2020 01:43:25 +0000 Received: from [172.30.20.202] (helo=mx.sourceforge.net) by sfs-ml-4.v29.lw.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1k8Zbv-0007Zq-KY for openvpn-devel@lists.sourceforge.net; Thu, 20 Aug 2020 01:43:23 +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:Message-Id: Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=zie1gkQd78NlrOGhrZpG7UnX2EYNjWAw+KGV0Q+kc4Y=; b=aDYbmZ4JZTbOOzeZNKe2Ni4AS4 +9zRpVYRx5IN6LKaye0EmOqg0dhp61wWQQyjUHfZXMJnsS5+zJP1N9O3KpBZrXgV2smEE1iATvlrW YN3YDjMrFms9WjHf6G9dkpgM8e31v3S1vgW3fdnggiFJue2VPl1UAoVxoZNeXfJCc4zc=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Content-Transfer-Encoding:MIME-Version:Message-Id:Date:Subject:Cc:To:From :Sender:Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post: List-Owner:List-Archive; bh=zie1gkQd78NlrOGhrZpG7UnX2EYNjWAw+KGV0Q+kc4Y=; b=Y iBjVBGNGNsFWBy8b7vIVfmsgnaMc4f11O6++8K1BR/YT6Ftl1BT3GxHu1kNdriWGhTDiC/pUpc3U/ xyxe2WM2NE5I0bQTPlKqcvW+BjHXXbSUqyEHkKR9dxZKHwGYpknZcfIUzL1t9MIM3oY2nZTyVSUHf hv5TXXk6cqJ9AcYk=; Received: from silicon.sparklabs.com ([66.185.22.121]) by sfi-mx-4.v28.lw.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92.2) id 1k8Zbt-001poN-J3 for openvpn-devel@lists.sourceforge.net; Thu, 20 Aug 2020 01:43:23 +0000 Received: from silicon.sparklabs.com (localhost [127.0.0.1]) by silicon.sparklabs.com (Postfix) with ESMTP id 4BX6qH0dTLzPlJn for ; Thu, 20 Aug 2020 01:43:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=sparklabs.com; h= content-transfer-encoding:mime-version:x-mailer:message-id:date :date:subject:subject:to:from:from; s=dkim; t=1597887786; x= 1600479787; bh=pQ+9dMpYS3s7d6nDDABL+DWiHvufwV5FqedIcFxkRbo=; b=I mmCM5lIJFqmBNqapOiamKGjl1fCdbL87si5RVNTog+Bim8jI+rBRLatxVPhaZEqf lnAAisOfriI+8dk+kgVK0aKCW82g7YaMPXBPApNnrHO0J5bze3u61fErz+yKXI/H pYoTkfmXCB5IgOrtr6C/KuuPNXtnp0pK3eqkseHnXU= Received: from silicon.sparklabs.com ([127.0.0.1]) by silicon.sparklabs.com (silicon.sparklabs.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id Zt5CEu4IAuM3 for ; Thu, 20 Aug 2020 01:43:06 +0000 (UTC) Received: from ubuntu20.trametheka.net (pa49-181-247-211.pa.nsw.optusnet.com.au [49.181.247.211]) by silicon.sparklabs.com (Postfix) with ESMTPSA id 4BX6qF3WwKzPk9G; Thu, 20 Aug 2020 01:43:05 +0000 (UTC) From: Eric Thorpe To: openvpn-devel@lists.sourceforge.net Date: Wed, 19 Aug 2020 18:42:58 -0700 Message-Id: <20200820014258.38377-1-eric@sparklabs.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [URIs: sparklabs.com] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-Headers-End: 1k8Zbt-001poN-J3 Subject: [Openvpn-devel] [PATCH] Fixes a bug in management_callback_send_cc_message, should be strlen instead of sizeof 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 Signed-off-by: Eric Thorpe Acked-By: Arne Schwabe --- src/openvpn/init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/openvpn/init.c b/src/openvpn/init.c index dfa045b0..a785934a 100644 --- a/src/openvpn/init.c +++ b/src/openvpn/init.c @@ -312,7 +312,7 @@ management_callback_send_cc_message(void *arg, const char *parameters) { struct context *c = (struct context *) arg; - size_t len = strlen(command) + 1 + sizeof(parameters) + 1; + size_t len = strlen(command) + 1 + strlen(parameters) + 1; if (len > PUSH_BUNDLE_SIZE) { return false;