What happened
API-key creation trims surrounding whitespace during request parsing, but CLI disable, enable, and revoke resolve later name arguments using an unnormalized exact comparison.
Reproduction:
dor apikey create ' incident key '
dor apikey disable ' incident key '
dor apikey ls
dor apikey disable 'incident key'
Repeat with revoke in place of disable to reproduce the irreversible-command path.
Expected: The same accepted name spelling used at creation should resolve the resulting key, or creation should reject non-canonical input.
Actual: Creation stores incident key. Verbatim disable reports no such key, and verbatim revoke reports that nothing was revoked while the credential remains active. The trimmed spelling succeeds.
Impact: Scripts or operators reusing the original operand can fail to disable or revoke a credential, leaving it active until they use the normalized spelling.
dor doctor output
Not applicable — the normalization mismatch was reproduced through schemas, validation, SDK, CLI command functions, and an in-memory database and does not depend on host readiness. dor doctor was not run.
Environment
- Reproduction mode: Focused-source reproduction
- Dormice commit:
4417ae14938273f5d937c476cf7cdc57e22e53a5
- Verification: Verified through the current shared schema, Fastify validation, SDK, CLI command functions, and in-memory database at
4417ae14938273f5d937c476cf7cdc57e22e53a5.
What happened
API-key creation trims surrounding whitespace during request parsing, but CLI disable, enable, and revoke resolve later name arguments using an unnormalized exact comparison.
Reproduction:
Repeat with
revokein place ofdisableto reproduce the irreversible-command path.Expected: The same accepted name spelling used at creation should resolve the resulting key, or creation should reject non-canonical input.
Actual: Creation stores
incident key. Verbatim disable reports no such key, and verbatim revoke reports that nothing was revoked while the credential remains active. The trimmed spelling succeeds.Impact: Scripts or operators reusing the original operand can fail to disable or revoke a credential, leaving it active until they use the normalized spelling.
dor doctor output
Not applicable — the normalization mismatch was reproduced through schemas, validation, SDK, CLI command functions, and an in-memory database and does not depend on host readiness.
dor doctorwas not run.Environment
4417ae14938273f5d937c476cf7cdc57e22e53a54417ae14938273f5d937c476cf7cdc57e22e53a5.