Skip to content

Set the HTTPS server variable for HTTPS requests - #2253

Merged
mnapoli merged 1 commit into
masterfrom
set-https-server-variable
Nov 11, 2026
Merged

mnapoli merged 1 commit into
masterfrom
set-https-server-variable

Conversation

@mnapoli

@mnapoli mnapoli commented Nov 10, 2026

Copy link
Copy Markdown
Member

Bref did not set $_SERVER['HTTPS'], so frameworks only detected HTTPS when they trusted the proxy that sets X-Forwarded-Proto. Without that configuration, Laravel and Symfony generate http:// URLs and drop secure cookies.

API Gateway, Function URLs and load balancers set X-Forwarded-Proto themselves and replace the value sent by the client, so Bref now sets HTTPS=on from it, in the PHP-FPM and function runtimes.

Frameworks detected HTTPS only when they trusted the proxy that sets X-Forwarded-Proto. API Gateway, Function URLs and load balancers set it, and replace the value sent by the client.
@mnapoli
mnapoli merged commit e7fd5ab into master Nov 11, 2026
8 checks passed
@mnapoli
mnapoli deleted the set-https-server-variable branch November 11, 2026 11:42
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