Console access
enforce_console_route_access checks whether a request should be allowed to access console routes.
Decision rules
Runtime ops validation
validate_runtime_ops_policy enforces v0.1 operational constraints.
BigQuery naming
validate_bigquery_naming ensures dataset and table names are safe.
Validation rules
- Dataset must be non-empty
- Table must be non-empty
- Both must contain only ASCII alphanumeric characters, underscores, and hyphens
- No dots, semicolons, spaces, or other special characters
Trusted module loading
load_trusted_mobkit_modules_from_toml parses and validates a trust manifest.
Validation rules
- Module
idmust be non-empty - Module
commandmust be non-empty - TOML must parse correctly; an empty manifest (no
[[modules]]table) declares no modules - Restart policy defaults to
OnFailurewhen omitted
Release metadata
validate_release_metadata ensures release targets are complete and the support matrix is valid.
Required targets
Every release must include all four targets:Validation rules
- No duplicate targets
- All required targets must be present
support_matrixmust equal"same-as-meerkat"
Runtime decision state
build_runtime_decision_state turns raw policy documents into the
RuntimeDecisionState the runtime consults while serving. It runs every check
below in order and returns the first refusal as a typed
DecisionRuntimeError::Policy(DecisionPolicyError); nothing panics, so a host
that crashes at startup is unwrapping the result.
Check 5 requires a non-empty
audience, a discovery document with issuer
and jwks_uri, and a JWKS with at least one key. It is skipped with
require_app_auth: false because an open console never verifies a token on
its own; the console’s request-time path re-validates the same snapshot and
fails closed whenever a token actually has to be checked. ConsolePolicy::default()
has require_app_auth: true, so a host that keeps the default still needs a
complete snapshot.
One consequence of the conditional check: an open console with an ABAC
AccessController installed still resolves a token a caller volunteers, and a
broken snapshot then degrades that caller to anonymous instead of refusing at
startup. A host that wants the startup refusal on an open console calls
validate_trusted_oidc_runtime_config(&inputs.trusted_oidc)? itself before
building.
Opting out of console auth
RuntimeDecisionState::local_console(console, bigquery) is the explicit
opt-out and the single owner of the keyless snapshot both gateway binaries
serve: a discovery document whose issuer resolves nowhere, a JWKS with no
keys, no trusted modules, default auth and ops policies, and the canonical
release metadata. It bypasses the validator because there is nothing to
validate about a snapshot that trusts nothing.
console, the session-store naming and
modules (the trusted module set console ingress consults); local_console
takes the first two as parameters and with_modules covers the third.
The default stays fail-closed: local_console(ConsolePolicy::default(), None)
requires app auth and trusts no key, so it refuses every request. This is
exactly what rpc_gateway serves when an SDK launch passes neither
runtime_options.auth_config nor console_require_app_auth: false; it logs a
startup warning naming the condition.
RuntimeDecisionState has public fields, so a struct literal is also a
supported construction path; it skips every check above.
Error types
All decision functions returnDecisionPolicyError:
See also
- Authentication — auth policy usage
- Configuration — all configuration types
- Governance — release candidate tracking
