LearnNewsExamplesServices
Frontmatter
id19238
titleADR 0034 §2.3: the credential window is a native password field
stateClosed
labels
documentationaiarchitecture
assigneesneo-opus-ada
createdAtSep 26, 2026, 9:27 AM
updatedAtSep 26, 2026, 10:48 AM
githubUrlhttps://github.com/neomjs/neo/issues/19238
authorneo-opus-ada
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtSep 26, 2026, 10:48 AM

ADR 0034 §2.3: the credential window is a native password field

Closed v13.2.0/archive-v13-2-0-chunk-23 documentationaiarchitecture
neo-opus-ada
neo-opus-ada commented on Sep 26, 2026, 9:27 AM

Context

  • The operator's ask. On 2026-09-26 @tobiu asked why the packaged shell asks for a PAT in a window that is only text: "why not use a PasswordField? I would not know that cmd+v would work." That window is the shell's one credential surface. It serves plane attach and every credential-bearing Fleet verb (connectTenant, defineAgent).
  • The Institution change. neomjs/neo-agent-institution#227 replaces the window with a native <input type="password"> inside the same isolated, script-free window.
  • Why the ADR moves first. That puts credential bytes in a renderer. ADR 0034 §2.3 forbids this today, and its own falsifier requires an amendment first: "any leaf needing a renderer capability … amends THIS section first … it never … moves secret bytes into renderer state as a leaf-local decision."

The Problem

The text that binds today (learn/agentos/decisions/0034-electron-shell-architecture.md, dev@6b37906b9a):

  • Anti-anchor row: "credential or token bytes in renderer-readable state (§2.3)".
  • §2.3 heading: "credentials never renderer-readable".
  • §2.3 item 8 (attachPlane): "collects the PAT in the main-custody credential window (the page receives no key or paste data)".

The window that item 8 describes shows no field and no button. Its only verbs are Enter and Escape, and it reports its length in the title bar.

It is also less secure than a native field. On macOS, Chromium turns on Secure Event Input only while a native password field has focus. A page with no input element never gets it, so today a typed PAT is readable by any process holding Input Monitoring.

The Architectural Reality

Element-less window (today) Native password field (#227)
Secure Event Input (macOS) off: typed keys readable via Input Monitoring on while focused, off after settle, measured below
Caret, selection, undo, ⌘V, AX secure-text role none: editing emulated in main the platform's own
Where the bytes live while typing main the credential window's renderer, until submit
Cockpit renderer / App Worker never never (unchanged)

Measured on Electron 43.1.0 (darwin), driving #227's module:

  • ioreg -l -w 0 showed kCGSSessionSecureInputPID = the probe's own main PID while the field had focus, and no holder after the prompt settled.
  • Submit resolved the exact typed value. Cancel, Escape, closing the window and a whitespace-only Enter each behaved as specified.
  • The page ran zero scripts.

The Fix

Amend §2.3. No other section changes.

  1. New item 9, "The credential window."
    • The window collects the credential in a native password field, in a sandboxed, context-isolated window of its own.
    • Its document carries no script, under CSP default-src 'none'.
    • A window-only preload hands the value to main once, on submit, over that window's own webContents.ipc.
    • Main destroys the window on every settle path: submit, cancel, close, renderer gone.
    • Main alone holds the credential after submit. The cockpit's renderer and the App Worker never hold it (items 5–6 unchanged).
    • Rationale: platform Secure Event Input and native editing, measured.
  2. Item 8 drops "(the page receives no key or paste data)" and points to item 9.
  3. The anti-anchor row and §2.3's heading scope the ban to renderer-readable state outside the credential window (§2.3.9).
  4. Provenance follows items 7 and 8: (amended 2026-09-26, #N — for neomjs/neo-agent-institution#227).

Acceptance Criteria

  • §2.3 carries item 9 as specified. Item 8's parenthetical, the anti-anchor row and §2.3's heading are scoped to it, with the provenance bracket.
  • No other ADR text changes. Items 5–6 (the per-boot token and seat PATs) stay exactly as they are.

Out of Scope

  • The Institution implementation: neomjs/neo-agent-institution#227.
  • The cockpit's dev-server-topology PasswordFields (item 6's transitional path).

Decision Record impact

amends ADR 0034 §2.3 (items 8–9, the anti-anchor row, the heading).

Related

  • #19228 / #19233 added and amended item 8.
  • #19237 (Grace) amends §2.3 item 2 in the same file, on separate lines.
  • neomjs/neo-agent-institution#227.

Sweeps:

  • Live latest-open sweep: checked the latest 20 open neo issues at 2026-09-26T07:27Z; no equivalent found (#19237 touches item 2 only).
  • A2A: the Dock Layouts claim is the only other new claim.

Origin Session ID: 1b945fcf-1142-475f-8007-ac18d51c069a Retrieval Hint: "ADR 0034 credential window native password field Secure Event Input"

tobiu referenced in commit 47fe933 - "docs(adr): ADR-0034 §2.3 makes the credential window a native password field (#19238) (#19239) on Sep 26, 2026, 10:48 AM
tobiu closed this issue on Sep 26, 2026, 10:48 AM