On 10/19/23, Paul Moore <[email protected]> wrote:
> Thinking about it a bit more this morning, I think we can safely
> ignore the non-@current case in audit_exe_compare() as the whole point
> of the audit exe filter is to record the actions of processes
> instantiated from that executable file; if the @current task is not
> being logged/filtered, we shouldn't have to worry about the exe
> filter.
>

I did a quick stab at figuring out whether one can get there with
non-current to begin with, but did not convince myself it is not
possible.

That said, should you repost, I think refing and unrefing mm should be a voided.

The bug showed up with 18c91bb2d87268d23868bf13508f5bc9cf04e89a
("prlimit: do not grab the tasklist_lock") which converted that lock
to task_lock. So I don't think pointing at my patch as "Fixes" is
accurate, but I'm not going to insist. ;)

As for prlimit, I think I'm going to add the lock to signal struct for
thread within one thread group. At the same time "remote" prlimit will
instead resort to tasklist_lock, like it did prior to the above
commit. Then the new lock can be converted to a seqlock, so that
grabbing rlimits is cheaper. I'm going to create a new thread about it
later.

-- 
Mateusz Guzik <mjguzik gmail.com>

Reply via email to