Skip to content

DOC Update X-Forwarded-Proto header documentation#889

Draft
emteknetnz wants to merge 1 commit intosilverstripe:5.4from
creative-commoners:pulls/5.4/update-proxy-header
Draft

DOC Update X-Forwarded-Proto header documentation#889
emteknetnz wants to merge 1 commit intosilverstripe:5.4from
creative-commoners:pulls/5.4/update-proxy-header

Conversation

@emteknetnz
Copy link
Member


```yml
SilverStripe\Control\HTTP:
vary: ""
Copy link
Member Author

@emteknetnz emteknetnz Mar 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vary: X-Forwarded-Protocol
```
> [!NOTE]
> Prior to Silverstripe CMS 5.4, the default `Vary` header was set to the non-standard
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we continue to target CMS 5.4, we'd need to put in the exact patch version this changes

sets the `X-Forwarded-Proto` header and the application is configured to trust it via
[`TrustedProxyMiddleware`](api:SilverStripe\Control\Middleware\TrustedProxyMiddleware).

You can also add additional headers to vary on. For example, if you use `Director::is_ajax()` on
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Slightly unrelated docs improvement

@emteknetnz emteknetnz force-pushed the pulls/5.4/update-proxy-header branch from f72e707 to 8d655d8 Compare March 3, 2026 00:15
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