# GHSA-mqf5-275h-gf6r: Silverstripe framework is vulnerable to XSS in install.php

> An attacker can inject malicious scripts via unescaped parameters in the Silverstripe installation form, potentially compromising the site.

- **Severity:** Not scored
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** A user has to click or open something
- **Fix available:** Yes
- **Published:** 23 May 2024

## What is GHSA-mqf5-275h-gf6r?

GHSA-mqf5-275h-gf6r is a cross-site scripting vulnerability in silverstripe/framework, published on 23 May 2024. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

### Official description

During installation, certain parameters (admin_username and admin_password) are not escaped in the setup form.

This issue is resolved in 3.1.14 stable, although existing users are advised to remove this file prior to deploying to a production server.

## Which versions are affected by GHSA-mqf5-275h-gf6r?

2 open source packages ship an affected version, including silverstripe/framework.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `silverstripe/framework` | Packagist | From 3.1.0 | 3.1.14 |
| `silverstripe/framework` | Packagist | From 3.1.0 | 3.1.14 |

## How do I fix GHSA-mqf5-275h-gf6r?

Upgrade silverstripe/framework to 3.1.14 or later.

## Is GHSA-mqf5-275h-gf6r being exploited?

There is no known exploitation of GHSA-mqf5-275h-gf6r in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for GHSA-mqf5-275h-gf6r and fix it if it is affected.

What it is: GHSA-mqf5-275h-gf6r is a cross-site scripting vulnerability in silverstripe/framework, published on 23 May 2024. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Exploitation: There is no known exploitation of GHSA-mqf5-275h-gf6r in the wild and no public exploit code.

Affected packages and fixed versions:
- silverstripe/framework (Packagist): affected from 3.1.0; fixed in 3.1.14
- silverstripe/framework (Packagist): affected from 3.1.0; fixed in 3.1.14

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/GHSA-mqf5-275h-gf6r/ (Markdown: https://insights.sbomify.com/GHSA-mqf5-275h-gf6r/index.md)
```

## Sources

- OSV: https://osv.dev/vulnerability/GHSA-mqf5-275h-gf6r

---
From sbomify Insights: https://insights.sbomify.com/GHSA-mqf5-275h-gf6r/
Summaries are generated and may contain mistakes; the official description above is the record.
