pub struct VfsNode {
pub method: &'static str,
pub path: &'static str,
pub kind: VfsNodeKind,
pub scope: &'static str,
pub bulk: bool,
pub mac: &'static str,
}Expand description
A single node in a service’s generated 9P/VFS projection (epic #539, T2).
Built by codegen from each method’s MethodMeta + $vfs* annotations. The
runtime mount engine (T3) consumes these to serve /srv/{service} — path
is mount-relative (fid-0 rooted, never absolute); {braces} in path are
segments that bind the method’s scalar argument.
Fields§
§method: &'static strThe method this node projects (snake_case), used to dispatch on access.
path: &'static strMount-relative path; {name} segments bind a scalar arg from the walk.
kind: VfsNodeKindThe projected node kind (inferred from scope+shape, or $vfsKind).
scope: &'static strAuthorization scope action (from MethodMeta::scope).
bulk: bool$vfsBulk: read returns raw mmap bytes, bypassing capnp (DMA path).
mac: &'static str$vfsMac annotation text declaring this node’s MAC security label
(#699 carrier (a)): the label is a property of the node’s type, derived
at codegen. Decode with VfsNode::mac_label. Empty ⇒ the node is
unlabeled ⇒ deny ⇒ a genesis-coverage finding (no permissive default).
Implementations§
Source§impl VfsNode
impl VfsNode
Sourcepub fn mac_label(&self) -> Option<SecurityLabel>
pub fn mac_label(&self) -> Option<SecurityLabel>
Decode this node’s $vfsMac annotation into a [SecurityLabel].
Returns None when the annotation is empty, malformed, or carries a
non-pq-hybrid assurance — the node is then unlabeled, which the MAC
model treats as deny (there is no permissive default; absence is
denial). Such nodes surface as gaps in the genesis coverage report rather
than being silently defaulted.
Format: "<level>:<assurance>[:<compBit>[,<compBit>...]]" where level
is one of public/internal/confidential/secret, assurance is
required and must be exactly pq-hybrid (the internal non-interop
carrier rejects unverified/classical/omitted — #556), and each
compBit is a u32 compartment bit index (the lattice vocabulary is S3’s
job, #569).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for VfsNode
impl RefUnwindSafe for VfsNode
impl Send for VfsNode
impl Sync for VfsNode
impl Unpin for VfsNode
impl UnsafeUnpin for VfsNode
impl UnwindSafe for VfsNode
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more