From patchwork Wed Feb 28 02:19:18 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Sommerseth X-Patchwork-Id: 250 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 (Dovecot) with LMTP id XH3UKzCulloVHQAAIUCqbw for ; Wed, 28 Feb 2018 08:27:12 -0500 Received: from proxy19.mail.ord1d.rsapps.net ([172.30.191.6]) by director10.mail.ord1d.rsapps.net (Dovecot) with LMTP id 30VJADCullruNgAApN4f7A ; Wed, 28 Feb 2018 08:27:12 -0500 Received: from smtp9.gate.ord1c ([172.30.191.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by proxy19.mail.ord1d.rsapps.net (Dovecot) with LMTP id OrGKNjCullqJNAAAyH2SIw ; Wed, 28 Feb 2018 08:27:12 -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.105.38.7] Authentication-Results: smtp9.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; dmarc=none (p=nil; dis=none) header.from=openvpn.net X-Classification-ID: 15574ddc-1c8b-11e8-a89e-0026b95bddb7-1-1 Received: from [216.105.38.7] ([216.105.38.7:10532] helo=lists.sourceforge.net) by smtp9.gate.ord1c.rsapps.net (envelope-from ) (ecelerity 4.2.1.56364 r(Core:4.2.1.14)) with ESMTPS (cipher=DHE-RSA-AES256-GCM-SHA384) id C8/8C-28096-03EA69A5; Wed, 28 Feb 2018 08:27:12 -0500 Received: from [127.0.0.1] (helo=sfs-ml-1.v29.lw.sourceforge.com) by sfs-ml-1.v29.lw.sourceforge.com with esmtp (Exim 4.89) (envelope-from ) id 1er1kg-009YmA-Nf; Wed, 28 Feb 2018 13:26:34 +0000 Received: from [172.30.20.202] (helo=mx.sourceforge.net) by sfs-ml-1.v29.lw.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89) (envelope-from ) id 1er1kd-009Ylh-JX for openvpn-devel@lists.sourceforge.net; Wed, 28 Feb 2018 13:26:31 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=References:In-Reply-To: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:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=EUxjIM+m/vu+gxnBBlgzIBKYjILUxFRImbcDu4KWgdc=; b=iZvxF6NiT1TNtpbyFEOQPpWEtF fzllCz0OMERbZ7Rn4h9TsCfRqsCZs/9jS0w8Mq8NAND9yFUdxx+YmHPGOrzS4VZZuS6RSj15KUero x7usn5T4mDP5ExPCUUsjcJs38U8v8UibY73RKUx/bcbq1522Mdkxg606r2yT/vvPkWRs=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=References:In-Reply-To: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:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=EUxjIM+m/vu+gxnBBlgzIBKYjILUxFRImbcDu4KWgdc=; b=PlOEx9q0VHwKTbkDqXHLdkf7aF +zqOPnICnIOFIdELB2iKlxP7XTh7J4DH9PX6wX4Nj2KG8qs/YBJlQn2pUKhiGTe0PaF23kGP8mcze t4zlpm+ZTN0YCUhUrdIFDy6AQtxJlzf/1ACLQO7eBZ8LuAOAtOmA/6sTgmxawRl3hht4=; Received: from sfi-lb-mx.v20.lw.sourceforge.com ([172.30.20.201] helo=winterfell.topphemmelig.net) by sfi-mx-4.v28.lw.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89) id 1er1ka-008Nvw-Fw for openvpn-devel@lists.sourceforge.net; Wed, 28 Feb 2018 13:26:29 +0000 Received: from localhost (unknown [IPv6:::1]) by winterfell.topphemmelig.net (Postfix) with ESMTP id 55E71824372 for ; Wed, 28 Feb 2018 13:19:27 +0000 (UTC) Received: from winterfell.topphemmelig.net ([127.0.0.1]) by localhost (winterfell.topphemmelig.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 38uM1V7tPX0r for ; Wed, 28 Feb 2018 14:19:26 +0100 (CET) Received: from zimbra.sommerseth.email (zimbra.sommerseth.email [172.16.33.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by winterfell.topphemmelig.net (Postfix) with ESMTPS id 2B8AC80B051 for ; Wed, 28 Feb 2018 14:19:23 +0100 (CET) Received: from localhost (localhost [IPv6:::1]) by zimbra.sommerseth.email (Postfix) with ESMTP id A047B401FA45 for ; Wed, 28 Feb 2018 14:19:22 +0100 (CET) Received: from zimbra.sommerseth.email ([IPv6:::1]) by localhost (zimbra.sommerseth.email [IPv6:::1]) (amavisd-new, port 10026) with ESMTP id kwWucTR10joE for ; Wed, 28 Feb 2018 14:19:22 +0100 (CET) Received: from optimus.homebase.sommerseths.net (unknown [10.35.0.233]) by zimbra.sommerseth.email (Postfix) with ESMTPS id 59D64401FA3A for ; Wed, 28 Feb 2018 14:19:22 +0100 (CET) From: David Sommerseth To: openvpn-devel@lists.sourceforge.net Date: Wed, 28 Feb 2018 14:19:18 +0100 Message-Id: <20180228131918.12954-3-davids@openvpn.net> X-Mailer: git-send-email 2.13.5 In-Reply-To: <20180228131918.12954-1-davids@openvpn.net> References: <20180228131918.12954-1-davids@openvpn.net> X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. 0.2 HEADER_FROM_DIFFERENT_DOMAINS From and EnvelopeFrom 2nd level mail domains are different -0.0 SPF_PASS SPF: sender matches SPF record X-Headers-End: 1er1ka-008Nvw-Fw Subject: [Openvpn-devel] [PATCH 3/3] management: Warn if TCP port is used without password 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 It is not recommended to use --management on a TCP port without also adding a password authentication, as this can easily be abused by other users or processes being able to connect to the managmement interface. Thus issue a warning that this configuration is strongly discouraged. Signed-off-by: David Sommerseth Acked-By: Arne Schwabe --- src/openvpn/options.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/openvpn/options.c b/src/openvpn/options.c index 41a42cf2..e0c0894b 100644 --- a/src/openvpn/options.c +++ b/src/openvpn/options.c @@ -2170,6 +2170,14 @@ options_postprocess_verify_ce(const struct options *options, const struct connec { msg(M_USAGE, "--management-client-(user|group) can only be used on unix domain sockets"); } + + if (!(options->management_flags & MF_UNIX_SOCK) + && (!options->management_user_pass)) + { + msg(M_WARN, "WARNING: Using --management on a TCP port WITHOUT " + "passwords is STRONGLY discouraged and considered insecure"); + } + #endif /*