Page MenuHomeFreeBSD

auditd: Further improve signal handling
AbandonedPublic

Authored by des on Jun 4 2026, 10:15 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Aug 15, 12:00 AM
Unknown Object (File)
Fri, Aug 14, 10:03 PM
Unknown Object (File)
Thu, Aug 13, 5:50 AM
Unknown Object (File)
Thu, Aug 13, 2:01 AM
Unknown Object (File)
Thu, Aug 13, 1:02 AM
Unknown Object (File)
Wed, Aug 12, 6:47 PM
Unknown Object (File)
Tue, Aug 11, 6:06 PM
Unknown Object (File)
Mon, Aug 10, 12:29 PM
Subscribers

Details

Reviewers
kevans
csjp
Summary

Rewrite the main loop to use ppoll() instead of just blocking on read,
blocking the signals we care about when we aren't polling.

I didn't bother replacing alarm() with setitimer(); the alarm code
is dead anyway since there is no way for max_idletime to acquire a
non-zero value.

MFC after: 1 week

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 73695
Build 70578: arc lint + arc unit

Event Timeline

des requested review of this revision.Jun 4 2026, 10:15 PM

Looks good a couple of minor things

contrib/openbsm/bin/auditd/auditd_fbsd.c
267

minor nit but NULL instead of 0 here

280

Another minor nit: Incrementing is misleading because it implies the count matters, when it doesn't. Using = 1 makes the intent explicit: this is a flag, not a counter

This revision is now accepted and ready to land.Jun 5 2026, 5:12 AM
This revision now requires review to proceed.Jun 5 2026, 6:50 AM
des marked 2 inline comments as done.Jun 5 2026, 6:50 AM
This revision is now accepted and ready to land.Jun 5 2026, 1:22 PM
contrib/openbsm/bin/auditd/auditd_fbsd.c
218

It occurs to me that we might want audiitwarning to have the previous mask available to restore the mask in the child