Red Hat Bugzilla – Bug 492166
Problem with filtering based on auid
Last modified: 2014-02-10 18:03:59 EST
Description of problem:
On PPC, i386 and s390 architecture, whenever an user gets auid -1 (i.e. cat /proc/self/ returns 4294967295) filtering of the syscalls based on auid=4294967295 does not work. OTOH it works with no problems on IA64, x86_64 and s390x.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Get loginuid -1 on any of those arch.
2. auditctl -d exit,always -S <syscall> -F auid=4294967295
3. use the syscall
4. check that there is the log about the syscall in the /var/log/audit/audit.log
- or -
use audit-test from kernel/security/audit, namely filter part, test process_attrs
No log about syscall whenever -F auid=4294967295 is present. Correct log message present when -F auid=4294967295 is ommited.
log about the syscall in /var/log/audit/audit.log
Whenever user has ordinary login_uid (like 0), then it works perfectly.
Log from s390 without auid in the filter:
type=SYSCALL,CWD,PATH msg=audit(1238000396.640:342): arch=80000016 syscall=5 success=yes exit=3 a0=7ffffa97 a1=8000 a2=0 a3=1 items=1 pid=23977 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 comm=cat exe=/bin/cat cwd=/mnt/testarea/tests/kernel/security/audit/audit-test/audit-test/filter/tests rdev=00:00 ouid=0 dev=fd:00 flags=101 mode=0100600 name=/tmp/tmp.pbCMb23963 ogid=0 inode=641999
we are looking at it, but for now, we know you can use auid=-1 to get what you want.
The source of the problem is in libaudit.c:
@@ -641,7 +641,7 @@ int audit_rule_fieldpair(struct audit_ru
vlen = strlen(v);
- strtol(v, NULL, 0);
+ strtoul(v, NULL, 0);
else if (vlen >= 2 && *(v)=='-' &&
Need to build a new audit package. Btw, this same patch is needed in RHEL5 and rawhide.
Since RHEL 4.8 External Beta has begun, and this bugzilla remains
unresolved, it has been rejected as it is not proposed as exception or
Thank you for submitting this issue for consideration in Red Hat Enterprise Linux. The release for which you requested us to review is now End of Life.
Please See https://access.redhat.com/support/policy/updates/errata/
If you would like Red Hat to re-consider your feature request for an active release, please re-open the request via appropriate support channels and provide additional supporting details about the importance of this issue.