diff options
author | Anton Blanchard <anton@samba.org> | 2013-01-09 10:46:17 +1100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-05-19 10:54:39 -0700 |
commit | ad86524f948c1914dbd5bc460a5c6fd131ec054a (patch) | |
tree | e123d937b7d8e6871bc161a6233f850c236e8d49 /kernel/sysctl_binary.c | |
parent | 7c8b65e18db43c918ec3491e2712432d2a33f8a5 (diff) |
audit: Syscall rules are not applied to existing processes on non-x86
commit cdee3904b4ce7c03d1013ed6dd704b43ae7fc2e9 upstream.
Commit b05d8447e782 (audit: inline audit_syscall_entry to reduce
burden on archs) changed audit_syscall_entry to check for a dummy
context before calling __audit_syscall_entry. Unfortunately the dummy
context state is maintained in __audit_syscall_entry so once set it
never gets cleared, even if the audit rules change.
As a result, if there are no auditing rules when a process starts
then it will never be subject to any rules added later. x86 doesn't
see this because it has an assembly fast path that calls directly into
__audit_syscall_entry.
I noticed this issue when working on audit performance optimisations.
I wrote a set of simple test cases available at:
http://ozlabs.org/~anton/junkcode/audit_tests.tar.gz
02_new_rule.py fails without the patch and passes with it. The
test case clears all rules, starts a process, adds a rule then
verifies the process produces a syscall audit record.
Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Eric Paris <eparis@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/sysctl_binary.c')
0 files changed, 0 insertions, 0 deletions