Page MenuHomeFreeBSD

mac: kdb/ddb framework hooks
ClosedPublic

Authored by mhorne on May 31 2022, 6:07 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mar 10 2024, 11:18 PM
Unknown Object (File)
Mar 10 2024, 10:58 PM
Unknown Object (File)
Mar 10 2024, 10:54 PM
Unknown Object (File)
Mar 10 2024, 10:29 PM
Unknown Object (File)
Feb 16 2024, 3:44 PM
Unknown Object (File)
Jan 3 2024, 2:34 PM
Unknown Object (File)
Dec 23 2023, 9:42 AM
Unknown Object (File)
Nov 8 2023, 10:55 AM

Details

Summary

Add three simple hooks to the debugger allowing for a loaded MAC policy
to intervene if desired:

  1. Before invoking the kdb backend
  2. Before ddb command registration
  3. Before ddb command execution

We extend struct db_command with a private pointer and two flag bits
reserved for policy use.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

markj added inline comments.
sys/ddb/db_command.c
494

This line appears to be too long.

sys/security/mac/mac_debugger.c
1 ↗(On Diff #106515)

mac_kdb.c might be a better name for this file. "debugger" sounds too generic to me.

This revision is now accepted and ready to land.Jul 13 2022, 2:30 PM
This revision was automatically updated to reflect the committed changes.