Senders API returns SMTP passwords and SES secret keys to every project member #30

Closed
opened 2026-10-15 01:18:27 -04:00 by vmanne-poc · 0 comments
Owner

Bug (security). GET /projects/:id/senders returns each sender's full config object, which includes the SMTP pass and the SES secretAccessKey. Every project member can read them, and so can anything that has a member's token.

Fix

  • Never return secrets.
    • The API returns config without pass and secretAccessKey.
    • It adds hasPassword / hasSecret flags, so the UI can show whether a secret is set.
    • This applies to every route that returns a sender.
  • Secrets stay write-only: they can be set or replaced (in Phase 10, when senders become editable) but never read back.
  • Separate follow-up: encrypt secrets at rest with a server key (POSTAK_SECRET_KEY).

Done when

  • An e2e test shows no secret appears in any sender response.
**Bug (security).** `GET /projects/:id/senders` returns each sender's full `config` object, which includes the SMTP `pass` and the SES `secretAccessKey`. Every project member can read them, and so can anything that has a member's token. **Fix** - Never return secrets. - The API returns `config` without `pass` and `secretAccessKey`. - It adds `hasPassword` / `hasSecret` flags, so the UI can show whether a secret is set. - This applies to every route that returns a sender. - Secrets stay write-only: they can be set or replaced (in Phase 10, when senders become editable) but never read back. - Separate follow-up: encrypt secrets at rest with a server key (`POSTAK_SECRET_KEY`). **Done when** - An e2e test shows no secret appears in any sender response.
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
vmanne-poc/Postak#30
No description provided.