From patchwork Wed Aug 29 04:27:14 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Ehrhardt X-Patchwork-Id: 458 Return-Path: Delivered-To: patchwork@openvpn.net Delivered-To: patchwork@openvpn.net Received: from director9.mail.ord1d.rsapps.net ([172.31.255.6]) by backend30.mail.ord1d.rsapps.net (Dovecot) with LMTP id YxqlDYmthlt+XwAAIUCqbw for ; Wed, 29 Aug 2018 10:28:25 -0400 Received: from proxy3.mail.iad3b.rsapps.net ([172.31.255.6]) by director9.mail.ord1d.rsapps.net with LMTP id 0KkgC4mthlt0DAAAalYnBA ; Wed, 29 Aug 2018 10:28:25 -0400 Received: from smtp7.gate.iad3b ([172.31.255.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by proxy3.mail.iad3b.rsapps.net with LMTP id CBQWBYmthlvpEwAAM8Wetg ; Wed, 29 Aug 2018 10:28:25 -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: smtp7.gate.iad3b.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=fail (p=none; dis=none) header.from=canonical.com X-Suspicious-Flag: YES X-Classification-ID: c93f2e78-ab97-11e8-ad24-525400e292e5-1-1 Received: from [216.105.38.7] ([216.105.38.7:3229] helo=lists.sourceforge.net) by smtp7.gate.iad3b.rsapps.net (envelope-from ) (ecelerity 4.2.38.62370 r(:)) with ESMTPS (cipher=DHE-RSA-AES256-GCM-SHA384) id D4/0F-24875-88DA68B5; Wed, 29 Aug 2018 10:28:24 -0400 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.90_1) (envelope-from ) id 1fv1RO-0004aU-W5; Wed, 29 Aug 2018 14:27:26 +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.90_1) (envelope-from ) id 1fv1RO-0004aA-6E for openvpn-devel@lists.sourceforge.net; Wed, 29 Aug 2018 14:27:26 +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:Cc: To:From:Sender:Reply-To: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=qNUtFbJnUCB01XGECQEzfO8X8ULxjCSo9IpqlqDQmgA=; b=YgXJARJwHbYyW/dEpPFijSB+n2 di7vQjJiv+4I6kMOmZ2evPi/2IJtQ8L/3YP5CTAtoluseC20p+yGSYLo1dsGQxoKu+IMfkA9sG7su ztbcYtl0nigeEy9tZxLgOFIt0KFUFxOYXT79Bsh1n4Af5+vg04TNb8Jlv/bBYFxwyRaQ=; 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:Cc:To:From:Sender:Reply-To :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=qNUtFbJnUCB01XGECQEzfO8X8ULxjCSo9IpqlqDQmgA=; b=gnIlga6exInbb6tZEaau17m7Lx 9FFZS9mCyRrBj3+snXcu/1GbAt9yAric4vPMzM5DQrSv0OF7tCWf7KSBCbvNVRhOT7H8OP14vXAas hh6uURqHMUJrKUZzNxnuf1ypdGVPKRmuM/C5w8E1f05+M+JvcQN8gx11ab5Oe4Z1MRec=; Received: from youngberry.canonical.com ([91.189.89.112]) by sfi-mx-1.v28.lw.sourceforge.com with esmtps (TLSv1:AES256-SHA:256) (Exim 4.90_1) id 1fv1RM-002Oi4-8g for openvpn-devel@lists.sourceforge.net; Wed, 29 Aug 2018 14:27:26 +0000 Received: from 1.general.paelzer.uk.vpn ([10.172.196.172] helo=lap.fritz.box) by youngberry.canonical.com with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1fv1RF-0004Do-Sb; Wed, 29 Aug 2018 14:27:17 +0000 From: Christian Ehrhardt To: openvpn-devel@lists.sourceforge.net Date: Wed, 29 Aug 2018 16:27:14 +0200 Message-Id: <20180829142715.417-2-christian.ehrhardt@canonical.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180829142715.417-1-christian.ehrhardt@canonical.com> References: <20180829142715.417-1-christian.ehrhardt@canonical.com> X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. X-Headers-End: 1fv1RM-002Oi4-8g Subject: [Openvpn-devel] [PATCH 1/2] systemd: extend CapabilityBoundingSet for auth_pam 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 Auth_pam will require audit writes or the connection will be rejected as the plugin fails to initialize like: openvpn[1111]: sudo: unable to send audit message openvpn[1111]: sudo: pam_open_session: System error openvpn[1111]: sudo: policy plugin failed session initialization See links from https://community.openvpn.net/openvpn/ticket/918 for more. auth_pam is a common use case and capabilties for it should be allowed by the .service file. Fixes: #918 Signed-off-by: Christian Ehrhardt Acked-By: David Sommerseth --- distro/systemd/openvpn-server@.service.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/distro/systemd/openvpn-server@.service.in b/distro/systemd/openvpn-server@.service.in index a8366a04..d1cc72cb 100644 --- a/distro/systemd/openvpn-server@.service.in +++ b/distro/systemd/openvpn-server@.service.in @@ -11,7 +11,7 @@ Type=notify PrivateTmp=true WorkingDirectory=/etc/openvpn/server ExecStart=@sbindir@/openvpn --status %t/openvpn-server/status-%i.log --status-version 2 --suppress-timestamps --config %i.conf -CapabilityBoundingSet=CAP_IPC_LOCK CAP_NET_ADMIN CAP_NET_BIND_SERVICE CAP_NET_RAW CAP_SETGID CAP_SETUID CAP_SYS_CHROOT CAP_DAC_OVERRIDE +CapabilityBoundingSet=CAP_IPC_LOCK CAP_NET_ADMIN CAP_NET_BIND_SERVICE CAP_NET_RAW CAP_SETGID CAP_SETUID CAP_SYS_CHROOT CAP_DAC_OVERRIDE CAP_AUDIT_WRITE LimitNPROC=10 DeviceAllow=/dev/null rw DeviceAllow=/dev/net/tun rw