Skip to content

Two more secret-field spellings still render type="text" on the form's unregistered-widget branch: ui:password and a bare secret #5375

Description

@os-support-ai

Found while implementing #5322 (the field:-prefixed secret leak). Out of that card's scope and not changed by its PR#5322 was scoped by its dispatch to the field: namespace and the two types the filer measured, and its PR states that narrowness deliberately. Recorded here rather than widened in silently.

Measured

Same probe as #5322 — the real form renderer on the built-in path (no registerAllFields()), main at f2e11ae6f, before and after #5322's fix:

type registry hit rendered type
ui:password true text
secret false text
field:secret false text

All three put the value on screen in clear text. For comparison, the two spellings #5322 does answer:

password true password (native masked input)
field:password false refusal (after #5322 — no input, no value in the DOM)

Why each one misses

Reachability, stated honestly

None of the three is emitted by a producer. All three are reachable only through a hand-authored form schema, which is why they were left out of #5322 rather than folded in. That makes this lower severity than #5322 — but the failure mode is identical (a secret rendered in clear text, in a control that looks like it worked), and the hand-authored standalone form is exactly the surface where the author is the producer and no normalizer sits in between.

The question for triage

Not obviously one shape:

  • A — extend the existing narrow tables. Add secret to NATIVE_INPUT_FIELD_TYPES / SECRET_FIELD_TYPES in packages/components/src/renderers/form/form.tsx, and decide whether a non-field: namespace should have its prefix stripped too. Cheap; leaves the class open for the next spelling.
  • B — decide the class, not the spellings. State once what an unregistered namespaced widget id means on the field path, and whether any spelling of a secret type may ever reach a rendered control. A field:-prefixed password / email field renders type="text" when its widget is not registered — a secret shown in clear text #5322 answered that for field: only, on the ground that field: is the one namespace meaning "field widget"; whether ui: deserves the same treatment or should be rejected outright at the field path is undecided.
  • C — reject at authoring.secret and ui:password are both off-contract as a form fieldtype. A publish-time / validate-time refusal is the contract-first shape and would not need the renderer to grow a table at all.

Related: #5322 (the field: half, fixed), #5254 (the fallback removal that routed these spellings to the default branch).

Search record

search_issues over the namespaced-password / clear-text / secret-field-type keywords; the hits were #5322 (this card's parent finding, open) and #4221 (closed — inline edit on the detail page writing the mask back, a different mechanism). No duplicate.


Generated by Claude Code

Metadata

Metadata

Assignees

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions