docs(tka): state that Tailnet Lock enforcement is active, not observe-only#258
Conversation
…-only The tka_sync module doc, two README entries, and CRYPTOGRAPHY.md described an old observe-only / fail-open / inert posture that contradicts the live code: the peer-trust chokepoint actively fails closed once a lock is synced, dropping a peer with a missing or unauthorized key-signature, and the control runner publishes the verified Authority to that enforcement cell. A maintainer reading the stale docs could wrongly "reconcile" the contradiction by removing enforcement, silently downgrading a working fail-closed security control to verify-only. Rewrite all four to state enforcement is active, keep the genuine remaining gaps named (multi-node lock enrollment, disablement-secret verification, rotation-obsolete dropping), and point to SECURITY.md as the authoritative description. The tka_sign and tka_disable submit-only doc lines that called the posture verify-and-log are corrected the same way. Also fix pre-existing intra-doc-link errors that broke cargo doc on the workspace: an unresolved Display link and a link to the private PROTO_NAMES in ts_control_serde, plus redundant explicit link targets in ts_runtime and the facade. cargo doc --workspace is clean again under broken_intra_doc_links=deny. No code or behavior change. Signed-off-by: GeiserX <9169332+GeiserX@users.noreply.github.com>
|
Warning Review limit reached
More reviews will be available in 42 minutes and 54 seconds. Learn how PR review limits work. Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file). ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (7)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
What
Correct stale documentation that described Tailnet Lock (TKA) as observe-only / fail-open / inert, contradicting the live code, which actively enforces.
The peer-trust chokepoint (
ts_runtime::peer_tracker::tka_snapshot_admits, mirroring Go'stkaFilterNetmapLocked) fails closed once a lock is synced: a peer presenting a missing or unauthorizedkey_signatureis dropped at the peer-db upsert path, and the control runner publishes the verifiedAuthorityto that enforcement cell. The authority only ever reaches that path afterVerifiedAumChain::verify, so a malicious control plane cannot forge a trusted key — it can only toggle the lock.Why this matters
A maintainer reading the stale
tka_syncmodule doc ("observe-only, fail-open … never drops a peer … enforcement is a separate, later, gated decision") could "reconcile" the contradiction with the enforcing code by removing enforcement — silently downgrading a working fail-closed security control to verify-only. This is a documentation-integrity fix flagged by security audits.Changed docs
ts_runtime/src/tka_sync.rs— module doc: separate the two distinct claims (a failed sync is fail-open and leaves prior enforcement untouched; a successfully syncedAuthorityis actively enforced), with an explicit "do not remove enforcement to match an outdated reading" note.README.md— the### Implementedand### UnsupportedTKA entries: "inert" / "not yet built" → actively enforcing, with the genuine remaining gaps named.docs/CRYPTOGRAPHY.md— "Enforcement posture — observe-only (verify-and-LOG)" → actively fail-closed (the staletka_observesymbol no longer exists; the real path istka_authority→tka_snapshot_admits).src/lib.rs— thetka_sign/tka_disablesubmit-only doc lines that called the posture "verify-and-log".The authoritative posture / threat model / deferred gaps live in
SECURITY.md; these are made consistent with it.Also: fix pre-existing
cargo docbreakagecargo doc --workspace(which CI runs, and which enforcesbroken_intra_doc_links = "deny") was failing onmain, unrelated to TKA:ts_control_serde/src/service_vip.rs: an unresolved[Display]link (nowcore::fmt::Display) and a public-doc link to the privatePROTO_NAMES(now plain code text) — these are hardbroken_intra_doc_linkserrors.ts_runtime(peer_tracker,status) and the facade (src/lib.rs) — caught under-D warnings.cargo doc --workspace --no-depsis now clean both plain (CI's form) and underRUSTDOCFLAGS="-D warnings".Verification
No code or behavior change.
cargo fmt --checkclean;cargo doc --workspace --no-depsclean (plain + strict); doctests pass. Verified each doc claim against the live enforcement code (peer_tracker/mod.rstka_snapshot_admits,control_runner.rsenforcement cell).Signed-off-by: Sergio sergio@geiser.cloud
Created using Claude Code (Opus 4.8)