You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#26 locked in-binary rustls sc+https:// with self-signed + TOFU pinning as the default and operator PEM optional. What is the concrete provisioning and pinning UX? At minimum: where the server keeps its minted cert/key (.sc/? regenerated when?); where the client stores pins (known_hosts-style user file — location, format) and what happens on first connect (silent accept-new, interactive fingerprint prompt, or strict pre-shared fingerprint) and on mismatch; a non-interactive override for scripting/CI (env var or flag, SC_HTTPS_FINGERPRINT-shaped); how operator PEM is passed to sc serve (--tls-cert/--tls-key); and whether sc serve token output/docs change to mention the fingerprint. Resolution feeds the same phase spec as #26.
Concrete UX for #26's self-signed + TOFU decision — three locked pieces:
First connect: accept-new (ssh StrictHostKeyChecking=accept-new semantics). Unknown host → pin silently, print the fingerprint loudly to stderr, proceed — safe for scripts and agent sessions, which are sc's primary consumers; an interactive prompt was rejected as mostly-theater assurance that hangs automation. Overrides: SC_HTTPS_FINGERPRINT=<spki-sha256> pre-pins for CI/high-assurance first connects; a strict mode refuses unknown hosts outright. A pin mismatch always hard-fails with a what-to-do-if-legitimate recovery hint — never an override prompt; fixing the pin file is a deliberate act.
Pin storage & content: user-level ~/.config/sc/known_hosts, one line per host:port. The pin is the SHA-256 of the server's SPKI (public key), not the whole cert — survives same-key certificate renewal without re-TOFUing every client, and is independently verifiable with stock openssl tooling. Per-repo pins rejected (host identity isn't repo-scoped; clones would diverge silently). BLAKE3 rejected here (never enters the CAS; interop wins).
Server lifecycle: explicit --tls per listener — sc serve --http <addr> --tls [--tls-cert <pem> --tls-key <pem>]; one port speaks exactly one protocol (no ClientHello sniffing), and plaintext sc+http:// survives for loopback/proxy use under the P29-tightened gate from Decide: transport confidentiality for sc+http (audit High #1) #26. Without operator PEM, the server auto-mints a self-signed cert (rcgen) on first TLS serve into .sc/serve-tls/ (cert.pem + key.pem, key 0600), persistent thereafter — under SPKI pinning the key IS the server's identity, so it must survive restarts; regenerated only if the files are missing. Long cert validity; the pinning verifier checks the key and deliberately ignores names/validity (pin-only trust in v1 — CA-path validation can join later for PEM deployments without breaking anything). Fingerprint discovery: the TLS serve startup banner prints the SPKI SHA-256, and a new sc serve fingerprint subcommand prints it on demand; sc serve token add output stays unchanged (transport identity and authorization are separate concerns — docs cross-reference).
Activity
tonibergholm commentedon Jul 10, 2026
Resolution
Concrete UX for #26's self-signed + TOFU decision — three locked pieces:
StrictHostKeyChecking=accept-newsemantics). Unknown host → pin silently, print the fingerprint loudly to stderr, proceed — safe for scripts and agent sessions, which are sc's primary consumers; an interactive prompt was rejected as mostly-theater assurance that hangs automation. Overrides:SC_HTTPS_FINGERPRINT=<spki-sha256>pre-pins for CI/high-assurance first connects; a strict mode refuses unknown hosts outright. A pin mismatch always hard-fails with a what-to-do-if-legitimate recovery hint — never an override prompt; fixing the pin file is a deliberate act.~/.config/sc/known_hosts, one line perhost:port. The pin is the SHA-256 of the server's SPKI (public key), not the whole cert — survives same-key certificate renewal without re-TOFUing every client, and is independently verifiable with stock openssl tooling. Per-repo pins rejected (host identity isn't repo-scoped; clones would diverge silently). BLAKE3 rejected here (never enters the CAS; interop wins).--tlsper listener —sc serve --http <addr> --tls [--tls-cert <pem> --tls-key <pem>]; one port speaks exactly one protocol (no ClientHello sniffing), and plaintextsc+http://survives for loopback/proxy use under the P29-tightened gate from Decide: transport confidentiality for sc+http (audit High #1) #26. Without operator PEM, the server auto-mints a self-signed cert (rcgen) on first TLS serve into.sc/serve-tls/(cert.pem+key.pem, key 0600), persistent thereafter — under SPKI pinning the key IS the server's identity, so it must survive restarts; regenerated only if the files are missing. Long cert validity; the pinning verifier checks the key and deliberately ignores names/validity (pin-only trust in v1 — CA-path validation can join later for PEM deployments without breaking anything). Fingerprint discovery: the TLS serve startup banner prints the SPKI SHA-256, and a newsc serve fingerprintsubcommand prints it on demand;sc serve token addoutput stays unchanged (transport identity and authorization are separate concerns — docs cross-reference).Fully consumes the ticket; remaining detail is phase-spec authorship for the assembly ticket. Parent decision: Decide: transport confidentiality for sc+http (audit High #1).