Skip to content

fix(security): stop logging the package link (it contains the UPN key)#71

Open
Androz2091 wants to merge 1 commit intomainfrom
fix/redact-upn-from-logs
Open

fix(security): stop logging the package link (it contains the UPN key)#71
Androz2091 wants to merge 1 commit intomainfrom
fix/redact-upn-from-logs

Conversation

@Androz2091
Copy link
Copy Markdown
Member

The link printed at the start of process_package is https://click.discord.com/ls/click?upn=<UPN_KEY>. The UPN is the AES key for the encrypted blob, so it was sitting in CloudWatch in plaintext for 30 days, contradicting the README's claim that the key never reaches the server.

Just drop link from the print. package_id alone is enough to correlate log lines.

The package link ends with ?upn=<UPN_KEY>, where UPN is the AES key the
worker uses to encrypt that user's data. Logging the link puts the
decryption key in CloudWatch for the duration of the log group's
retention window (30 days), which contradicts the README's stated
security model ('encryption key must always remain on the client side,
must never be stored on the server side').

Drop the link from the print; package_id alone is enough to correlate
log lines.
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.

1 participant