HighGHSA-25gq-jvx2-vg9x

Silverstripe X-Forwarded-Host request hostname injection

Published 23 May 2024 · Updated 28 Nov 2024

Is your project on an affected silverstripe/framework?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Look after several Laravel or PHP apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Affected package

Affected
>=3.1.0 <3.1.13
Fixed in
3.1.13
Update to the fixed version for your release line, for example:composer require silverstripe/framework:^3.1.13

Details

A potential hostname injection vulnerability has been found which could allow attackers to alter url resolution.

If a request contains the X-Forwarded-Host HTTP header a website would then use its value in place of the actual HTTP hostname. In cases where caching is enabled, this could allow an attacker to potentially embed a remote url as the base_url for any site. This would then cause other visitors to the site to be redirected unknowingly.

This header is necessary for servers running behind a reverse proxy (such as nginx). Such servers are likely not vulnerable to this risk.

A fix has been merged into the default installer, although existing projects which do not run behind a reverse proxy should update their htaccess as below:

<IfModule mod_headers.c>
    # Remove X-Forwarded-Host header sent as a part of any request from the web
    RequestHeader unset X-Forwarded-Host
</IfModule>

Is GHSA-25gq-jvx2-vg9x in any of your client repos?

Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected silverstripe/framework, and gives you the command that fixes it.

More advisories for silverstripe/framework

  • MediumCVE-2026-54720Silverstripe Framework: Possible XSS attack through media embed · 27 Aug 2026
  • MediumGHSA-256q-hx8w-xcqxSilverstripe Framework user enumeration via timing attack on login and password reset forms · 10 Apr 2025
  • MediumCVE-2025-30148Silverstripe Framework has a XSS vulnerability in HTML editor · 10 Apr 2025
  • LowGHSA-74j9-xhqr-6qv3Reflected Cross Site Scripting (XSS) in error message · 23 Jan 2025
  • LowGHSA-mqf3-qpc3-g26qSilverstripe Framework has a Reflected Cross Site Scripting (XSS) in error message · 14 Jan 2025
  • MediumCVE-2024-53277Silverstripe Framework has a XSS in form messages · 14 Jan 2025
All 93 advisories for silverstripe/framework

References

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.