CVE-2024-4207 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in GitLab

Medium 4.4 Published Updated

Attackers can execute arbitrary scripts in victim browsers by tricking them into viewing malicious XML files in raw mode, potentially leading to account takeover.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2024-4207?

CVE-2024-4207 is a medium-severity cross-site scripting vulnerability in Gitlab Gitlab, published on 8 Aug 2024. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.

Official description

A cross-site scripting issue has been discovered in GitLab affecting all versions starting from 5.1 prior 17.0.6, starting from 17.1 prior to 17.1.4, and starting from 17.2 prior to 17.2.2. When viewing an XML file in a repository in raw mode, it can be made to render as HTML if viewed under specific circumstances.

Weakness: CWE-79

Which versions are affected by CVE-2024-4207?

1 open source package ship an affected version, including gitlab. It affects 1 product.

PackageAffectedFixed in
gitlab BitnamiFrom 5.1.017.0.6, 17.1.4, 17.2.2

Products include Gitlab Gitlab.

How do I fix CVE-2024-4207?

Upgrade gitlab to a fixed version for your release line: 17.0.6, 17.1.4 or 17.2.2.

Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.

Is CVE-2024-4207 being exploited?

There is no known exploitation of CVE-2024-4207 in the wild and no public exploit code.

All Gitlab Gitlab vulnerabilities

Sources

Also known as BIT-gitlab-2024-4207, GHSA-f8f8-vpg5-qg2x, UBUNTU-CVE-2024-4207.

Is CVE-2024-4207 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free