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=-2.1 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no 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 13B47C433DF for ; Fri, 12 Jun 2020 07:05:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E6FEA207D8 for ; Fri, 12 Jun 2020 07:05:15 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="tynlaPL/" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726517AbgFLHFP (ORCPT ); Fri, 12 Jun 2020 03:05:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43910 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726287AbgFLHFN (ORCPT ); Fri, 12 Jun 2020 03:05:13 -0400 Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [IPv6:2a00:1450:4864:20::129]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 42729C03E96F for ; Fri, 12 Jun 2020 00:05:12 -0700 (PDT) Received: by mail-lf1-x129.google.com with SMTP id h188so4902614lfd.7 for ; Fri, 12 Jun 2020 00:05:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-language:content-transfer-encoding; bh=PxILO0zFA/3ECeR2jEOpiAfS1WsZPICQO4MZEJnowa4=; b=tynlaPL/zHZB82LC/5aaQR/6IQYzDVPZrv1+CbAD6tzdsmlOoV0sO5xfC33d3fS2jc nDi6L0CGEmKvvudtTGUGRCpI/0AMZMnOz4REPzEI59JQuRmYeiFB5/GaGa+tYG6P/L+x lD/9Ahi1tw0aGkNVXzjDOtjujJkukoBo4+EE/BzH9FDZx1IcwrqJZiqS8cw+ioTAFwmw B3Xzvacu9zS4I0xAKRR5IU5rp/f4CQIN2NZ6KT4fSgXTKrpq0gr+Wi38qaXAp2MO69Dv lI/QwCMIfLTl5KbGCTeprnGIRlm2Yh9q1H67zvOllwaOLgQLGYk+bVmBH8g4wU9QeXrK mdgg== 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=PxILO0zFA/3ECeR2jEOpiAfS1WsZPICQO4MZEJnowa4=; b=mO79SuQ7SBaiUDdlp08L6cSIxQZ0tOEFtDYnuQIdm6xcGvsxtNrHNbM6gx167LVn/0 2VZ+gOmbRHdjBptxopO81RsUMPADbuVXJvwN6Svuu1GAD8XKmONNzYnnT7+RrE/J55de RXfWncuJPaIGtnBwWUKMVxftG2Qh7NVHfwDXS8OCxyHAkD6JtSRjwPET/gXuJ/QX0alB +KBtCAydq3rqwSekrSVWtnpeFK3Wspi7eUX3xmYBkavDe4CbpPgsCwXk8OF1EKr1ywEU ljWtOFzaUWznBXF8fbk0kVrsdzaUIx31PmFPzqOcKUhisdNixv0NkZ/s+FdXfG1DpYay MDbA== X-Gm-Message-State: AOAM530Z9xsCLUQJE4ur3sBhVliaJwyCUnBr/Y3hKCsMVr0DPAWqYAS9 t2v82MMv7Pbof5C9ioNmrQJUB8dT X-Google-Smtp-Source: ABdhPJzBc5yMqhqJtcTi34b6U9iYIi35KHCFk6UsUksBcRT5wAI3Q2lIUtVPlxSEjN0nierKWqsOZg== X-Received: by 2002:a19:ac08:: with SMTP id g8mr170970lfc.207.1591945509938; Fri, 12 Jun 2020 00:05:09 -0700 (PDT) Received: from [192.168.1.38] (88-114-211-119.elisa-laajakaista.fi. [88.114.211.119]) by smtp.gmail.com with ESMTPSA id m11sm1517392lfl.70.2020.06.12.00.05.08 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 12 Jun 2020 00:05:09 -0700 (PDT) Subject: Re: Are we on the wrong track? To: Russell Coker , selinux-refpolicy@vger.kernel.org References: <3243717.6S2XvbbdUs@liv> From: Topi Miettinen Message-ID: Date: Fri, 12 Jun 2020 10:05:07 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 In-Reply-To: <3243717.6S2XvbbdUs@liv> 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 12.6.2020 3.03, Russell Coker wrote: > The reference policy is getting an increasing number of domains and types with > an O(N^2) level of complexity for writing policy and an O(N^2) size of the > binary policy. In 2012 the binary policy on my machines was 560k, now it's > over 2M. The policy can be shrunk by disabling unused modules, mine is 760k because only 166 modules are enabled out of 506. Some of the modules are for more or less obsolete software (e.g. hal, rlogin, uucp), or they may target proprietary software, which may be of unknown relevance today. Perhaps they should be disabled by default, removed from refpolicy or moved aside to directory "extra" or "Attic"? The package installer could also propose groups like "all", "most", "recommended", "distro-only" (disable all 3rd party stuff), "minimal" to enable/disable modules. -Topi