You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Unsubscribe only when the reader confirms, not when a link scanner opens the email link #445
The unsubscribe link in our emails applies the change on a plain GET. Mail link scanners, for example Microsoft Safe Links, open every link in a message. So a reader can be unsubscribed without ever clicking. RFC 8058 expects the change on POST; mail clients already use our separate one-click POST endpoint.
Severity: Low (not a security issue; lost notifications)
Area: email unsubscribe
Source: security review of 2026-10-06, review of email flows
Where
Rewrite: apps/webapp/next.config.js:205 sends /unsubscribe to ${restApi}/email/unsubscribe.
GET applies the change: apps/hocuspocus.server/src/api/email.ts (handler near :373, which calls apply_unsubscribe at :361).
The RFC 8058 POST handler already exists: apps/hocuspocus.server/src/api/email.ts:448-482.
Fix plan
GET /email/unsubscribe?token= verifies the token and renders a confirmation page with one "Unsubscribe" button. It changes nothing.
The button POSTs the token to the same path. The POST applies the change and renders the success page.
Keep the existing List-Unsubscribe-Post handler unchanged.
Page copy follows Simplified English and the email page style already used by the handler.
Acceptance criteria
Opening the link with GET changes no preference.
Pressing the button unsubscribes, as today.
One-click unsubscribe from the mail client still works.
An invalid or expired token still shows the current error page.
Verify
cd apps/hocuspocus.server && bun test with a new case for GET (no change) and POST (change), in the existing email test file if one exists.
Activity
fix(api): put push gateway status behind admin and confirm unsubscribe
docs(openapi): match the spec to today's admin, email, media and heal…
docs(hocuspocus): sync server docs with the 9 October fixes
docs: update the API and self-hosting guides for the 9 Oct backend fixes
docs(repo): record the 9 Oct security and email batch in the changelo…
fix(email-templates): give the unsubscribe button a hover state
HMarzban commentedon Oct 9, 2026
Fixed and live.
659029c36,f0aae97f5bbdaae66c(production run 37976785981, green).