-
Notifications
You must be signed in to change notification settings - Fork 25
Description
When having set the TRUSTED_PROXIES
and TRUSTED_HOSTS
, generated URLs will use the URL provided by the X-FORWARDED-HOST
header when fetching a page through the API (e.g. in a `text_editor' content type this will replace the absolute URLs with the provided URL in the header).
A page that has been configured as an internal link will generate a redirect when fetching the page through API. This is all correct behaviour.
The problem is that the generated redirect URL is then also using the forwarded host header. I think this should be the Sulu URL and not the provided URL by the forwarded host header.
Consequence is that the frontend follows redirects and fetches the wrong (redirected) URL, thus no JSON content from Sulu.
Please let me know if more info or examples are needed.