Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2025-52875 Overview
CVE-2025-52875 is a DOM-based Cross-Site Scripting (XSS) vulnerability in JetBrains TeamCity prior to version 2025.03.3. The flaw resides in the Performance Monitor page, where user-controlled input is processed by client-side JavaScript without proper sanitization. An authenticated attacker can craft a malicious URL that, when opened by another TeamCity user, executes arbitrary script in the victim's browser session. The issue is tracked under [CWE-79] and affects the TeamCity continuous integration and deployment platform.
Critical Impact
An attacker with low privileges can execute arbitrary JavaScript in a victim's browser context, potentially stealing session data, hijacking CI/CD workflows, or pivoting to build artifacts.
Affected Products
- JetBrains TeamCity versions prior to 2025.03.3
- TeamCity Performance Monitor page component
- On-premises TeamCity deployments exposing the affected UI
Discovery Timeline
- 2025-06-23 - CVE-2025-52875 published to the National Vulnerability Database (NVD)
- 2026-06-17 - Last updated in NVD database
Technical Details for CVE-2025-52875
Vulnerability Analysis
The vulnerability is a DOM-based XSS flaw located in the Performance Monitor page of JetBrains TeamCity. In DOM-based XSS, the injection sink lives entirely in client-side code. The browser processes attacker-controlled input from a source such as the URL, document.location, or query parameters and writes it into the DOM without escaping. Exploitation requires user interaction, typically clicking a crafted link, and the attacker must hold a valid low-privilege TeamCity account. Because the scope is changed, the injected script can affect resources beyond the vulnerable component's boundary within the TeamCity web application.
Root Cause
The root cause is improper neutralization of input during web page generation on the client side [CWE-79]. The Performance Monitor page consumes a value that originates from the request context and passes it to a DOM sink such as innerHTML, document.write, or an equivalent JavaScript API without contextual output encoding. Any HTML or <script> markup embedded in the attacker-controlled parameter is parsed and executed by the victim's browser.
Attack Vector
Exploitation follows a standard reflected DOM XSS chain. The attacker authenticates to TeamCity with any valid account and crafts a URL targeting the Performance Monitor page with a malicious payload in a parameter processed by client-side code. The attacker delivers the link to another authenticated TeamCity user through chat, email, or a build description. When the victim opens the URL, the payload executes in the origin of the TeamCity server. The attacker can then read the victim's DOM, issue authenticated API calls, exfiltrate CSRF tokens, or manipulate build configurations available to that user.
No verified public exploit or proof of concept has been published for this vulnerability. See the JetBrains Security Fixes advisory for vendor details.
Detection Methods for CVE-2025-52875
Indicators of Compromise
- HTTP requests to Performance Monitor endpoints containing URL-encoded HTML tags, <script> fragments, or JavaScript event handlers such as onerror= and onload=.
- Reverse proxy or web server logs showing unusually long query strings or fragments (#) referencing the Performance Monitor page.
- Outbound browser connections from workstations to attacker-controlled domains immediately after a TeamCity session, indicating possible token exfiltration.
Detection Strategies
- Deploy a Content Security Policy (CSP) report-only header and monitor violation reports for inline script execution on TeamCity pages.
- Inspect TeamCity access.log for requests to Performance Monitor URLs with suspicious parameter values or encoded script keywords.
- Correlate authenticated TeamCity sessions with anomalous administrative API calls that follow a click on a shared link.
Monitoring Recommendations
- Forward TeamCity web server and application logs to a centralized SIEM for query-string analysis and retention.
- Alert on newly created or modified build configurations, users, or tokens that immediately follow a Performance Monitor page visit.
- Track browser telemetry from privileged TeamCity administrators for unexpected script execution or DOM modifications.
How to Mitigate CVE-2025-52875
Immediate Actions Required
- Upgrade JetBrains TeamCity to version 2025.03.3 or later on all servers.
- Audit TeamCity user accounts and revoke sessions and personal access tokens issued before the upgrade.
- Instruct TeamCity users to avoid clicking untrusted links that reference the TeamCity host, particularly links pointing at Performance Monitor URLs.
Patch Information
JetBrains resolved the DOM-based XSS in TeamCity 2025.03.3. The fix is listed on the JetBrains Security Fixes page. Administrators should follow the standard TeamCity upgrade procedure and validate that the server version reports 2025.03.3 or newer after restart.
Workarounds
- Restrict access to the TeamCity web interface using network segmentation, VPN, or IP allow-listing until the patch is applied.
- Enforce a strict Content Security Policy at a reverse proxy in front of TeamCity to block inline script execution and untrusted script origins.
- Limit assignment of low-privilege TeamCity accounts and disable self-registration to reduce the pool of potential attackers.
# Verify installed TeamCity version and confirm it is 2025.03.3 or later
curl -s -u <user>:<token> https://teamcity.example.com/app/rest/server | grep -oE 'version="[^"]+"'
# Example reverse proxy CSP header (nginx) to reduce DOM XSS impact
add_header Content-Security-Policy "default-src 'self'; script-src 'self'; object-src 'none'; base-uri 'self'; frame-ancestors 'self'" always;
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

