Debian Codegraph @

src/action.rs

raw symbols SCIP
1 // SPDX-License-Identifier: Apache-2.0 or MIT
2 //
3 // Copyright 2021 Sony Group Corporation
4 //
5
6 use craterust-analyzer cargo libseccomp 0.4.0 crate/::errorrust-analyzer cargo libseccomp 0.4.0 error/::ErrorKindrust-analyzer cargo libseccomp 0.4.0 error/ErrorKind#::*;
7 use craterust-analyzer cargo libseccomp 0.4.0 crate/::errorrust-analyzer cargo libseccomp 0.4.0 error/::{Resultrust-analyzer cargo libseccomp 0.4.0 error/Result#, SeccompErrorrust-analyzer cargo libseccomp 0.4.0 error/SeccompError#};
8 use libseccomp_sysrust-analyzer cargo libseccomp-sys 0.3.0 crate/::*;
9 use stdrust-analyzer cargo std https://github.com/rust-lang/rust/library/std crate/::convertrust-analyzer cargo core https://github.com/rust-lang/rust/library/core convert/::TryIntorust-analyzer cargo core https://github.com/rust-lang/rust/library/core convert/TryInto#;
10
11 /// Represents an action to be taken on a filter rule match in the libseccomp.
12 #[deriverust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/builtin/derive:(Debugrust-analyzer cargo core https://github.com/rust-lang/rust/library/core fmt/macros/Debug:, Clonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core clone/Clone:, Copyrust-analyzer cargo core https://github.com/rust-lang/rust/library/core marker/Copy:, PartialEqrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/PartialEq:, Eqrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/Eq:, Hashrust-analyzer cargo core https://github.com/rust-lang/rust/library/core hash/macros/Hash:)]
13 #[non_exhaustive]
14 pub enum ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction# {
15 /// Kills the process.
16 KillProcessrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillProcess#,
17 /// Kills the thread.
18 KillThreadrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillThread#,
19 /// Throws a SIGSYS signal.
20 Traprust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trap#,
21 /// Triggers a userspace notification.
22 /// NOTE: This action is only usable when the libseccomp API level 6
23 /// or higher is supported.
24 Notifyrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Notify#,
25 /// Returns the specified error code.
26 /// NOTE: You can only use integers from 0 to `u16::MAX`.
27 Errnorust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Errno#(i32),
28 /// Notifies a tracing process with the specified value.
29 Tracerust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trace#(u16),
30 /// Allows the syscall to be executed after the action has been logged.
31 Logrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Log#,
32 /// Allows the syscall to be executed.
33 Allowrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Allow#,
34 }
35
36 impl ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction# {
37 pub(craterust-analyzer cargo libseccomp 0.4.0 crate/) fn to_sysrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]to_sys().(self) -> u32 {
38 match self {
39 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::KillProcessrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillProcess# => SCMP_ACT_KILL_PROCESSrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_KILL_PROCESS.,
40 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::KillThreadrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillThread# => SCMP_ACT_KILL_THREADrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_KILL_THREAD.,
41 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Traprust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trap# => SCMP_ACT_TRAPrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_TRAP.,
42 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Notifyrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Notify# => SCMP_ACT_NOTIFYrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_NOTIFY.,
43 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Errnorust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Errno#(x) => SCMP_ACT_ERRNOrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_ERRNO().(x as u16),
44 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Tracerust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trace#(x) => SCMP_ACT_TRACErust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_TRACE().(x),
45 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Logrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Log# => SCMP_ACT_LOGrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_LOG.,
46 Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Allowrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Allow# => SCMP_ACT_ALLOWrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_ALLOW.,
47 }
48 }
49
50 pub(craterust-analyzer cargo libseccomp 0.4.0 crate/) fn from_sysrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_sys().(val: u32) -> Resultrust-analyzer cargo libseccomp 0.4.0 error/Result#<Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]> {
51 match val rust-analyzer cargo core https://github.com/rust-lang/rust/library/core ops/bit/impl#[u32][`BitAnd<Self>`]bitand().&rust-analyzer cargo core https://github.com/rust-lang/rust/library/core ops/bit/impl#[u32][`BitAnd<Self>`]bitand(). rust-analyzer cargo core https://github.com/rust-lang/rust/library/core ops/bit/impl#[u32][`BitAnd<Self>`]bitand().SCMP_ACT_MASKrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_MASK. {
52 SCMP_ACT_KILL_PROCESSrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_KILL_PROCESS. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::KillProcessrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillProcess#),
53 SCMP_ACT_KILL_THREADrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_KILL_THREAD. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::KillThreadrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillThread#),
54 SCMP_ACT_TRAPrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_TRAP. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Traprust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trap#),
55 SCMP_ACT_NOTIFYrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_NOTIFY. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Notifyrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Notify#),
56 SCMP_ACT_ERRNO_MASKrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_ERRNO_MASK. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Errnorust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Errno#(val as u16 as i32)),
57 SCMP_ACT_TRACE_MASKrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_TRACE_MASK. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Tracerust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trace#(val as u16)),
58 SCMP_ACT_LOGrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_LOG. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Logrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Log#),
59 SCMP_ACT_ALLOWrust-analyzer cargo libseccomp-sys 0.3.0 SCMP_ACT_ALLOW. => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Allowrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Allow#),
60 inv => Errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Err#(SeccompErrorrust-analyzer cargo libseccomp 0.4.0 error/SeccompError#::newrust-analyzer cargo libseccomp 0.4.0 error/impl#[SeccompError]new().(InvalidActionrust-analyzer cargo libseccomp 0.4.0 error/ErrorKind#InvalidAction#(inv))),
61 }
62 }
63
64 /// Converts string seccomp action to `ScmpAction`.
65 ///
66 /// # Arguments
67 ///
68 /// * `action` - A string action, e.g. `SCMP_ACT_*`.
69 ///
70 /// See the [`seccomp_rule_add(3)`] man page for details on valid action values.
71 ///
72 /// [`seccomp_rule_add(3)`]: https://www.man7.org/linux/man-pages/man3/seccomp_rule_add.3.html
73 ///
74 /// # Errors
75 ///
76 /// If an invalid action is specified or a value on `"SCMP_ACT_TRACE"` is not in the
77 /// range from 0 to `u16::MAX`, an error will be returned.
78 pub fn from_strrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_str().(action: &str, val: Optionrust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#<i32>) -> Resultrust-analyzer cargo libseccomp 0.4.0 error/Result#<Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]> {
79 match action {
80 "SCMP_ACT_KILL_PROCESS" => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::KillProcessrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillProcess#),
81 "SCMP_ACT_KILL_THREAD" | "SCMP_ACT_KILL" => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::KillThreadrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillThread#),
82 "SCMP_ACT_TRAP" => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Traprust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trap#),
83 "SCMP_ACT_NOTIFY" => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Notifyrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Notify#),
84 "SCMP_ACT_ERRNO" => match val {
85 Somerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#Some#(v) => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Errnorust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Errno#(v)),
86 Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None# => Errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Err#(SeccompErrorrust-analyzer cargo libseccomp 0.4.0 error/SeccompError#::newrust-analyzer cargo libseccomp 0.4.0 error/impl#[SeccompError]new().(Commonrust-analyzer cargo libseccomp 0.4.0 error/ErrorKind#Common#(
87 "Missing an errno value of SCMP_ACT_ERRNO in ScmpAction::from_str".intorust-analyzer cargo core https://github.com/rust-lang/rust/library/core convert/impl#[T][`Into<U>`]into().(),
88 ))),
89 },
90 "SCMP_ACT_TRACE" => match val {
91 Somerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#Some#(v) => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Tracerust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trace#(v.try_intorust-analyzer cargo core https://github.com/rust-lang/rust/library/core convert/impl#[T][`TryInto<U>`]try_into().()?rust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`][Try]branch().)),
92 Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None# => Errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Err#(SeccompErrorrust-analyzer cargo libseccomp 0.4.0 error/SeccompError#::newrust-analyzer cargo libseccomp 0.4.0 error/impl#[SeccompError]new().(Commonrust-analyzer cargo libseccomp 0.4.0 error/ErrorKind#Common#(
93 "Missing a message value of SCMP_ACT_TRACE in ScmpAction::from_str".intorust-analyzer cargo core https://github.com/rust-lang/rust/library/core convert/impl#[T][`Into<U>`]into().(),
94 ))),
95 },
96 "SCMP_ACT_LOG" => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Logrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Log#),
97 "SCMP_ACT_ALLOW" => Okrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Ok#(Selfrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]::Allowrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Allow#),
98 _ => Errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#Err#(SeccompErrorrust-analyzer cargo libseccomp 0.4.0 error/SeccompError#::newrust-analyzer cargo libseccomp 0.4.0 error/impl#[SeccompError]new().(FromStrrust-analyzer cargo libseccomp 0.4.0 error/ErrorKind#FromStr#(action.to_stringrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc string/impl#[T][ToString]to_string().()))),
99 }
100 }
101 }
102
103 #[cfg(test)]
104 mod testsrust-analyzer cargo libseccomp 0.4.0 action/tests/ {
105 use superrust-analyzer cargo libseccomp 0.4.0 action/::*;
106
107 #[testrust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/builtin/test:]
108 fn test_parse_actionrust-analyzer cargo libseccomp 0.4.0 action/tests/test_parse_action().() {
109 let test_data = &[
110 ("SCMP_ACT_KILL_PROCESS", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::KillProcessrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillProcess#),
111 ("SCMP_ACT_KILL_THREAD", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::KillThreadrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillThread#),
112 ("SCMP_ACT_KILL", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::KillThreadrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#KillThread#),
113 ("SCMP_ACT_TRAP", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::Traprust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trap#),
114 ("SCMP_ACT_NOTIFY", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::Notifyrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Notify#),
115 ("SCMP_ACT_ERRNO", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::Errnorust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Errno#(10)),
116 ("SCMP_ACT_TRACE", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::Tracerust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Trace#(10)),
117 ("SCMP_ACT_LOG", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::Logrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Log#),
118 ("SCMP_ACT_ALLOW", ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::Allowrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#Allow#),
119 ];
120
121 for data in test_data {
122 if data.0 rust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/impls/impl#[`&A`][`PartialEq<&B>`]eq().==rust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/impls/impl#[`&A`][`PartialEq<&B>`]eq(). rust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/impls/impl#[`&A`][`PartialEq<&B>`]eq()."SCMP_ACT_ERRNO" || data.0 rust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/impls/impl#[`&A`][`PartialEq<&B>`]eq().==rust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/impls/impl#[`&A`][`PartialEq<&B>`]eq(). rust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/impls/impl#[`&A`][`PartialEq<&B>`]eq()."SCMP_ACT_TRACE" {
123 assert_eqrust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/assert_eq!!(
124 ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_sysrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_sys().(ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_strrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_str().(data.0, Somerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#Some#(10)).unwraprust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]unwrap().().to_sysrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]to_sys().())
125 .unwraprust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]unwrap().(),
126 data.1
127 );
128 } else {
129 assert_eqrust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/assert_eq!!(
130 ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_sysrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_sys().(ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_strrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_str().(data.0, Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None#).unwraprust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]unwrap().().to_sysrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]to_sys().())
131 .unwraprust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]unwrap().(),
132 data.1
133 );
134 }
135 }
136 assertrust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/builtin/assert!!(ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_strrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_str().("SCMP_ACT_ERRNO", Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None#).is_errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]is_err().());
137 assertrust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/builtin/assert!!(ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_strrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_str().("SCMP_ACT_TRACE", Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None#).is_errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]is_err().());
138 assertrust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/builtin/assert!!(ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_strrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_str().("SCMP_INVALID_FLAG", Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None#).is_errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]is_err().());
139 assertrust-analyzer cargo core https://github.com/rust-lang/rust/library/core macros/builtin/assert!!(ScmpActionrust-analyzer cargo libseccomp 0.4.0 action/ScmpAction#::from_sysrust-analyzer cargo libseccomp 0.4.0 action/impl#[ScmpAction]from_sys().(0x00010000).is_errrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/impl#[`Result<T, E>`]is_err().());
140 }
141 }