Re: [PATCH] lsm: constify 'file' parameter in security_bprm_creds_from_file()

From
Paul Moore <paul@paul-moore.com>
Date
2023-09-13 22:09:37
Also in
linux-fsdevel, lkml
Reply to
Khadija Kamran, 2023-08-23
On Aug 23, 2023 Khadija Kamran [off-list ref] wrote:
The 'bprm_creds_from_file' hook has implementation registered in
commoncap. Looking at the function implementation we observe that the
'file' parameter is not changing.

Mark the 'file' parameter of LSM hook security_bprm_creds_from_file() as
'const' since it will not be changing in the LSM hook.

Signed-off-by: Khadija Kamran <redacted>
---
 include/linux/fs.h            | 2 +-
 include/linux/lsm_hook_defs.h | 2 +-
 include/linux/security.h      | 6 +++---
 security/commoncap.c          | 4 ++--
 security/security.c           | 2 +-
 5 files changed, 8 insertions(+), 8 deletions(-)
Merged into lsm/next, thanks!

--
paul-moore.com
Thread (2 messages) 2 messages, 2 authors, last reply 2023-09-13
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help