-
Notifications
You must be signed in to change notification settings - Fork 367
Status/2025Q3/mac_do.adoc: Add report #552
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,23 @@ | ||||||||||||||
[[gsoc25-macdo-mdo]] | ||||||||||||||
=== mac_do(4) and mdo(1) Improvements | ||||||||||||||
|
||||||||||||||
Links: + | ||||||||||||||
https://wiki.freebsd.org/SummerOfCode2025Projects/MacDoAndMDoImprovements | ||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We have a different format for the links section. We need to explicitly use the
Suggested change
|
||||||||||||||
|
||||||||||||||
Contact: Kushagra Srivastava <[email protected]> | ||||||||||||||
|
||||||||||||||
As part of Google Summer of Code 2025, I worked on two related sub-projects in the FreeBSD Project: kernel improvements to `mac_do(4)` and userland enhancements to `mdo(1)`. | ||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We have a specific macro for man pages.
Suggested change
|
||||||||||||||
|
||||||||||||||
`mac_do(4)` is a kernel MAC security module that allows controlled credential transitions without requiring setuid binaries. The project extended it in two key ways: | ||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We do not need to refer to the man page each single time.
Suggested change
|
||||||||||||||
|
||||||||||||||
* **Per-jail configuration of authorized executables** – administrators can now specify a list of executables per-jail, permitted to request credential transitions, instead of being limited to the hardcoded `/usr/bin/mdo`. | ||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We have a special syntax for filenames too.
Suggested change
|
||||||||||||||
* **Support for traditional credential-changing syscalls** – transitions requested via `setuid(2)`, `setgid(2)`, `setgroups(2)`, and related functions are now intercepted and authorized through `mac_do(4)`, in addition to the original `setcred(2)` mechanism. | ||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||
|
||||||||||||||
On the userland side, the companion tool `mdo(1)` was extended to: | ||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||
|
||||||||||||||
* Allow explicit UID/GID overrides, fine-grained group management (`-g`, `-G`, `-s` options), and improved credential parsing. | ||||||||||||||
* Provide a `--print-rule` option to display the corresponding `mac_do(4)` rule for a requested transition. | ||||||||||||||
|
||||||||||||||
Together, these improvements make `mac_do(4)` and `mdo(1)` far more flexible and practical, enabling safer privilege transitions without relying on setuid executables and with strong jail integration. | ||||||||||||||
Comment on lines
+19
to
+21
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||
|
||||||||||||||
Sponsor: Google LLC (Google Summer of Code 2025) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We usually do not put labels at the beginning of reports. Please remove it unless you have some special need.