Skip to content

backend

Modules

  • platform - Host-platform probes used by sandbox backend selection and preflight checks.

Structs

  • EnforcementProof - Network enforcement proof returned by backend.
  • LaunchSpec - Launch payload for wrapped command.
  • PrepareRequest - Request payload for backend prepare stage.
  • ResolvedGuestShim - A guest shim whose exact bytes were validated against the guest manifest.
  • SandboxHandle - Handle produced by backend prepare stage.
  • SandboxMount - A mount carried by a prepared sandbox together with its security authority.
  • ShimTarget - Target platform triple and executable suffix for a shim binary.

Enums

Traits

  • SandboxBackend - Backend interface for sandbox runtime implementations.

Enum

Supported runtime backend choices.

Variants:

  • Bwrap
  • Vz
  • Wsl2
  • Firecracker

Traits: Eq, Copy

Trait Implementations:

  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • FromStr
    • fn from_str(value: &str) -> Result<Self, <Self as >::Err>
  • Serialize
    • fn serialize<__S>(self: &Self, __serializer: __S) -> _serde::__private229::Result<<__S as >::Ok, <__S as >::Error>
  • From
    • fn from(backend: SchemaBackendKind) -> Self
  • Clone
    • fn clone(self: &Self) -> Self
  • Display
    • fn fmt(self: &Self, f: & mut fmt::Formatter) -> fmt::Result
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • Deserialize
    • fn deserialize<__D>(__deserializer: __D) -> _serde::__private229::Result<Self, <__D as >::Error>

Enum

How the guest reaches the host-side secret broker.

Variants:

  • VsockPort{ port: u32 } - VSOCK port forwarding to the host broker listener.

Traits: Eq, Copy

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool

Struct

Network enforcement proof returned by backend.

Fields:

  • backend: BackendKind
  • structural: bool
  • fail_closed: bool
  • detail: String
  • network_confinement: NetworkConfinement - OS primitive that enforces the network boundary, if any.

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

Struct

Launch payload for wrapped command.

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

Enum

Identifies the OS-level mechanism that provides network confinement.

Used in [EnforcementProof] so operators and audit systems can distinguish structurally equivalent guarantees achieved by different primitives.

Variants:

  • LinuxNetworkNamespace - Linux unprivileged network namespace (bwrap --unshare-net).
  • MacosSandboxNetworkDeny - macOS TrustedBSD MAC sandbox with deny network-outbound policy.
  • MacosVzGuest - Apple Virtualization.framework guest with isolated virtio networking.
  • KvmMicroVm - KVM micro-VM (Firecracker). Planned as enterprise additive path.
  • ProxyOnly - Proxy-only compatibility mode: enforcement depends on HTTP_PROXY

Traits: Eq

Trait Implementations:

  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • Serialize
    • fn serialize<__S>(self: &Self, __serializer: __S) -> _serde::__private229::Result<<__S as >::Ok, <__S as >::Error>
  • Clone
    • fn clone(self: &Self) -> Self
  • Deserialize
    • fn deserialize<__D>(__deserializer: __D) -> _serde::__private229::Result<Self, <__D as >::Error>
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool

Struct

Request payload for backend prepare stage.

Fields:

  • identity: crate::identity::RunIdentity
  • profile: crate::config::ResolvedProfile
  • working_dir: std::path::PathBuf

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

Struct

A guest shim whose exact bytes were validated against the guest manifest.

Traits: Eq

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

firma_run::backend::ResolvedSecretShimSupport

Section titled “firma_run::backend::ResolvedSecretShimSupport”

Enum

Launch-ready secret-shim support after run-specific artifact resolution.

Variants:

  • NotRequired - This launch has no CLI providers and needs no shim artifact.
  • HostBindMount{ target: ShimTarget } - The host-platform shim can be bind-mounted into the sandbox.
  • IsolatedGuest{ broker_bridge: BrokerBridgeKind, guest_shim: ResolvedGuestShim } - An isolated guest shim has been validated against its bundle manifest.

Traits: Eq

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

Trait

Backend interface for sandbox runtime implementations.

Methods:

  • kind: Returns the concrete backend kind.
  • preflight: Checks host support without creating sandbox state.
  • structural_network: Whether this host’s selected mode structurally confines the network.
  • prepare: Prepare host/sandbox state before launching an agent.
  • enforce_network: Install structural network routing and return proof metadata.
  • verify_fail_closed: Verify fail-closed invariants after network policy application.
  • start_agent: Launch the wrapped command inside the prepared sandbox.
  • teardown: Tear down backend runtime state after execution.
  • secret_shim_capability: Returns whether this backend supports CLI secret-provider shim mediation.
  • resolve_secret_shim_support: Resolve launch-specific shim support after validating runtime artifacts.

Struct

Handle produced by backend prepare stage.

Fields:

  • backend: BackendKind
  • runtime_dir: std::path::PathBuf
  • identity: crate::identity::RunIdentity
  • mounts: Vec<SandboxMount> - Prepared mounts, retaining their security authority until a backend
  • network_policy: crate::config::NetworkPolicy

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

Struct

A mount carried by a prepared sandbox together with its security authority.

Operator-provided mounts and framework mounts cannot expose control-plane state. Sandbox-infrastructure mounts are the narrow class allowed to originate in the private per-sandbox runtime.

Traits: Eq

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result

Enum

Whether a backend can support CLI secret-provider shim mediation and how.

Variants:

  • Unsupported{ reason: SecretShimUnsupportedReason } - The backend cannot mediate CLI secret providers.
  • HostBindMount{ target: ShimTarget } - The backend can bind-mount a host-platform shim over the real provider
  • IsolatedGuest{ broker_bridge: BrokerBridgeKind } - The guest is an isolated VM that cannot reach the host directly; a

Traits: Eq

Trait Implementations:

  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • Clone
    • fn clone(self: &Self) -> Self

firma_run::backend::SecretShimUnsupportedReason

Section titled “firma_run::backend::SecretShimUnsupportedReason”

Enum

Why a backend does not support CLI secret-provider shims.

Variants:

  • HostCallable - The guest can call the host directly, so mediation is unnecessary.
  • NotYetImplemented - Guest artifact deployment is not yet implemented for this backend.

Traits: Copy, Eq

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool

Struct

Target platform triple and executable suffix for a shim binary.

Traits: Eq, Copy

Trait Implementations:

  • Clone
    • fn clone(self: &Self) -> Self
  • Debug
    • fn fmt(self: &Self, f: & mut $crate::fmt::Formatter) -> $crate::fmt::Result
  • PartialEq
    • fn eq(self: &Self, other: &Self) -> bool

Host-platform probes used by sandbox backend selection and preflight checks.

All probes are read-only and side-effect-free. On non-Linux targets the functions return safe “not applicable” values so callers don’t need per-platform gating.