Bind dialect names to their first-registering principal #6
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The dialect store is content-addressed (keyed by digest), which is good. But the secondary name → latest-digest index is latest-write-wins by name alone, without regard to who taught it. A producer with
ingress:submitscope can teach a malicious(define cbcl-email …)that wildly diverges from the legitimate one. R1-R5 still pass — the body is structurally well-formed; the harm is in the expansion templates pointing at attacker-controlled addresses. Workers subscribed tocbcl-emailor*would then install the malicious version on the next push.Mitigation
Bind each name to the principal that first registered it. Reject re-teach of an existing name from a different principal with
name-already-bound-to-different-principal. Same principal re-teaching new bytes for the same name continues to work as today (versioning a dialect you own is the honest case).Acceptance
cbcl-dialect-storegen_server state grows aname → principalmap (in addition to the existingname → digest).handle_call (teach …)checks: if name exists and recorded-principal ≠ new-principal, reply{error, name_squatting}.cbcl-routerdialect once we ship it again) uses#"router"as principal; matches subsequent same-author re-teach.Out of scope
@anunalets@deploy-botteach on its behalf).See discussion in hark conversation on the dialect-distribution threat model.