lkml.org 
[lkml]   [2024]   [Apr]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 2/2] openat2: add OA2_INHERIT_CRED flag
From
22.04.2024 22:53, Stefan Metzmacher пишет:
> I'm wondering if it would be better to capture the whole cred structure.
>
> Similar to io_register_personality(), which uses get_current_cred().
>
> Only using uid and gid, won't reflect any group memberships or
> capabilities...
Hmm, I thought about that, but was
under an impression that with get_current_cred()
you only increment a refcount.
But I guess the trick here is that due
to an RCU machinery, you can actually
get your local copy if someone else
changes it?

I'll try what you say, thanks.

\
 
 \ /
  Last update: 2024-04-22 22:19    [W:0.057 / U:0.032 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site