Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3BA4CC43387 for ; Thu, 3 Jan 2019 00:27:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0B2962073F for ; Thu, 3 Jan 2019 00:27:53 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=ieee.org header.i=@ieee.org header.b="aYKxllTS" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728089AbfACA1w (ORCPT ); Wed, 2 Jan 2019 19:27:52 -0500 Received: from mail-qk1-f196.google.com ([209.85.222.196]:42148 "EHLO mail-qk1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725985AbfACA1w (ORCPT ); Wed, 2 Jan 2019 19:27:52 -0500 Received: by mail-qk1-f196.google.com with SMTP id 68so18847238qke.9 for ; Wed, 02 Jan 2019 16:27:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ieee.org; s=google; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-language:content-transfer-encoding; bh=qcnP4NvPHH7MBOdUuZR5FVJEBkXILR3LECYeNTh+QNo=; b=aYKxllTSQWh7B3qCmvZc3wzPbBlR0v7bjsUSmij66g82v9jJNS022nECNe9gRF3ZAI OrvdH0GavFKCoM0eF3KAFdJ4TyFIjeKukxuUYpiRd+qEMd4BNEWqTnHp6o63YwinQOHG 5Oi4cy4ZofLFoXw1FRuRJG5pYdBnc6HstObUA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=qcnP4NvPHH7MBOdUuZR5FVJEBkXILR3LECYeNTh+QNo=; b=DqMJfI+VYAIlqt9UufydiyPCJyWwjkBBOZ6h8DuARMTwwWe3K4T/ConrVsNWI8qbiO OT1MXU8ber7QJ4kmHG5Ptz1XkXkcjGMmCloVheZSgbP05j1ed0iVpCpzz6u+7W69v+Su 5JtZKy/dLBgb/hLgvMvCmarA4bcP/tTGHvNpwr9kpsoJQ75O28dRfmVDGQxSwkvnJWMG F/C4TJ91U1hLpE+n2ABIkGsdC0R1wvMpYVrXblZEZVejWzFnY2Y/LhfHJ1rOtsx/1Y5j TgRUSF7QkFqIK0A28jwlPtyZXmN/rMsWBtoHPNcTuMpO0J3YWk278Y6doT8gptyTTDk2 7xng== X-Gm-Message-State: AJcUukfPxrZBlxWMJ9g2e8CV6CuD1yFwbydrxruY5xgYmzLbwoBPXznk 0/KyTHTD7VuWNig8zkSWWefuhTrnRXI= X-Google-Smtp-Source: ALg8bN6czK6CIveL5XE0RyYhvlxPuLek4vg095CMLRwtXjm1bF2QOxjwnbWBTX/VCHtqWsH/NhAbSw== X-Received: by 2002:a37:c08:: with SMTP id 8mr41238462qkm.148.1546475271305; Wed, 02 Jan 2019 16:27:51 -0800 (PST) Received: from [192.168.1.190] (pool-108-15-23-247.bltmmd.fios.verizon.net. [108.15.23.247]) by smtp.gmail.com with ESMTPSA id q17sm28216020qtc.19.2019.01.02.16.27.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 02 Jan 2019 16:27:50 -0800 (PST) Subject: Re: [PATCH misc 2/3] selinuxutil sysnetwork consolekit apt dpkg udev iptables logrotate, and gpm To: Russell Coker , selinux-refpolicy@vger.kernel.org References: <20190102084500.GB31076@aaa.coker.com.au> From: Chris PeBenito Message-ID: Date: Wed, 2 Jan 2019 19:07:19 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.0 MIME-Version: 1.0 In-Reply-To: <20190102084500.GB31076@aaa.coker.com.au> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: selinux-refpolicy-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: selinux-refpolicy@vger.kernel.org On 1/2/19 3:45 AM, Russell Coker wrote: > Lots of little stuff. > > Also the sysnet_dns_name_resolve() change the previous patch needed. > [...] > --- refpolicy-2.20180701.orig/policy/modules/services/consolekit.te > +++ refpolicy-2.20180701/policy/modules/services/consolekit.te > @@ -27,7 +27,7 @@ init_daemon_pid_file(consolekit_var_run_ > # Local policy > # > > -allow consolekit_t self:capability { chown dac_override fowner setgid setuid sys_admin sys_nice sys_ptrace sys_tty_config }; > +allow consolekit_t self:capability { chown dac_override dac_read_search fowner setgid setuid sys_admin sys_nice sys_ptrace sys_tty_config }; Since you're getting the dac_read_search denial, the dac_override probably isn't necessary anymore. Can you retest without it? [...] > =================================================================== > --- refpolicy-2.20180701.orig/policy/modules/system/udev.te > +++ refpolicy-2.20180701/policy/modules/system/udev.te [...] > @@ -328,6 +324,11 @@ optional_policy(` > ') > > optional_policy(` > + iptables_domtrans(udev_t) > + iptables_write_pipe(udev_t) I'm not clear why this separate pipe interface is necessary, as that access should be provided by the domtrans interface already. > --- refpolicy-2.20180701.orig/policy/modules/system/iptables.if > +++ refpolicy-2.20180701/policy/modules/system/iptables.if > @@ -25,6 +25,24 @@ interface(`iptables_domtrans',` > > ######################################## > ## > +## Allow iptables to write to a pipe > +## > +## > +## > +## Domain to be written to > +## > +## > +# > +interface(`iptables_write_pipe',` Should be iptables_write_inherited_pipe(). > + gen_require(` > + type iptables_t; > + ') > + > + allow iptables_t $1:fifo_file write; > +') > + -- Chris PeBenito