Re: [PATCH v3] selinux: simplify away security_policydb_len()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 27, 2020 at 12:28 PM Ondrej Mosnacek <omosnace@xxxxxxxxxx> wrote:
>
> Remove the security_policydb_len() calls from sel_open_policy() and
> instead update the inode size from the size returned from
> security_read_policy().
>
> Since after this change security_policydb_len() is only called from
> security_load_policy(), remove it entirely and just open-code it there.
>
> Also, since security_load_policy() is always called with policy_mutex
> held, make it dereference the policy pointer directly and drop the
> unnecessary RCU locking.
>
> Signed-off-by: Ondrej Mosnacek <omosnace@xxxxxxxxxx>
> ---
>
> v3: rebase on top of latest selinux/next
>
>  security/selinux/include/security.h |  1 -
>  security/selinux/selinuxfs.c        | 12 ++++++------
>  security/selinux/ss/services.c      | 27 ++++-----------------------
>  3 files changed, 10 insertions(+), 30 deletions(-)

Merged into selinux/next.

-- 
paul moore
www.paul-moore.com



[Index of Archives]     [Selinux Refpolicy]     [Linux SGX]     [Fedora Users]     [Fedora Desktop]     [Yosemite Photos]     [Yosemite Camping]     [Yosemite Campsites]     [KDE Users]     [Gnome Users]

  Powered by Linux