• [gentoo-dev] Rationalizing USE flags by narrowing the scope of them.

    From Piotr Karbowski@21:1/5 to All on Sat Jan 1 23:30:02 2022
    Hi,

    I'd like to get some insight how others see the concept of narrowing the
    scope of USE flags in Gentoo.

    Taking a quote from devmanual:

    > USE flags are to control optional dependencies and settings which
    the user may reasonably want to select.

    I'd like to focus on the 'reasonably want' here. While it is commonly
    agreed on that we interface as USE flags only things that make sense to
    be togglable, it is not always the case. It is not uncommon to see
    packages that puts every possible option as USE flag which hardly
    benefit anyone in some cases.

    It creates artificial choice of USE flag that makes as much sense as
    building and trying to use solar-powered night vision googles. Possible
    to be engineered, but makes absolute no sense to exist, yet, there will
    be someone who will go with it and then things will not work in desired
    way, bugs will be reported, effort will be wasted on investigation and
    patching things up.

    As example I'd like to use 'ipv6' USE flag, at the moment of writing
    this email there's 351 ebuilds in tree that expose ipv6 as USE flag,
    allow it to be disabled.

    The thing is, it's 2022, and it does not make any sense to *not* support
    IPv6, even if one does not connect to any network with IPv6, there's no
    harm to just have it there.

    While I am all for choice, I am for choice on things that do make sense.
    For instance, Linux kernel can be built with CONFIG_MULTIUSER=n, someone
    could argue that since Linux kernel, that is user-configured in Gentoo,
    can be built without support for other than UID 0, then Gentoo should
    support it. One of the extreme examples of not supporting something that
    does not make sense to be supported.

    Beside 'ipv6', there are other USE flags that I have on mind. 'pam'
    being another of them.

    Whats your view on it?

    -- Piotr.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Scott Ellis@21:1/5 to All on Sun Jan 2 01:10:01 2022
    Your `ipv6` USE flag hits home - I don't use IPv6, nor do I want to have
    IPv6 support built into things (just another potential "thing" that I have
    to secure, or errors/warnings I need to suppress since I run an IPv6-less kernel).

    If there needs to be a path to culling USE flags, perhaps looking to which flags actually cause packages to pull in additional dependencies (vs solely enable/disable a feature) would be a better place to start?

    ScottE

    <div dir="ltr">Your `ipv6` USE flag hits home - I don&#39;t use IPv6, nor do I want to have IPv6 support built into things (just another potential &quot;thing&quot; that I have to secure, or errors/warnings I need to suppress since I run an IPv6-less
    kernel).  <div><br></div><div><div>If there needs to be a path to culling USE flags, perhaps looking to which flags actually cause packages to pull in additional dependencies (vs solely enable/disable a feature) would be a better place to start?</div><
    <br></div><div>   ScottE</div></div></div>

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Blake Bartenbach@21:1/5 to Piotr Karbowski on Sun Jan 2 05:50:01 2022
    On Sat Jan 1, 2022 at 4:21 PM CST, Piotr Karbowski wrote:
    I'd like to focus on the 'reasonably want' here.


    I find that words like "reasonable" are generally useless. The issue
    is, it's completely subjective. Do you think the average
    person would think that using Gentoo is reasonable for their home
    computing? Is it resonable for grandma? I think it's reasonable for me.

    The thing is, it's 2022, and it does not make any sense to *not* support IPv6, even if one does not connect to any network with IPv6, there's no
    harm to just have it there.


    This kind of logic goes down a slippery slope very quickly though.
    "There's no harm to just have it there" kind of defeats the purpose of a configurable operating system.

    Beside 'ipv6', there are other USE flags that I have on mind. 'pam'
    being another of them.


    Well, I'm not sure about the pam one. The only USE flag that
    consistently baffles me is 'X'. It really does not seem to have a well
    defined definition, and it seems to do different things with different packages. For the longest time, I had that flag globally disabled, but
    used X and almost every package worked totally fine.

    -- Blake

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Sam James@21:1/5 to All on Sun Jan 2 08:40:02 2022
    On 2 Jan 2022, at 00:03, Scott Ellis <scotte@warped.com> wrote:

    Your `ipv6` USE flag hits home - I don't use IPv6, nor do I want to have IPv6 support built into things (just another potential "thing" that I have to secure, or errors/warnings I need to suppress since I run an IPv6-less kernel).

    If there needs to be a path to culling USE flags, perhaps looking to which flags actually cause packages to pull in additional dependencies (vs solely enable/disable a feature) would be a better place to start?


    Yep, that's a good idea, but please do see my other comments on IPv6. USE=ipv6 actually has some problematic properties
    aside from people wanting (or not wanting) IPv6.

    One reason being that it's often not even a supported configuration upstream, but there's others I mentioned too.

    Best,
    sam

    -----BEGIN PGP SIGNATURE-----

    iQGTBAEBCgB9FiEEYOpPv/uDUzOcqtTy9JIoEO6gSDsFAmHRVhdfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDYw RUE0RkJGRkI4MzUzMzM5Q0FBRDRGMkY0OTIyODEwRUVBMDQ4M0IACgkQ9JIoEO6g SDvBxQf/V0Oy3NmX0BCSj4mMdQBGISmIDBCbTON4cZnTnOzhX2aSXo58oRHq4vOA I3VROilFUSDNKwNq+Q6IpOTXR4oO0RO7MTsD0Posg5OufS/3sC0GVf8wtCOUO6Cb G0ljxeaWOkh/QGryIUvBPhd3Gn11rm6ZyU7JsQBSakRy9QdsyMl24Uhimg8qJkYh pceTtobUlKPhLJcS4SalsV+Jwt+AaClS6y82J+eUFjGusmMFdVpBFj3Zpuxl1u/i 4oRIy+mIipC+ODJXFBUpBFm6r6U29beBV+Omo09a7ADlvazzmh1hxxZU3mwlnito OIuSvn45pBNurG9pVG8RVU99iiu1Rw==
    =HO+E
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Roy Bamford@21:1/5 to Sam James on Sun Jan 2 13:10:01 2022
    On 2022.01.02 07:33, Sam James wrote:

    [snip]

    Note that having USE flags for things, even if forced on/masked (for
    the opposite case) is useful for building embedded systems. So, if you
    wanted to go this route, a sensible
    first step would actually be forcing PAM on. But I don't think PAM is
    a candidate for dropping.

    While I think it's hard to run a modern desktop system without it,
    there are a fair number of people who do still run -pam and I don't
    think
    breaking it for the sake of it is a good idea. They already know there
    be dragons.


    Whats your view on it?

    I think I broadly agree, although PAM is a mildly controversial
    example.

    I'd like to discuss specific examples of flags like USE=threads, some-if-not-all instances of USE=ipv6,
    And others which people raise if any others come up.

    Best,
    sam


    I'll stir the USE=-pam pot.
    A static busybox is a very good thing but that can only be achieved with USE=-pam.

    Sometimes it's the only way to pick up the pieces.

    In general, where USE=-foo makes the code size smaller I would be
    against dropping it. Think non Intel/AMD memory constrained systems.

    Gentoo is popular outside the desktop, so keep those users in mind too.

    --
    Regards,

    Roy Bamford
    (Neddyseagoon) a member of
    elections
    gentoo-ops
    forum-mods
    arm64
    -----BEGIN PGP SIGNATURE-----

    iQEzBAABCAAdFiEEsOrcx0gZrrCMwJzo/xJODTqpeT4FAmHRlTMACgkQ/xJODTqp eT4BcAf+Iyfo6jU2SlCjVo/62ZbzDyMDl5E+sZ8YGmVhYxsNbuKr9GwXY0mihiI0 ytHy7pcD6Zt9oF4gIMPOrQu3m6BcUHTWrt/UcEh0vTMvxOAM0zq58lDFrtfJKKdX 1kGCygshYVwdtxjKF/WUYzbOL9lKrVQJ0Fny6zr76T1yHjsavAZKVtJwrIn8s2+U Uf+pK/WTSt4tFKqVIHi4LwZ5LmZdk+3wN3cgitHfUX4zkclEfvZCA6T+8lhdR/Rq iS84CPq+FxBQghubV3tVWeZw6JmTCmx17od2sUVlkRvNglTUNpib3WsjTAo3G7j2 MC02cPv+Yx79/RiOUi4xTrh3/JjEoQ==
    =cb7f
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Piotr Karbowski@21:1/5 to Scott Ellis on Sun Jan 2 12:30:02 2022
    Hi,

    On 02/01/2022 01.03, Scott Ellis wrote:
    Your `ipv6` USE flag hits home - I don't use IPv6, nor do I want to have
    IPv6 support built into things (just another potential "thing" that I have
    to secure, or errors/warnings I need to suppress since I run an IPv6-less kernel).

    If there needs to be a path to culling USE flags, perhaps looking to which flags actually cause packages to pull in additional dependencies (vs solely enable/disable a feature) would be a better place to start?

    And here I am having a deja vu, an associate of mine who happens to use
    Gentoo also intentionally runs without IPv6. When we were traveling out
    of country he was unable to use WIFI hotspot that I was connected to,
    turns out, it was IPv6-only hotspot with NAT64 gateway. I had internet
    access, he had rant about why IPv6-only networks are abomination and
    that he never seen a network like it.

    He won nothing, and neither do you win anything running without IPv6
    support.

    -- Piotr.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Arsen =?utf-8?Q?Arsenovi=C4=87?=@21:1/5 to All on Sun Jan 2 12:50:01 2022
    Your `ipv6` USE flag hits home - I don't use IPv6, nor do I want to have
    IPv6 support built into things (just another potential "thing" that I have
    to secure, or errors/warnings I need to suppress since I run an IPv6-less kernel).
    More often than not IPv6 support is transparent and comes down to
    switching AF_INET for AF_INET6. There's not much code to secure here.
    --
    Arsen Arsenović

    -----BEGIN PGP SIGNATURE-----

    iQKTBAABCgB9FiEEbgAyNLNJlrDxDuNvR0U1GgzAwbwFAmHRj3ZfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDZF MDAzMjM0QjM0OTk2QjBGMTBFRTM2RjQ3NDUzNTFBMENDMEMxQkMACgkQR0U1GgzA wbzr0hAAmavqRW9YQlBHnfC9x30D6EqGSi5oeRrRA+LSmtWAYEqFGt/bHF1j0kRg 2Hhnx2+wDV34jpePKjwC6GRIuzlnoLviEfqUSH/j/P0SAj+Wkay116ez4/qEQIQo xYaEg7MZHH7+6GvzUTGxZnAjyi/X9J/ZsUGFRjEBKA9hS+JwIAMjY3TC0+DarXkL vniMXm2HOuj+lyZKdEQelaTehoEtCRb4FbpJ6wRxOnpV1TsGcFLyE4m4/EKjX8wX P0DAV+wlgpUiUvH2HIk1fl8TNwkVzC8dgmUY6Yw59qSguK4ZaPuFUwctp4f1ezu0 ZmEdtyugc0w6dNFTRIg8ToByYh76TSTF4obKp4Ck8d8EXfDQ0a7duPSZgJVhIODn Q/Ye0o/skpjOfPLfZ57IFYdxIfdefcnwc5evEh66UiQyXHu3IJtRcunrdWRHVCtl qphJ49DVWGJpjQ/Imq7yEJHFQo8BH2PpOFcVGHaaDDuZH6V+3G5as6en0y/FWz0V zzcweLYVQU9LApMGcMGcNA+WCjSsK/nzrbbBZAFqzxsAL/MkvK3Ot7k4Z7q9J4xj c86cJsxAXBfN66ruB7PH7shs8Lf9loFyB9hSzGX+3ZmF0QLNOgeHuE7Vb2Y/mp9H +UkyZVhBrkQi/oSIXzccII8Mf/3dH0Rt+aQLvIh+w8SOMFoRAPE=
    =d+wh
    -----END PGP SIGNATURE-----

    --- SoupGate-Win
  • From Ionen Wolkens@21:1/5 to Piotr Karbowski on Sun Jan 2 15:20:01 2022
    On Sat, Jan 01, 2022 at 11:21:40PM +0100, Piotr Karbowski wrote:
    As example I'd like to use 'ipv6' USE flag, at the moment of writing
    this email there's 351 ebuilds in tree that expose ipv6 as USE flag,
    allow it to be disabled.

    This is a flag I've usually been removing when I touch a package
    already, not that I'd want to spearhead removing it from /all/
    packages at once but well.

    In most cases it's:
    - an upstream default
    - has no extra dependencies
    - doesn't increase file size in any noticeable way
    - ipv6 is expected to work
    - USE=-ipv6 tend to have less-tested code paths that I've seen cause
    issues even for ipv4
    - not really anything to gain by disabling in a specific package even
    if you don't use ipv6, there's plenty of ways to disable ipv6
    - majority of packages don't even have a switch to disable either way,
    this is mostly historical switches from early days of support

    I'd keep it if say the package needed libsuperipv6 or something as I'm
    not particularly an advocate that it /must/ be supported, and in this
    case libsuperipv6 may be less wanted or even not supported on some
    arches (maybe was written in rust!)

    Beside 'ipv6', there are other USE flags that I have on mind. 'pam'
    being another of them.

    That's one I think needs to be kept even if I don't like the idea of
    normal desktop system arbitrarily disabling it where about everything
    expects it to be used.

    Disabling can make sense on prefix, embedded systems and similar --
    and it also need extra dependencies and cause more relevant changes
    in behavior that users should be free to want or not.

    Not that should be responsible for upstreams supporting disabling it,
    so when they don't just depend on it being enabled (what we do now).

    --
    ionen

    -----BEGIN PGP SIGNATURE-----

    iQEzBAABCAAdFiEEx3SLh1HBoPy/yLVYskQGsLCsQzQFAmHRtEoACgkQskQGsLCs QzQCagf+I/dKJWeV92NKCPuXhr+ce+Lb6crcNDAfU7bIilYg8v66Mqf6WtADVgDB l4TUdXNU3Mof+V8WKJ5LSJA8IFYOfvc843oIkVqvGRI6cv39qphI9IBUAdxjeNqj az6YeAchjWeoddlKdHRHBoCxY0in00Uw+muPgeS8n+TEJDQScDMnlxfzg5wPTfTD 9eU1j3xrOrv38yXQQrZiUAU5FMngCmDAPfsCEA5froyT7QHm0yIe9lKbtld0GTEL y1gUIkIRC1HHgulY4IvtW0Qyy+/Hwwsep1485ty09k4ISNewUVToKafUHligVUth es6eh9EwN85uOqI+0eRFWtBW1V6wPQ==
    =OByH
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alec Warner@21:1/5 to slashbeast@gentoo.org on Mon Jan 3 18:20:02 2022
    On Sat, Jan 1, 2022 at 2:22 PM Piotr Karbowski <slashbeast@gentoo.org> wrote:

    Hi,

    I'd like to get some insight how others see the concept of narrowing the scope of USE flags in Gentoo.

    Taking a quote from devmanual:

    > USE flags are to control optional dependencies and settings which
    the user may reasonably want to select.

    I'd like to focus on the 'reasonably want' here. While it is commonly
    agreed on that we interface as USE flags only things that make sense to
    be togglable, it is not always the case. It is not uncommon to see
    packages that puts every possible option as USE flag which hardly
    benefit anyone in some cases.

    It creates artificial choice of USE flag that makes as much sense as
    building and trying to use solar-powered night vision googles. Possible
    to be engineered, but makes absolute no sense to exist, yet, there will
    be someone who will go with it and then things will not work in desired
    way, bugs will be reported, effort will be wasted on investigation and patching things up.

    As example I'd like to use 'ipv6' USE flag, at the moment of writing
    this email there's 351 ebuilds in tree that expose ipv6 as USE flag,
    allow it to be disabled.

    The thing is, it's 2022, and it does not make any sense to *not* support IPv6, even if one does not connect to any network with IPv6, there's no
    harm to just have it there.

    While I am all for choice, I am for choice on things that do make sense.
    For instance, Linux kernel can be built with CONFIG_MULTIUSER=n, someone could argue that since Linux kernel, that is user-configured in Gentoo,
    can be built without support for other than UID 0, then Gentoo should
    support it. One of the extreme examples of not supporting something that
    does not make sense to be supported.

    Beside 'ipv6', there are other USE flags that I have on mind. 'pam'
    being another of them.

    Whats your view on it?

    I'm trying to understand your principles here. Like on what basis do
    you remove or add flags (in general).

    I want to remove:
    - bash-completion
    - acl
    - ldap
    - policykit
    - readline
    - sound

    (Part of this is just to have a meta discussion so we settle on some
    driving principles on why we keep one flag over the other.)

    I can easily craft a narrative for getting rid of ipv6, for example,
    but I cannot really craft a good narrative for getting rid of pam, or policykit, or ldap as flags. So why do we keep some and remove others?

    -A


    -- Piotr.


    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Mike Gilbert@21:1/5 to antarus@gentoo.org on Mon Jan 3 19:40:02 2022
    On Mon, Jan 3, 2022 at 12:16 PM Alec Warner <antarus@gentoo.org> wrote:

    On Sat, Jan 1, 2022 at 2:22 PM Piotr Karbowski <slashbeast@gentoo.org> wrote:

    Hi,

    I'd like to get some insight how others see the concept of narrowing the scope of USE flags in Gentoo.

    Taking a quote from devmanual:

    > USE flags are to control optional dependencies and settings which
    the user may reasonably want to select.

    I'd like to focus on the 'reasonably want' here. While it is commonly agreed on that we interface as USE flags only things that make sense to
    be togglable, it is not always the case. It is not uncommon to see
    packages that puts every possible option as USE flag which hardly
    benefit anyone in some cases.

    It creates artificial choice of USE flag that makes as much sense as building and trying to use solar-powered night vision googles. Possible
    to be engineered, but makes absolute no sense to exist, yet, there will
    be someone who will go with it and then things will not work in desired way, bugs will be reported, effort will be wasted on investigation and patching things up.

    As example I'd like to use 'ipv6' USE flag, at the moment of writing
    this email there's 351 ebuilds in tree that expose ipv6 as USE flag,
    allow it to be disabled.

    The thing is, it's 2022, and it does not make any sense to *not* support IPv6, even if one does not connect to any network with IPv6, there's no harm to just have it there.

    While I am all for choice, I am for choice on things that do make sense. For instance, Linux kernel can be built with CONFIG_MULTIUSER=n, someone could argue that since Linux kernel, that is user-configured in Gentoo,
    can be built without support for other than UID 0, then Gentoo should support it. One of the extreme examples of not supporting something that does not make sense to be supported.

    Beside 'ipv6', there are other USE flags that I have on mind. 'pam'
    being another of them.

    Whats your view on it?

    I'm trying to understand your principles here. Like on what basis do
    you remove or add flags (in general).

    I want to remove:
    - bash-completion
    - acl
    - ldap
    - policykit
    - readline
    - sound

    (Part of this is just to have a meta discussion so we settle on some
    driving principles on why we keep one flag over the other.)

    I can easily craft a narrative for getting rid of ipv6, for example,
    but I cannot really craft a good narrative for getting rid of pam, or policykit, or ldap as flags. So why do we keep some and remove others?

    The devmanual has a section on this topic:

    https://devmanual.gentoo.org/general-concepts/use-flags/index.html#when-not-to-use-use-flags

    Personally, I use the following principles:

    Is there an optional build time dependency, and is the package still
    useful without said dependency? If so, a USE flag is warranted.

    Is there some optional feature/behavior that can only be toggled at
    build time? If so, a USE flag is probably warranted.

    Is there some optional feature/behavior that can be toggled at run
    time (via config)? Does disabling it at build time have a minimal
    effect on the installed size? If so, I will NOT add a USE flag.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Piotr Karbowski@21:1/5 to Alec Warner on Mon Jan 3 21:40:02 2022
    Hi,

    On 03/01/2022 18.16, Alec Warner wrote:
    I'm trying to understand your principles here. Like on what basis do
    you remove or add flags (in general).

    My principals is to end-user experience over exposing as much as
    possible as USE flags.

    A real life example

    media-sound/deadbeef

    The .mp3 support can either use libmad or libmpg123. The first one is dead upstream, while code work currently with it, because it is dead, I
    rather avoid some setups where users setup +mad instead of +mpg123 that
    are mutually exclusive and run into some issues, like crashes, that
    would waste a lot of time on debugging it, so I made it that mp3 depends
    on libmpg123 without option for libmad. Some overlay-provided ebuilds
    for it do have option for libmad, I decided to not include it.

    If you'd decide to give user a choice, you would make it as USE flag,
    but from end-user perspective it does not provide any benefit, and from maintainer perspective it's better to reduce error surface.

    Perhaps the 'pam' example was extreme, but ipv6, or threads as Sam
    shared, does not make sense to be togglable.

    -- Piotr

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Orlitzky@21:1/5 to Piotr Karbowski on Tue Jan 4 01:40:02 2022
    On Mon, 2022-01-03 at 21:29 +0100, Piotr Karbowski wrote:

    Perhaps the 'pam' example was extreme, but ipv6, or threads as Sam
    shared, does not make sense to be togglable.


    Many packages need their ipv6 code disabled if the kernel has no ipv6
    support, and enabling ipv6 in the kernel is a pointless security risk
    for pretty much anyone in the United States.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Orlitzky@21:1/5 to Alec Warner on Tue Jan 4 02:10:01 2022
    On Mon, 2022-01-03 at 16:51 -0800, Alec Warner wrote:


    Many packages need their ipv6 code disabled if the kernel has no ipv6 support, and enabling ipv6 in the kernel is a pointless security risk
    for pretty much anyone in the United States.

    https://www.google.com/intl/en/ipv6/statistics.html#tab=per-country-ipv6-adoption

    Go troll somewhere else?


    Anyway, leave the USE flag please.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alec Warner@21:1/5 to mjo@gentoo.org on Tue Jan 4 02:00:03 2022
    On Mon, Jan 3, 2022 at 4:29 PM Michael Orlitzky <mjo@gentoo.org> wrote:

    On Mon, 2022-01-03 at 21:29 +0100, Piotr Karbowski wrote:

    Perhaps the 'pam' example was extreme, but ipv6, or threads as Sam
    shared, does not make sense to be togglable.


    Many packages need their ipv6 code disabled if the kernel has no ipv6 support, and enabling ipv6 in the kernel is a pointless security risk
    for pretty much anyone in the United States.

    https://www.google.com/intl/en/ipv6/statistics.html#tab=per-country-ipv6-adoption

    Go troll somewhere else?

    -A





    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Sam James@21:1/5 to All on Tue Jan 4 04:40:02 2022
    On 4 Jan 2022, at 00:29, Michael Orlitzky <mjo@gentoo.org> wrote:

    On Mon, 2022-01-03 at 21:29 +0100, Piotr Karbowski wrote:

    Perhaps the 'pam' example was extreme, but ipv6, or threads as Sam
    shared, does not make sense to be togglable.


    Many packages need their ipv6 code disabled if the kernel has no ipv6 support, and enabling ipv6 in the kernel is a pointless security risk
    for pretty much anyone in the United States.


    Obviously for such cases, the flag should be kept. But that's not
    the case for plenty of packages.

    Best,
    sam

    -----BEGIN PGP SIGNATURE-----

    iQGTBAEBCgB9FiEEYOpPv/uDUzOcqtTy9JIoEO6gSDsFAmHTwF5fFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDYw RUE0RkJGRkI4MzUzMzM5Q0FBRDRGMkY0OTIyODEwRUVBMDQ4M0IACgkQ9JIoEO6g SDvPowgApiq63BTN9zCILxYaC5km5z7Vxf/Yr6Gc60r5wy7/Zu/+51ChseZ2ZS/9 5K5BJuH34TZykwnY4yHE4cXRMPUIFks7tETmiGH1S3M69CHK8HNT1iFNF7D+fPuS SXOLCtWf3icuDoOagVEKBo1JH+/MPXmvjBWKZ8lG69FI46Cz0Lqlz5fUrffa7quD AfUwWX9GGz/KJezj/5FS9dzd4y/fZ1pmhZzmnLJ+Rd8r+JQJywe0JWmqwhTXbq+Q UadvCKJUalBNPSRYbXD0eBKlb2FGAn2HTdbI6Errw6k5mmWaop5ONslFqycnhRgn hYxICHDO6CaAXqjywDJt++s2mkyWVg==
    =W74a
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Alec Warner@21:1/5 to sam@gentoo.org on Tue Jan 4 06:40:02 2022
    On Mon, Jan 3, 2022 at 7:39 PM Sam James <sam@gentoo.org> wrote:



    On 3 Jan 2022, at 17:16, Alec Warner <antarus@gentoo.org> wrote:

    [snip]


    I'm trying to understand your principles here. Like on what basis do
    you remove or add flags (in general).

    I want to remove:
    - bash-completion


    FWIW, I've managed to remove basically all instances of {bash,zsh}-completion and made upstream PRs (all of one of which have been merged!) for fixing `./configure` behaviour accordingly.

    This is in align with our small files policy: https://projects.gentoo.org/qa/policy-guide/installed-files.html#pg0301.

    - acl
    - ldap


    ACL is kind of similar to what Ionen said for PAM, i.e. sometimes
    people may want to turn it off and it makes sense to expose
    this option for those who do, but we don't need to try support it.

    I feel like 'acl' or 'pam' or 'policykit' are not really USE flags in
    the general sense. They are more like profile settings. You don't want
    to toggle these flags, you want to switch profiles. I think
    conceptually profile migrations are larger changes that require a
    rebuild of a bunch of stuff, and typically have downtime (e.g. where
    your system isn't expected to work the entire time.)

    There are practical problems with profile proliferation, but I think
    it is closer to what these flags represent, if that makes sense.

    -A



    I think some of this kind of comes back to "how do we better
    make clear what is/isn't okay (supported)to customise?"

    LDAP is a fun one because IIRC we had it enabled by default
    for too long and it didn't really break anything when we turned
    It off.

    Overall, I think we kind of come back to this idea of
    trying to just set better IUSE defaults rather than
    in profiles, so that it's per-package where possible.

    - policykit


    This is a reasonable flag to keep given the heavy polkit
    dependency of spidermonkey (for now) and it's somewhat
    heavy-handed as a concept anyway.

    - readline


    readline is a tricky one because of its relation with libedit too.

    - sound

    (Part of this is just to have a meta discussion so we settle on some
    driving principles on why we keep one flag over the other.)

    I can easily craft a narrative for getting rid of ipv6, for example,
    but I cannot really craft a good narrative for getting rid of pam, or policykit, or ldap as flags. So why do we keep some and remove others?



    It's very hard to quantify :(


    Best,
    sam


    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Orlitzky@21:1/5 to Sam James on Tue Jan 4 06:40:02 2022
    On Tue, 2022-01-04 at 03:38 +0000, Sam James wrote:

    ACL is kind of similar to what Ionen said for PAM, i.e. sometimes
    people may want to turn it off and it makes sense to expose
    this option for those who do, but we don't need to try support it.


    This is another important one. It has security implications, is highly confusing, requires kernel support, and is nonstandard as a USE flag
    and as an implementation. Most people should have it off to avoid
    surprises, but disabling it in the kernel can make the userland
    software complain when explicitly built with ACL support.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Mike Gilbert@21:1/5 to mjo@gentoo.org on Tue Jan 4 18:10:03 2022
    On Tue, Jan 4, 2022 at 12:31 AM Michael Orlitzky <mjo@gentoo.org> wrote:

    On Tue, 2022-01-04 at 03:38 +0000, Sam James wrote:

    ACL is kind of similar to what Ionen said for PAM, i.e. sometimes
    people may want to turn it off and it makes sense to expose
    this option for those who do, but we don't need to try support it.


    This is another important one. It has security implications, is highly confusing, requires kernel support, and is nonstandard as a USE flag
    and as an implementation. Most people should have it off to avoid
    surprises, but disabling it in the kernel can make the userland
    software complain when explicitly built with ACL support.

    I disagree with the claim that "most people" should disable ACL
    support at build time. That just gives you partially functional tools.
    The ACL behavior can generally be controlled using runtime options.

    Also, you might be able to get away with disabling ACL support on a
    server, but desktop users will want ACL support enabled to get
    properly functioning udev rules.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Orlitzky@21:1/5 to Mike Gilbert on Tue Jan 4 18:40:02 2022
    On Tue, 2022-01-04 at 12:03 -0500, Mike Gilbert wrote:

    I disagree with the claim that "most people" should disable ACL
    support at build time. That just gives you partially functional tools.
    The ACL behavior can generally be controlled using runtime options.

    I understand why people would disagree in this case, but isn't that a
    an argument for having the flag?

    There are plenty of great uses for ACLs, but unless you're extremely knowledgeable, they also add a million new ways to compromise your
    system. For example, if you untar a file with a default-ACL'd directory
    in it and don't notice the little plus sign, you might wind up
    unknowingly creating world-writable files. Even if you do notice the
    ACL, you have to be an expert in the interaction between umask,
    permission bits, the ACL mask, effective permissions, conflicting ACLs,
    and all of the tools you're using to understand what will actually
    happen or how to properly fix it. It's not something normal people can
    handle.

    If you don't need them for anything, it's just nice not to have to
    worry about those issues.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Piotr Karbowski@21:1/5 to Mike Gilbert on Tue Jan 4 18:20:02 2022
    Hi,

    On 04/01/2022 18.03, Mike Gilbert wrote:
    On Tue, Jan 4, 2022 at 12:31 AM Michael Orlitzky <mjo@gentoo.org> wrote:

    On Tue, 2022-01-04 at 03:38 +0000, Sam James wrote:

    ACL is kind of similar to what Ionen said for PAM, i.e. sometimes
    people may want to turn it off and it makes sense to expose
    this option for those who do, but we don't need to try support it.


    This is another important one. It has security implications, is highly
    confusing, requires kernel support, and is nonstandard as a USE flag
    and as an implementation. Most people should have it off to avoid
    surprises, but disabling it in the kernel can make the userland
    software complain when explicitly built with ACL support.

    I disagree with the claim that "most people" should disable ACL
    support at build time. That just gives you partially functional tools.
    The ACL behavior can generally be controlled using runtime options.

    Also, you might be able to get away with disabling ACL support on a
    server, but desktop users will want ACL support enabled to get
    properly functioning udev rules.


    I second this.

    As far as Desktop is concerned acl is basic feature that should be there
    along with extended attributes, for example, I am pretty sure
    systemd-login will use acl to grant access to inputs in /dev for the
    logged user.

    acl is as much needed as support for multiple users (CONFIG_MULTIUSER),
    and it also needs support on kernel level, because without this symbol
    hardly anything will work for you. What I mean here is that argument
    'needs support in kernel' is not a problem, because everything does need
    a support in kernel. Try to boot without CONFIG_FUTEX as example, it can
    be disabled so you could say that it needs support in kernel in a way to constitute that this is something bad and thus should be avoided.

    -- Piotr.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Piotr Karbowski@21:1/5 to Michael Orlitzky on Tue Jan 4 19:30:02 2022
    Hi,

    On 04/01/2022 18.35, Michael Orlitzky wrote:
    On Tue, 2022-01-04 at 12:03 -0500, Mike Gilbert wrote:

    I disagree with the claim that "most people" should disable ACL
    support at build time. That just gives you partially functional tools.
    The ACL behavior can generally be controlled using runtime options.

    I understand why people would disagree in this case, but isn't that a
    an argument for having the flag?

    There are plenty of great uses for ACLs, but unless you're extremely knowledgeable, they also add a million new ways to compromise your
    system. For example, if you untar a file with a default-ACL'd directory
    in it and don't notice the little plus sign, you might wind up
    unknowingly creating world-writable files. Even if you do notice the
    ACL, you have to be an expert in the interaction between umask,
    permission bits, the ACL mask, effective permissions, conflicting ACLs,
    and all of the tools you're using to understand what will actually
    happen or how to properly fix it. It's not something normal people can handle.
    And none of which happens unless you intentionally trigger it.

    1. To have ACL break things on new (extracted) files you'd first need to
    have default ACL set on parent directory where you extract to --
    otherwise they won't be carried and no problem

    2. unless you add --acl to both create and extract, no acl will be added
    to tarball and/or extracted onto system

    Running 'tar --acl ...' or 'setfacl -d ...' does not happen by accident
    and argument that you should disable acl to not run into issues with
    above does not make much sense.

    Sure, acl and how chmod manipulate mask on ACL-enabled entities is not
    very simple, but nothing will break by itself just because you have acl
    support enabled, you would need to try very hard to run into problems.

    -- Piotr.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Orlitzky@21:1/5 to Piotr Karbowski on Tue Jan 4 20:20:02 2022
    On Tue, 2022-01-04 at 19:26 +0100, Piotr Karbowski wrote:

    And none of which happens unless you intentionally trigger it.

    ...

    Sure, acl and how chmod manipulate mask on ACL-enabled entities is not
    very simple, but nothing will break by itself just because you have acl support enabled, you would need to try very hard to run into problems.



    Even if you're right, and if no other tools invoke tar, and the user is
    smart enough not to copy/paste commands from the web, and if no other
    archivers can extract ACLs when invoked directly or indirectly...
    you're still burdening the user to either have faith that this is all
    true, or to verify it himself. Repeat the argument for other flags like
    ipv6, and you wind up requiring either a lot of faith, or a lot of
    diligence, both of which are antithetical to basic principles of
    security.

    You may not buy the argument, but it's why people disable this stuff,
    and the ability to disable it is why a lot of our users user Gentoo to
    begin with.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Piotr Karbowski@21:1/5 to Michael Orlitzky on Tue Jan 4 20:50:01 2022
    On 04/01/2022 20.18, Michael Orlitzky wrote:
    On Tue, 2022-01-04 at 19:26 +0100, Piotr Karbowski wrote:

    And none of which happens unless you intentionally trigger it.

    ...

    Sure, acl and how chmod manipulate mask on ACL-enabled entities is not
    very simple, but nothing will break by itself just because you have acl
    support enabled, you would need to try very hard to run into problems.



    Even if you're right, and if no other tools invoke tar, and the user is
    smart enough not to copy/paste commands from the web, and if no other archivers can extract ACLs when invoked directly or indirectly...
    you're still burdening the user to either have faith that this is all
    true, or to verify it himself. Repeat the argument for other flags like
    ipv6, and you wind up requiring either a lot of faith, or a lot of
    diligence, both of which are antithetical to basic principles of
    security.

    You may not buy the argument, but it's why people disable this stuff,
    and the ability to disable it is why a lot of our users user Gentoo to
    begin with.

    I was challenging here your opinion that most people should disable acl support.

    And what I showed is that, by keeping it enabled, does not bring on you potential problems beside possible security issues in the code that you
    keep around and not want to have around.

    Sure, there are valid reasons to strip things from kernel, I've seen
    some tor nodes running kernel without input devices all out of
    initramfs, such usecase do make sense.

    However I am strongly against opinion that most people should not enable
    acl, unless you have 16 MB NOR flash storage and every kB of kernel
    image counts, but then it's unlikely that you'd use gentoo there in the
    first place, since bundling headers and whole toolchain would east a lot
    of storage.

    I know there are people who love to disable things, there are even
    people who says that pam is bloatware and strip it, or people who,
    security reason as they claim, refuse to use logind provider (elogind or systemd) and instead choose to run Xorg as root.

    -- Piotr.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)