This revision introduces the test-program for ioctl audit class which only contains
ioctl(2) as the audit event.
Details
Details
- Reviewers
asomers rwatson gnn - Commits
- rS335354: audit(4): add tests for ioctl(2)
Execute make && make install from test/sys/audit.
Execute kyua test from /usr/tests/sys/audit. All testcases should succeed.
Diff Detail
Diff Detail
- Lint
Lint Passed - Unit
No Test Coverage - Build Status
Buildable 17427 Build 17259: arc lint + arc unit
Event Timeline
Comment Actions
Verify the audit of hex(request) in the ioctl(2)'s audit record
@asomers I have opened a separate instance of /dev/auditpipe for the test-case, so it doesn't
matter what is flushed from this device instance, since it is not of our concern.
Also, I pondered initially about which request to use, I chose AUDITPIPE_FLUSH because
it is the simplest of all available options.
tests/sys/audit/ioctl.c | ||
---|---|---|
60 | Pro tip: the "#" character tells printf(3) to use an "alternate form", which has different meanings depending on the type of conversion. For example, printf("%#x", 16) will print 0xa. |