Configuration and launch
STATIC can run as a standalone binary or inside Rose. Proxy mode requires a selected profile from --profile <name> or pipeline.default_profile in TOML. --list-profiles prints the catalog without starting a listener. Profile anatomy explains the selected JSON; Build from source covers toolchain setup.
Standalone and config-driven runs
From the source checkout, after building:
./src/STATIC_proxy/target/release/static_proxy \
--profiles-path ./src/STATIC_proxy/profiles --list-profiles
./src/STATIC_proxy/target/release/static_proxy \
--profiles-path ./src/STATIC_proxy/profiles --profile firefox-windows
Without a config file, the CLI defaults to loopback port 8443, reserves 8444 for the disabled HTTP/3 path, and serves control on 8445. When run from src/STATIC_proxy/, an existing config/static.example.toml is loaded implicitly; that sample uses loopback proxy port 4040, a disabled HTTP/3 placeholder on 4041, and control on 4042.
cd src/STATIC_proxy
cargo run -- --config config/static.example.toml --profile edge-windows
The leading -- in cargo run -- ... separates Cargo arguments from the application’s arguments. Do not add it when invoking the binary directly. Use a browser from the same engine family as the profile; STATIC logs coherence warnings but does not enforce every match.
Config surfaces and modes
The sample TOML sets the listener, TLS keystore, pipeline.profiles_path, js_debug, alt_svc_strategy, explicit request/response/HTML body limits, disabled HTTP/3 placeholder, and telemetry. The control listener has its own bind setting and uses listener.bind_port + 2; see API authentication. A body over its configured buffer limit may fail instead of passing through unchanged. The release ZIP has a separate Windows-mounted static.runtime.toml, profiles, and token; see Distribution anatomy.
--mode proxy starts the data plane and control listener. --mode control runs the control-only sidecar. The local sample config uses a keychain keystore, while the WSL runtime TOML uses file-backed key custody inside Linux; legacy TLS path fields are compatibility inputs and the managed CA paths resolve under the app-data directory. Use GET /ca/status to locate the public certificate instead of guessing an OS-specific path. CA and trust covers private-key storage and host installation.
For local Linux or WSL eBPF development, scripts/run-static-with-ebpf-caps.sh --profile firefox-windows builds and launches STATIC with capabilities for the pinned map, using a sudo fallback on WSL. A normal cargo run can work as a proxy while map sync fails for lack of BPF permissions. See eBPF verification.
Advertised storage
The runtime supports explicit browser-observation settings through the existing CLI/config path. These are advertised origin-storage values, not a request to inspect or match physical disk capacity.
./src/STATIC_proxy/target/release/static_proxy \
--profiles-path ./src/STATIC_proxy/profiles --profile chrome-windows \
--storage-preset standard --storage-usage 2MiB
| Option | Meaning |
|---|---|
--storage-quota | Explicit advertised quota in bytes or an integer B/KiB/MiB/GiB/TiB quantity. |
--storage-usage | Explicit fixed advertised usage, using the same unit syntax. |
--storage-preset | lower, standard, higher: 10, 50, 100 GiB respectively. |
pipeline.advertised_storage | TOML preset, quota and usage; byte fields are integers. |
[pipeline.advertised_storage]
preset = "standard"
usage = 2097152
Explicit CLI quantities override configured quantities; a CLI preset replaces the configured quota unless an explicit CLI quota accompanies it. Effective explicit quantities take precedence over a preset, then selected profile values, then documented defaults. The setting resolves once into the effective profile before delivery. Usage must be nonnegative and no greater than a positive safe-integer quota; invalid quantities, suffixes or relationships fail validation. Existing profile values need not equal the preset default.
Estimates remain fixed after writes and do not expand when native usage exceeds the advertised quota. Actual allocation/exhaustion and persistence are browser operations. Profile anatomy and storage behavior explain that distinction.
Browser runtime controls
Supported enablement flags belong to the selected JSON policy. Audio and timing do not have hostname exemptions; host hardware does not select a replacement persona. Unsupported APIs and restrictions are explicit, and a flag cannot supply a missing codec, viewer or device. Media-device protection follows the WebRTC enablement flag; event timing follows performance enablement.
The following fields belong under the profile’s fingerprint object, not TOML browser-runtime sections. They refine covered observations; the shared schema supplies types/defaults and rejects invalid choices.
| Profile field | Policy choices and boundary |
|---|---|
canvas_readback_mode | noise (default) or destructive fixed-color redacted; neither supplies another renderer. |
canvas_redaction_color | Four RGBA byte values used by redacted readback. |
canvas_export_budget | Validated bytes and operations bound estimated extra export work; exhaustion explicitly errors. |
webrtc_transport_policy | relay-only (default) or explicit native transport; TURN infrastructure is external. |
webrtc_observation_policy | mask-all (default), or preserve-relay-routing requiring relay-only; usable TURN endpoints remain visible in the latter. |
pdf_inventory_policy | standardized-native (default) or deny; no PDF viewer or absent branded collections are supplied. |
font_inventory_policy | profile-allowlist (default) or native; query restriction applies when fonts are configured, not glyph rendering. |
timezone_legacy_policy | normalize (default), deny, or explicit native nonstandard local parsing; UTC/explicit zones retain meaning. |
audio_context.worklet_policy | legacy-float-noise (default), channel-data-only, or deny-opaque; payload scope/size is bounded and processors are not universally covered. |
Default mask-all can make remote relay signaling unusable. PDF inventory and opaque-message restrictions can throw during feature detection/application use. Review JavaScript behavior and limits and reload relevant contexts after selecting another profile.
Path resolution
settings.rs defines configuration defaults; main.rs applies CLI overrides and resolves launch paths. A config file can replace CLI defaults; relative profile/token paths resolve against the config file’s directory, while --profiles-path resolves against the current working directory.
Defaults by launch contract
| Setting | No-config CLI | Repo sample / macOS operator bundle | Windows operator bundle |
|---|---|---|---|
| Proxy bind | 127.0.0.1:8443 | 127.0.0.1:4040 | 0.0.0.0:4040 inside WSL |
| Control bind | 127.0.0.1:8445 | 127.0.0.1:4042 | 0.0.0.0:4042 inside WSL |
| HTTP/3 config | Disabled, 127.0.0.1:8444 | Disabled, 127.0.0.1:4041 | Disabled, 0.0.0.0:4041 |
| Profile source | profiles/ beside executable unless overridden | ../profiles relative to sample config | ./profiles relative to runtime config |
| Default profile | None; explicit selection required in proxy mode | Repo sample: none. macOS bundle: firefox-windows. | firefox-windows |
| Keystore | Linux file; other platforms keychain | Explicit keychain; implicitly loaded Linux repo sample is changed to file by CLI | file in Linux |
| Control token | None | None in current sample/bundle | ../../../Local/404/wsl/control-token, a fixed example token in published ZIP |
| Telemetry | stdout | stdout | stdout |
0.0.0.0 is an all-interface bind in the runtime environment. Windows forwarding/firewall settings determine host exposure. The bundled example token is not installation-specific entropy. An explicitly requested Linux sample config retains its explicit keystore setting; the CLI’s Linux file-mode adjustment applies to the implicitly discovered repo sample.
Field reference
| Field / flag | Default or behavior |
|---|---|
listener.bind_address, .bind_port | 127.0.0.1, 8443 at the type/no-config level. |
listener.proxy_protocol | tls; accepts tls or plain. Connection classification still handles the supported entry paths. |
control.bind_address | Independently defaults to 127.0.0.1; it does not inherit a proxy bind override. |
| Control port | listener.bind_port.saturating_add(2); choose ordinary ports that leave room for adjacent listeners. |
control.token_path | Optional; unreadable configured file fails startup. Trimmed empty content disables token checking. Restart to reload a changed token. |
pipeline.profiles_path | Required in TOML; directory or JSON path. No-config CLI derives it beside the executable. |
pipeline.default_profile / --profile | None by default; --profile overrides config selection. |
pipeline.js_debug | false. |
pipeline.advertised_storage / storage CLI options | Fixed browser storage observations; see Advertised storage. |
pipeline.alt_svc_strategy | normalize; also accepts remove and redirect. |
pipeline.body_limits.max_request_body_bytes | 16777216 bytes (16 MiB). |
pipeline.body_limits.max_response_body_bytes | 33554432 bytes (32 MiB). |
pipeline.body_limits.max_decompressed_html_bytes | 16777216 bytes (16 MiB). |
http3.enabled | false; current docs do not claim a complete HTTP/3 data plane. |
http3.bind_address, .bind_port | Type defaults: 127.0.0.1, 8444. Config values are separate from TCP listener fields. |
telemetry.mode | stdout; also accepts json. Local telemetry is not an assertion of zero local logging. |
tls.keystore.mode | Backend enum: file or keychain; parsed keystore defaults to keychain, no-config Linux explicitly selects file. |
tls.keystore.service, .account | 404.static_proxy, ca_key. |
Legacy tls.ca_cert_path, .ca_key_path, .cache_dir | If supplied, only compatibility values certs/static-ca.crt, certs/static-ca.key, certs/cache are accepted; actual paths stay managed. |
--config precedence | Explicit path, otherwise existing config/static.example.toml relative to CWD, otherwise built-in defaults. |
--bind-address, --bind-port | Override proxy fields after config loading. --bind-port also sets disabled HTTP/3 config port to proxy + 1; control derives proxy + 2. |
--mode | proxy (default) or control. |
Missing optional nested fields use their serde defaults; this does not mean a TOML file can omit every top-level section. See CA and trust for managed paths and API contract for token behavior.
Implementation map
| Path | Responsibility |
|---|---|
src/STATIC_proxy/src/main.rs, app.rs | CLI overrides, mode selection, shared state, and listeners. |
src/STATIC_proxy/src/proxy/ | Connections, Flows, stages, and upstream fetches. |
src/STATIC_proxy/src/tls/, keystore/ | Certificates, transport planning, key custody. |
src/STATIC_proxy/src/control.rs, telemetry.rs | Local routes and bounded process telemetry. |
src/STATIC_proxy/profiles/ | Browser identities and inherited primitives. |
src/STATIC_proxy/assets/js/src/, build/, build.rs | Browser runtime modules, bundling, and Rust embedding. |
Follow Request path for the pipeline order and JavaScript runtime for the embedded bundle. The generated target/ and JS dist/ directories are build outputs, not hand-edited source.