[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHk-=wiH3hoPTxX3=xTRzRuCwktf3pNzFWP45-x6AwoVAjUsUQ@mail.gmail.com>
Date: Wed, 26 Mar 2025 14:06:06 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Paul Moore <paul@...l-moore.com>
Cc: "Cameron K. Williams" <ckwilliams.work@...il.com>, "Kipp N. Davis" <kippndavis.work@....com>,
Stephen Smalley <stephen.smalley.work@...il.com>, selinux@...r.kernel.org,
linux-security-module@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [GIT PULL] selinux/selinux-pr-20250323
On Wed, 26 Mar 2025 at 13:48, Paul Moore <paul@...l-moore.com> wrote:
>
> Looking at the pre-patched code one can see that SELinux only enforced
> access controls on kernel module loading
I *know*.
I've looked at that commit. It's why I'm asking.
> Moving forward to the recent pull
> request, the LSM hooks do have the ability to gate these additional
> file types, and for a LSM such as SELinux that aims to provide
> comprehensive access controls, adding support for enforcing controls
> on these additional file types is a logical thing to do and consistent
> with our other work.
Again - you're explaining what it *does*. I see what it does. That
was never the issue. That was the only part that the commit message
talked about.
What I'm asking for is *WHY*.
I realize that to you, the security side is what you do, and you feel
that this is all some internal thing to selinux and may feel that I'm
butting in where I shouldn't.
But to others, these things cause extra overhead, so it's *not* just
internal to selinux. It affects others in bad ways.
I want the _reasons_ for new policy hooks to be *explained*.
> The fact that these changes didn't happen at the
> same time as the enabling support for the other file types is likely
> due to an ongoing challenge we face where we sometimes fail to keep
> current with all facets of kernel development.
You are still just talking about what the code does.
I repeat: my questions is *WHY*.
*WHY* is that policy needed at all?
As you correctly point out, it has NOT EXISTED for a long long time
already, and the code has been the old way since 4.x timeframe.
So my question literally boils down to "WHY SHOULD IT EXIST NOW"?
We've done quite well without it.
And I do not not see the point of allowing a driver module load (which
*is* a policy, and has been for a long time), and then disallowing
loading the firmware that the driver needs.
That's insane. So explain to me why you added what looks like
completely insane policy hooks.
See what I'm complaining about? I'm literally looking at that code,
and I understand what it does, but it adds policy for something where
I do not believe policy makes any sense what-so-ever.
The whole "any policy, anywhere, any time, for any reason" model is not valid.
We don't ask for permission for core kernel functionality. We don't
ask permission to do things the kernel needs to do.
And new policy rules need to be explained.
Linus
Powered by blists - more mailing lists