Skip to content

Commit 9d0b55c

Browse files
Hawk777petreeftime
authored andcommitted
Clarify how to unconditionally match a syscall
This information is available elsewhere, but this seems like a useful place to write it as well (especially for someone coming from the `libseccomp` API, which doesn’t separate rules by syscall number in its public API the way `seccompiler` does). Signed-off-by: Christopher Head <chead@chead.ca>
1 parent 2d373ef commit 9d0b55c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/backend/rule.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ pub struct SeccompRule {
1717
}
1818

1919
impl SeccompRule {
20-
/// Creates a new rule. Rules with 0 conditions are not allowed.
20+
/// Creates a new rule. Rules with 0 conditions are not allowed; to match a syscall regardless
21+
/// of argument values, map the syscall number to an empty vector of rules when constructing
22+
/// the [`SeccompFilter`](super::SeccompFilter) instead.
2123
///
2224
/// # Arguments
2325
///

0 commit comments

Comments
 (0)