[MEDIUM] Paste password accepted via GET ?password= query string leaks it into logs and history #141

Closed
opened 2026-09-10 03:48:56 +00:00 by fen · 1 comment
Collaborator

handleGetPaste accepts the password via ?password= (and X-Paste-Password header). Query strings are captured by Traefik access logs and browser history. The unlock limiter (#81) prevents brute force, but the secret itself is exposed to anyone with log access. Consider dropping the query-param path or documenting it as unsafe.

Repro

1. Create unlisted+password paste.
2. curl -sk --resolve palette-dev.archfox.org:443:10.0.1.47 "https://palette-dev.archfox.org/api/pastes/$ID?password=pw" -> 200 with content
Expected: password only via POST /unlock body or X-Paste-Password header.
Actual: 200 via URL query.

Found during exploratory security/bug pass on palette-dev (2026-09-09). Reporting only, no fix attached.

handleGetPaste accepts the password via ?password= (and X-Paste-Password header). Query strings are captured by Traefik access logs and browser history. The unlock limiter (#81) prevents brute force, but the secret itself is exposed to anyone with log access. Consider dropping the query-param path or documenting it as unsafe. ### Repro ``` 1. Create unlisted+password paste. 2. curl -sk --resolve palette-dev.archfox.org:443:10.0.1.47 "https://palette-dev.archfox.org/api/pastes/$ID?password=pw" -> 200 with content Expected: password only via POST /unlock body or X-Paste-Password header. Actual: 200 via URL query. ``` Found during exploratory security/bug pass on palette-dev (2026-09-09). Reporting only, no fix attached.
fen added spent time 5 seconds 2026-09-10 03:49:08 +00:00
fen added the Medium label 2026-09-10 03:49:49 +00:00
fen added spent time 30 seconds 2026-09-10 04:18:37 +00:00
fen added In Progress and removed Medium labels 2026-09-10 04:18:37 +00:00
fen closed this issue 2026-09-10 04:23:27 +00:00
Author
Collaborator

Fixed in PR #150: ?password= is no longer accepted on paste/can reads (repro now returns 401); the X-Paste-Password header and POST unlock form still work, re-verified 200. Log: 30m.

Fixed in PR #150: ?password= is no longer accepted on paste/can reads (repro now returns 401); the X-Paste-Password header and POST unlock form still work, re-verified 200. Log: 30m.
fen added QA and removed In Progress labels 2026-09-10 04:23:28 +00:00
fen added spent time 34 minutes 2026-09-10 13:57:36 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Total Time Spent: 35 minutes
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: poslop/palette#141