diff options
author | Casey Schaufler <casey@schaufler-ca.com> | 2023-09-12 22:56:48 +0200 |
---|---|---|
committer | Paul Moore <paul@paul-moore.com> | 2023-11-13 04:54:42 +0100 |
commit | 267c068e5f8b81b68cc4247c94dbba90a21a634e (patch) | |
tree | 58b75854f3b7743433ea23603eb08348dd3a4d77 /fs/proc/internal.h | |
parent | LSM: Maintain a table of LSM attribute data (diff) | |
download | linux-267c068e5f8b81b68cc4247c94dbba90a21a634e.tar.xz linux-267c068e5f8b81b68cc4247c94dbba90a21a634e.zip |
proc: Use lsmids instead of lsm names for attrs
Use the LSM ID number instead of the LSM name to identify which
security module's attibute data should be shown in /proc/self/attr.
The security_[gs]etprocattr() functions have been changed to expect
the LSM ID. The change from a string comparison to an integer comparison
in these functions will provide a minor performance improvement.
Cc: linux-fsdevel@vger.kernel.org
Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Serge Hallyn <serge@hallyn.com>
Reviewed-by: Mickael Salaun <mic@digikod.net>
Reviewed-by: John Johansen <john.johansen@canonical.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
Diffstat (limited to 'fs/proc/internal.h')
-rw-r--r-- | fs/proc/internal.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/proc/internal.h b/fs/proc/internal.h index 9a8f32f21ff5..a71ac5379584 100644 --- a/fs/proc/internal.h +++ b/fs/proc/internal.h @@ -92,7 +92,7 @@ union proc_op { int (*proc_show)(struct seq_file *m, struct pid_namespace *ns, struct pid *pid, struct task_struct *task); - const char *lsm; + int lsmid; }; struct proc_inode { |