From patchwork Sat Nov 11 02:36:49 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gert Doering X-Patchwork-Id: 60 Return-Path: Delivered-To: patchwork@openvpn.net Delivered-To: patchwork@openvpn.net Received: from director2.mail.ord1d.rsapps.net ([172.27.255.58]) by backend31.mail.ord1d.rsapps.net (Dovecot) with LMTP id G6PHMUEAB1o+LgAAgoeIoA for ; Sat, 11 Nov 2017 08:50:57 -0500 Received: from proxy3.mail.iad3a.rsapps.net ([172.27.255.58]) by director2.mail.ord1d.rsapps.net (Dovecot) with LMTP id 69iWKkEAB1qSBwAAgYhSiA ; Sat, 11 Nov 2017 08:50:57 -0500 Received: from smtp47.gate.iad3a ([172.27.255.58]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by proxy3.mail.iad3a.rsapps.net (Dovecot) with LMTP id Y+M4JEEAB1rkaQAAYaqY3Q ; Sat, 11 Nov 2017 08:50:57 -0500 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.34.181.88] Authentication-Results: smtp47.gate.iad3a.rsapps.net; iprev=pass policy.iprev="216.34.181.88"; 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; dmarc=none (p=nil; dis=none) header.from=greenie.muc.de X-Classification-ID: 5799419a-c6e7-11e7-958a-842b2b73aeca-1-1 Received: from [216.34.181.88] ([216.34.181.88:33890] helo=lists.sourceforge.net) by smtp47.gate.iad3a.rsapps.net (envelope-from ) (ecelerity 4.2.1.56364 r(Core:4.2.1.14)) with ESMTPS (cipher=DHE-RSA-AES256-GCM-SHA384) id C6/2A-25115-140070A5; Sat, 11 Nov 2017 08:50:57 -0500 Received: from localhost ([127.0.0.1] helo=sfs-ml-2.v29.ch3.sourceforge.com) by sfs-ml-2.v29.ch3.sourceforge.com with esmtp (Exim 4.89) (envelope-from ) id 1eDWB1-000893-Rw; Sat, 11 Nov 2017 13:50:27 +0000 Received: from sfi-mx-2.v28.ch3.sourceforge.com ([172.29.28.192] helo=mx.sourceforge.net) by sfs-ml-2.v29.ch3.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89) (envelope-from ) id 1eDWB0-00088q-GQ for openvpn-devel@lists.sourceforge.net; Sat, 11 Nov 2017 13:50:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=Message-Id:Date:Subject:To:From:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding: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=XO4E+Zv+rbeK77ZpmEPuvtMYFRX3hAjv3+hxHGtQCnk=; b=Y9Qg5ilrNUQzzbqXjFoDKCCgWH 3tqUgc6LQCAzeR7ebDGBt3OugvmoEU/r1sFpk3r33YOgrokI3tTkITymujGvPLVysgd81bjYVVXTc ouM4jtgr3HZPLbrqdfVMUzYhO5TTkfqPv4cSvnEzXBcFpEyTAxLVu0g2hr4Bj5m2n2W0=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Message-Id:Date:Subject:To:From:Sender:Reply-To:Cc:MIME-Version: Content-Type:Content-Transfer-Encoding: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=XO4E+Zv+rbeK77ZpmEPuvtMYFRX3hAjv3+hxHGtQCnk=; b=I6Gwdep/HREUcDxlEH1Ixd8S4W esKHrixQ/9Z3OM+d4Y3CyOO3PFwXw2M4kZ5ELxoKiFRWGo9BIFK/lHli7t7SUY2hu7v6/q0prsqTv 30wc2CVl+drIwjwAlsjttfVN/fcKfkMPLEXnkqhKkVUFZuhpPVrQ93h4/i5N7zqrXy/o=; Received: from delta2.greenie.net ([194.97.144.211]) by sfi-mx-2.v28.ch3.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89) id 1eDWAy-0003Id-HV for openvpn-devel@lists.sourceforge.net; Sat, 11 Nov 2017 13:50:26 +0000 Received: from mobileV.green.sophos ([IPv6:2001:1a80:2000:1:dfb:d8a7:bc0c:c5ed]) (authenticated bits=0) by delta2.greenie.net (8.15.2/8.12.11) with ESMTPSA id vABDakT2043919 (version=TLSv1.2 cipher=AES256-SHA256 bits=256 verify=NO) for ; Sat, 11 Nov 2017 14:36:46 +0100 (CET) From: Gert Doering To: openvpn-devel@lists.sourceforge.net Date: Sat, 11 Nov 2017 14:36:49 +0100 Message-Id: <20171111133649.20192-1-gert@greenie.muc.de> X-Mailer: git-send-email 2.13.0 X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.6.2 (delta2.greenie.net [IPv6:2001:608:0:1007:a00:20ff:fefe:4bd2]); Sat, 11 Nov 2017 14:36:46 +0100 (CET) X-Virus-Status: Clean X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -0.0 SPF_PASS SPF: sender matches SPF record X-Headers-End: 1eDWAy-0003Id-HV Subject: [Openvpn-devel] [PATCH] Remove warning on pushed tun-ipv6 option. 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: , MIME-Version: 1.0 Errors-To: openvpn-devel-bounces@lists.sourceforge.net X-getmail-retrieved-from-mailbox: Inbox tun-ipv6 is a no-op nowadays, and we print a warning to let users know - which is not helpful for server-pushed tun-ipv6 (which might be the result of --server-ipv6 automatically pushing this). So, remove the warning if parsing pushed options. Also, remove the VERIFY_PERMISSION() call here which has side effects on the "which class of options got pushed, do we need to act on them later on?" flag set. Signed-off-by: Gert Doering --- src/openvpn/options.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/openvpn/options.c b/src/openvpn/options.c index 641a26e2..bbf65613 100644 --- a/src/openvpn/options.c +++ b/src/openvpn/options.c @@ -5233,8 +5233,10 @@ add_option(struct options *options, } else if (streq(p[0], "tun-ipv6") && !p[1]) { - VERIFY_PERMISSION(OPT_P_UP); - msg(M_WARN, "Note: option tun-ipv6 is ignored because modern operating systems do not need special IPv6 tun handling anymore."); + if ( !(permission_mask & OPT_P_PULL_MODE) ) + { + msg(M_WARN, "Note: option tun-ipv6 is ignored because modern operating systems do not need special IPv6 tun handling anymore."); + } } #ifdef ENABLE_IPROUTE else if (streq(p[0], "iproute") && p[1] && !p[2])