Skip to main content

Module sidecar_guard

Module sidecar_guard 

Source
Expand description

Launch-token authentication for the supervised uar-sidecar process.

The host that launches the sidecar writes a per-launch 256-bit token as the first line of the sidecar’s stdin. SidecarGuard then admits a request only when it carries that token or an explicitly scoped host-issued grant, names the sidecar’s own loopback authority, and carries no Origin header. A loopback port is not an authentication boundary: any local process, and a web page through DNS rebinding or a cross-origin request, can reach it. See the OpenSpec change sidecar-launch-security.

Structs§

HostAuthenticated
Marker installed only after the outer launch-token guard admits a request. Inner authentication may trust host assertions only when this marker exists.
HostBoundPrincipal
Request marker for a launch-bound sidecar. It is installed only by enforce on a launch-token match, never on the delegation-grant path, and it can be constructed only in this module.
InvalidBoundPrincipal
The launch-bound principal was not a valid host principal.
InvalidLaunchToken
The first stdin line was missing or was not a well-formed launch token.
SidecarBoundPrincipal
The one owner a launch-bound sidecar serves for its whole lifetime.
SidecarGuard
Per-request admission for the sidecar port.
SidecarLaunchToken
The token the host handed the sidecar over stdin, plus the optional principal the same host bound the process to at launch.

Functions§

enforce
Outermost middleware of a token-authenticated sidecar.