Repository navigation
spec(profile): explicit Keld legacy profile key — one location, parse into admit(Legacy), ProfileState↔AuthorityProfile mapping, forfeit printing, unverified unscoreable by design #586
Description
Activity
- addedelectron-compatElectron compatibility program areaElectron compatibility program area
on Oct 6, 2026 - addedenhancementNew feature or requestNew feature or requestcompat:tier-1Electron compat Tier 1 (arch 04 §4)Electron compat Tier 1 (arch 04 §4)ready-for-agentFully specified; an AFK agent can take itFully specified; an AFK agent can take itmilestone:first-proofNeeded for the first migration proof (drawio-desktop on macOS, explicit legacy profile)Needed for the first migration proof (drawio-desktop on macOS, explicit legacy profile)
on Oct 6, 2026 This was generated by AI during triage.
Agent Brief
Category: enhancement
Summary: spec(profile): explicit Keldlegacyprofile key — one location, parse into admit(Legacy), ProfileState↔AuthorityProfile mapping, forfeit printing,unverifiedunscoreable by designCurrent behavior:
Verified at origin/main 8678c0d: keld-guard ProfileState {unverified, legacy, strict} and admit() are live. No config key exists. There is no ProfileState consumer in keld-runtime, keld-host or keld-cli (refuter grep at b4b907c, surfaces unchanged).Desired behavior:
Write the KEL-78 spec amendment that creates the profile key. The first proof runs draw.io 'under an explicitly declared legacy profile', and KEL-78 says the key 'does not exist today'.The spec decides:
- one location for the key. This is the single owner question: keld.permissions.jsonc or the Keld app config. Recommendation: keld.permissions.jsonc, because arch 06 gives it the capability subset and the key changes authority, not lifecycle.
- the grammar
profile: "strict" | "legacy"; - that Electron sandbox/appSandbox, fuses, package names and architecture never set the key;
- the mapping keld-guard ProfileState Legacy → evidence authority_profile legacy_sandbox_off;
- that
unverifiedhas no evidence value and is unscoreable by design (no enum addition); - forfeit printing on the build, doctor and scoreboard surfaces (the KEL-78 T6 table);
- the implementation slice (X03-T7) with its gates.
Adjacent atoms owned elsewhere:
- migrate writing the key only after user acceptance is X02's (KEL-17 Done; migrate is unowned in Linear).
- strict admission itself is KEL-78's T-series.
- X02-T1 (the migrate key→owner table) and X02-T3 (the hand-authored draw.io artefact) consume the location this spec selects and are blocked by it. Neither pre-decides the file; X02-T1's profile row names X03-T5 (spec) and X03-T7 (implementation).
Key interfaces:
- The profile key grammar; admit() input; the authority_profile mapping; forfeit strings on the reporting surfaces.
Acceptance criteria:
- The spec is approved by exact content. It names one key location, the grammar, and the rule that no Electron option or package name selects a profile.
- The spec states the mapping legacy → legacy_sandbox_off and that undeclared (unverified) apps produce no scoreable record.
- The spec's test plan contains three fixtures: a config with the key reaches admit() as Legacy; a config without it is reported unverified; Electron sandbox:false with no key is never legacy.
- The spec names X03-T7 as the implementation slice with permission-model and public-API gates.
- Negative control: A draft that derives legacy from Electron sandbox:false is rejected under the KEL-78 rule.
- Negative control: A draft that adds
unverifiedto the evidence authority enum is rejected.
Out of scope:
- Strict admission and the per-OS archive (KEL-78 T2–T5). The migrate UX (X02). Per-role profiles (legacy primary + strict addon worker), which stay a not-yet-specified question.
Tracker of record and claim location: see "Ownership and gates" in the issue body.
Parent
Epic #501 · Map #391 · Unit X03 · Kind:
spec· Tier: Tier 1 · Maturity target: L0 · Size: S · Milestone:first-proofWhat to build
Write the KEL-78 spec amendment that creates the profile key. The first proof runs draw.io 'under an explicitly declared legacy profile', and KEL-78 says the key 'does not exist today'.
The spec decides:
profile: "strict" | "legacy";unverifiedhas no evidence value and is unscoreable by design (no enum addition);Adjacent atoms owned elsewhere:
Acceptance criteria
Negative controls (each names the one mutation that must fail)
unverifiedto the evidence authority enum is rejected.External predecessors (outside this tracker)
Ownership and gates
The authoritative agent contract is the latest Agent Brief comment on this issue (triage skill); this body is the planning record.
Out of scope
Strict admission and the per-OS archive (KEL-78 T2–T5). The migrate UX (X02). Per-role profiles (legacy primary + strict addon worker), which stay a not-yet-specified question.
Notes
Owner-only question: key location, with the recommendation keld.permissions.jsonc. Falsifier for the recommendation: arch 06 or KEL-78 assigns authority-changing keys to the app config.
Change log (doctrine-audit repair, 2026-10-07)