]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
fix bogus reporting of signals by audit
authorAl Viro <viro@ftp.linux.org.uk>
Sun, 7 Oct 2007 07:24:36 +0000 (00:24 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Sun, 7 Oct 2007 23:28:43 +0000 (16:28 -0700)
commit291041e935e6d0513f2b7e4a300aa9f02ec1d925
tree626b06b52d5ce0a41c7bf21ce4314e2a9fbe79ff
parent7a5c5d5735e785a700a377a5fce913b8ad45a58f
fix bogus reporting of signals by audit

Async signals should not be reported as sent by current in audit log.  As
it is, we call audit_signal_info() too early in check_kill_permission().
Note that check_kill_permission() has that test already - it needs to know
if it should apply current-based permission checks.  So the solution is to
move the call of audit_signal_info() between those.

Bogosity in question is easily reproduced - add a rule watching for e.g.
kill(2) from specific process (so that audit_signal_info() would not
short-circuit to nothing), say load_policy, watch the bogus OBJ_PID entry
in audit logs claiming that write(2) on selinuxfs file issued by
load_policy(8) had somehow managed to send a signal to syslogd...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Acked-by: Steve Grubb <sgrubb@redhat.com>
Acked-by: Eric Paris <eparis@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
kernel/signal.c