Skip to content

feat(favorites): never store a password in a saved query - #615

Merged
EVWorth merged 1 commit into
mainfrom
feat/favorites-redaction
Sep 10, 2026
Merged

EVWorth merged 1 commit into
mainfrom
feat/favorites-redaction

Conversation

@EVWorth

@EVWorth EVWorth commented Sep 10, 2026

Copy link
Copy Markdown
Owner

Closes #339.

A favorite carrying IDENTIFIED BY 's3cret' was written to storage as typed, walking past the keyring the same way history did before #587. A favorite is kept deliberately and for longer than a history entry, so the case is stronger here, not weaker.

Credentials are stripped on the way in — on save and on edit, since an edit can introduce one the original didn't have. The sidebar marks such a favorite and says why it won't run as written.

Only credentials, deliberately

The issue asked for the same value-redaction setting history has (#330). I've deliberately not extended it.

A favorite exists to be run again, and one whose values have been blanked isn't a saved query — it's a broken one. History can afford that trade because a history entry is a record; a favorite is a tool. If a value shouldn't be in a favorite, it shouldn't be in the favorite.

That's a judgement, not an oversight, so overrule it if you disagree: redactLiterals already exists and the store has a single scrub() to change.

Verification

8 new tests (5 store, 3 sidebar). Unit 2054, browser 297, 0 lint errors.

A favorite carrying `IDENTIFIED BY 's3cret'` was written to storage as
typed, walking past the keyring the same way history did before #587. A
favorite is kept deliberately and for longer than a history entry, so the
case is stronger here, not weaker (#339).

Credentials are stripped on the way in — on save and on edit, since an edit
can introduce one the original did not have. The sidebar marks such a
favorite and says why it will not run as written.

Only credentials. The issue asked for the same value-redaction setting
history has, and I have deliberately not extended it: a favorite exists to
be run again, and one whose values have been blanked is not a saved query,
it is a broken one. History can afford that trade because a history entry is
a record; a favorite is a tool. If a value should not be in a favorite, it
should not be in the favorite.

That is a judgement rather than an oversight, so it is worth overruling if
you disagree — the plumbing is one call away, `redactLiterals` already
exists, and the store has a single scrub() to change.

Closes #339

Co-Authored-By: Claude Opus 5 <[email protected]>
@EVWorth
EVWorth merged commit 9a722f6 into main Sep 10, 2026
12 checks passed
@EVWorth
EVWorth deleted the feat/favorites-redaction branch September 10, 2026 11:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[P1/security] Favorites persist raw SQL with user-supplied values — no scrubbing/redaction

1 participant