Skip to content

fix: feedback links answered 403 in browsers - #39

Merged
StanBarrows merged 1 commit into
productionfrom
main
Oct 22, 2026
Merged

StanBarrows merged 1 commit into
productionfrom
main

Conversation

@StanBarrows

Copy link
Copy Markdown
Contributor

Signed feedback links (thank you screen, feedback:link) answered an empty 403 when opened in a browser on feedback.codebar.ch, while the same URL without browser headers returned 200.

Cause: BlockBrowserNavigation is prepended and runs before the trusted proxies are applied. Behind Laravel Cloud's TLS terminating proxy it saw http://…, so hasValidSignature() failed for the https:// link.

Fix: the guard only lets navigations to /v1/feedback/* carrying a signature through; the route's signed middleware (after the proxies) checks the signature on the correct URL. Invalid or expired links still get the empty 403, every other navigation is still blocked.

Tests: new Pest test with TrustProxies and X-Forwarded-Proto: https reproduces the production 403 without the fix and passes with it; 336 passed, Larastan/Pint clean, full stack E2E green.

🤖 Generated with Claude Code

BlockBrowserNavigation runs before the trusted proxies are applied, so it
checked the signature against http:// while the link is https://. It now
only lets navigations to /v1/feedback/* with a signature through; the
route's signed middleware checks the signature on the correct URL.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@StanBarrows
StanBarrows merged commit e36cf98 into production Oct 22, 2026
13 checks passed
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