Add panic recovery and HTTP security headers #11

Closed
opened 2026-09-04 23:26:08 +02:00 by arne · 0 comments
Owner

Protect the HTTP boundary with recovery and baseline browser security middleware.

Acceptance criteria:

  • Panics in downstream handlers are recovered, logged with request context, and returned as a generic 500 response without leaking panic details.
  • Responses include documented baseline headers for content-type sniffing, framing, referrer policy, and other headers appropriate to Fjomp’s same-origin UI.
  • Middleware ordering preserves request IDs and structured logging for recovered requests.
  • Tests cover panic recovery, non-panicking requests, and the security headers on representative success and error responses.
  • make check passes.

Dependencies:

Protect the HTTP boundary with recovery and baseline browser security middleware. Acceptance criteria: - Panics in downstream handlers are recovered, logged with request context, and returned as a generic 500 response without leaking panic details. - Responses include documented baseline headers for content-type sniffing, framing, referrer policy, and other headers appropriate to Fjomp’s same-origin UI. - Middleware ordering preserves request IDs and structured logging for recovered requests. - Tests cover panic recovery, non-panicking requests, and the security headers on representative success and error responses. - `make check` passes. Dependencies: - Depends on #9 and #10.
arne closed this issue 2026-09-05 08:26:46 +02:00
Sign in to join this conversation.
No labels
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
arne/fjomp#11
No description provided.