Linux Integrity Measurement development
 help / color / mirror / Atom feed
* [PATCH 0/2] ima: add dont_audit and fs_subtype to policy language
@ 2025-09-25 23:45 Jann Horn
  2025-09-25 23:45 ` [PATCH 1/2] ima: add dont_audit action to suppress audit actions Jann Horn
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Jann Horn @ 2025-09-25 23:45 UTC (permalink / raw)
  To: Mimi Zohar, Roberto Sassu, Dmitry Kasatkin, Eric Snowberg
  Cc: Frank Dinoff, linux-kernel, linux-integrity, Jann Horn

This series adds a "dont_audit" action that cancels out following
"audit" actions (as we already have for other action types), and also
adds an "fs_subtype" that can be used to distinguish between FUSE
filesystems.

With these two patches applied, as a toy example, you can use the
following policy:
```
dont_audit fsname=fuse fs_subtype=sshfs
audit func=BPRM_CHECK fsname=fuse
```

I have tested that with this policy, executing a binary from a
"fuse-zip" FUSE filesystem results in an audit log entry:
```
type=INTEGRITY_RULE msg=audit([...]): file="/home/user/ima/zipmount/usr/bin/echo" hash="sha256:1d82e8[...]
```
while executing a binary from an "sshfs" FUSE filesystem does not
generate any audit log entries.

Signed-off-by: Jann Horn <jannh@google.com>
---
Jann Horn (2):
      ima: add dont_audit action to suppress audit actions
      ima: add fs_subtype condition for distinguishing FUSE instances

 Documentation/ABI/testing/ima_policy |  3 +-
 security/integrity/ima/ima_policy.c  | 57 ++++++++++++++++++++++++++++++++----
 2 files changed, 54 insertions(+), 6 deletions(-)
---
base-commit: 00642a06d60c897a8348784e1eee9e5369219ce5
change-id: 20250925-ima-audit-8bd219dcc6f6

--  
Jann Horn <jannh@google.com>


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2025-10-16 15:57 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-25 23:45 [PATCH 0/2] ima: add dont_audit and fs_subtype to policy language Jann Horn
2025-09-25 23:45 ` [PATCH 1/2] ima: add dont_audit action to suppress audit actions Jann Horn
2025-09-25 23:45 ` [PATCH 2/2] ima: add fs_subtype condition for distinguishing FUSE instances Jann Horn
2025-09-30 10:23 ` [PATCH 0/2] ima: add dont_audit and fs_subtype to policy language Mimi Zohar
2025-09-30 14:26   ` Jann Horn
2025-10-16 15:52     ` Mimi Zohar
2025-10-16 15:53       ` Jann Horn
2025-10-14 15:55   ` Jann Horn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox