Expand description
microsandbox-protocol defines the shared protocol types used for communication
between the host and the guest agent over CBOR-over-virtio-serial.
Modules§
- codec
- Length-prefixed frame codec for reading and writing protocol messages.
- core
- Core protocol message payloads.
- exec
- Exec-related protocol message payloads.
- fs
- Filesystem-related protocol message payloads.
- heartbeat
- Heartbeat data for the guest agent.
- message
- Message envelope and type definitions for the agent protocol.
Enums§
- Protocol
Error - Errors that can occur during protocol operations.
Constants§
- AGENT_
PORT_ NAME - Virtio-console port name for the agent channel.
- AGENT_
RELAY_ ID_ RANGE_ STEP - Size of the correlation ID range allocated to each relay client.
- AGENT_
RELAY_ MAX_ CLIENTS - Maximum number of simultaneous SDK clients the host relay admits.
- ENV_
BLOCK_ ROOT - Environment variable specifying how agentd assembles the root filesystem.
- ENV_
DIR_ MOUNTS - Environment variable carrying virtiofs directory volume mount specs for guest init.
- ENV_
DISK_ MOUNTS - Environment variable carrying disk-image volume mount specs for guest init.
- ENV_
FILE_ MOUNTS - Environment variable carrying virtiofs file volume mount specs for guest init.
- ENV_
HANDOFF_ INIT - Environment variable selecting a guest init binary for PID 1 handoff.
- ENV_
HANDOFF_ INIT_ ARGS - Argv list for the handoff init binary.
- ENV_
HANDOFF_ INIT_ ENV - Extra environment variables for the handoff init binary.
- ENV_
HOSTNAME - Environment variable carrying the guest hostname for agentd.
- ENV_
HOST_ ALIAS - Environment variable carrying the DNS name the guest uses to reach
the sandbox host (Docker’s
host.docker.internalequivalent). - ENV_NET
- Environment variable carrying the guest network interface configuration.
- ENV_
NET_ IPV4 - Environment variable carrying the guest IPv4 network configuration.
- ENV_
NET_ IPV6 - Environment variable carrying the guest IPv6 network configuration.
- ENV_
RLIMITS - Environment variable carrying sandbox-wide resource limits.
- ENV_
TMPFS - Environment variable carrying tmpfs mount specs for guest init.
- ENV_
USER - Environment variable carrying the default guest user for agentd execs.
- FILE_
MOUNTS_ DIR - Guest directory for file mount virtiofs shares.
- GUEST_
TLS_ CA_ PATH - Guest-side path to the CA certificate for TLS interception.
- GUEST_
TLS_ HOST_ CAS_ PATH - Guest-side path to a PEM bundle of the host’s extra trusted CAs.
- HANDOFF_
INIT_ AUTO - Sentinel value for
ENV_HANDOFF_INITrequesting auto-detection. - HANDOFF_
INIT_ AUTO_ CANDIDATES - Ordered list of init-binary paths agentd probes when
ENV_HANDOFF_INITis set toHANDOFF_INIT_AUTO. - HANDOFF_
INIT_ SEP - Separator byte for argv/env entries in handoff-init env vars.
- HANDOFF_
INIT_ SEP_ STR - String form of
HANDOFF_INIT_SEPfor use with&str-friendly APIs like[T]::join. Avoids per-callchar.to_string()allocations on the host’s encoder side. - HANDOFF_
POWEROFF_ TIMEOUT - Maximum time agentd spends in its handoff-mode poweroff sequence.
- RUNTIME_
FS_ TAG - Virtiofs tag for the runtime filesystem (scripts, heartbeat).
- RUNTIME_
MOUNT_ POINT - Guest mount point for the runtime filesystem.
- SCRIPTS_
PATH - Guest path for named scripts (added to PATH by agentd).
- SHUTDOWN_
FLUSH_ TIMEOUT - How long the host waits after forwarding
core.shutdownto agentd before triggering its own VMM exit fallback.
Type Aliases§
- Protocol
Result - The result type for protocol operations.