Introduction
A critical flaw in JetBrains TeamCity allowed a user with low privileges to turn harmless-looking Unicode characters in Perforce settings into real command-line syntax, ending in remote code execution on the build server. JetBrains rated the issue Critical with a CVSS 3.1 score of 9.9 and a changed scope, and shipped fixes in TeamCity 2026.1.3 and 2025.11.7 in July 2026.
TeamCity is the JetBrains continuous integration server used to automate software builds and tests, offered both as an On Premises installation and as TeamCity Cloud. JetBrains states that TeamCity is used by more than 30,000 DevOps teams, and the company reports 12.5M+ recurring active users and 88 Fortune Global Top 100 customers across its products. Because a CI server sits between source control and build infrastructure, flaws in how it talks to version control systems such as Perforce deserve close attention.
Technical Information
Root cause: Windows best-fit mapping
The CVE description states that remote code execution was possible via best fit character mapping in Perforce settings, and assigns CWE-1289: Improper Validation of Unsafe Equivalence in Input.
Best-fit mapping is a Windows behavior. When a Unicode string is converted to the system's legacy ANSI code page, characters that have no exact equivalent are not rejected. Instead, Windows substitutes a similar-looking ASCII character. Examples relevant to command-line construction:
- Fullwidth quotation mark (U+FF02) can become a plain
" - Fullwidth hyphen-minus (U+FF0D) can become the ASCII hyphen-minus character used as an option prefix
- Yen sign (
¥) can become\in some code pages
Where TeamCity went wrong
The problem is a classic mismatch between validation and processing. TeamCity's input validator for Perforce settings saw the fullwidth or otherwise unusual Unicode characters, found nothing dangerous, and accepted them. Only later, when TeamCity assembled the Perforce (p4) process command line from the VCS root settings and Windows converted that command line to ANSI, did those characters turn into quotes, option dashes, or path separators.
This is exactly the pattern MITRE describes for CWE-1289: input that appears safe at validation time becomes dangerous when a lower layer processes it. The validator and the process being launched did not see the same bytes.
Reading the CVSS vector
The CNA vector is CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H:
- AV:N / AC:L: reachable over the network with low attack complexity
- PR:L: requires low privileges, consistent with a user who can edit Perforce settings
- UI:N: no user interaction required
- S:C: changed scope, meaning impact extends beyond the vulnerable component
- C:H / I:H / A:H: high impact to confidentiality, integrity, and availability
NVD displays this CNA score and has not yet provided its own assessment.
Attack flow
Based on the vendor description and the vulnerability class, the attack proceeds roughly as follows:
- The attacker holds a TeamCity account with enough permission to edit Perforce settings for a VCS root. The exact permission is not specified publicly. The vector only states low privileges.
- The attacker enters a value containing best-fit candidates, such as fullwidth quotation marks or fullwidth hyphen-minus characters, into a Perforce setting that ends up on the
p4command line. - TeamCity's validation sees characters outside the ASCII range rather than quotes or option prefixes, and accepts the value.
- TeamCity builds the
p4command line from the VCS root settings. On Windows, the conversion to the ANSI code page maps the lookalike characters to", the ASCII option dash, or\. - The resulting command line now contains attacker-controlled structure, such as broken-out quoting or injected options, which leads to code execution on the TeamCity server.
TeamCity is closed source and the internal ticket (TW-101693) is not publicly viewable, so the specific vulnerable field, the exact injected arguments, and any additional prerequisites have not been published. The official CVE and NVD records contain no proof of concept or reproduction instructions, and they do not report active exploitation or attribute activity to any threat actor.
Relationship to earlier Perforce fixes
The same July releases fix a sibling Perforce issue, CVE-2026-132232 (TW-101817), an argument injection (CWE-88) in Perforce settings. An earlier Perforce connection settings RCE, CVE-2026-49373 (TW-99632, CWE-88), was fixed in 2026.1. It is plausible, though JetBrains has not confirmed it, that the best-fit issue was a way around the earlier argument injection hardening: a filter looking for literal quotes and dashes would not catch their fullwidth equivalents. That would explain why the July builds harden the Perforce command-line path at two separate layers.
Patch Information
What JetBrains shipped. JetBrains fixed CVE-2026-132231 in TeamCity On Premises 2026.1.3 (build 222742) and 2025.11.7 (build 208264), both released on 27 July 2026. The Fixed Security Issues bulletin lists the bug as "Remote code execution was possible via best fit character mapping in Perforce settings", tracked internally as TW-101693, rated Critical, classified as CWE-1289, and resolved in 2026.1.3,2025.11.7. The CNA data in NVD matches: versions 2026.1 < 2026.1.3 and 0 < 2025.11.7 are affected.
How the fix is delivered. There is no public commit, diff, or standalone hotfix plugin. The fix ships only inside full product builds. Neither release note names this CVE. The 2026.1.3 notes state that 30 security problems were fixed, the 2025.11.7 notes state 22, and both point readers to the Security Bulletin. The JetBrains release blog describes both updates as primarily focused on security and strongly recommends upgrading. Update options:
- The automatic update mechanism in TeamCity
- Installers or archives from jetbrains.com
- The updated Docker image
Within 2026.1.x the data format does not change, so you can move between patch releases without a backup and restore. Later builds are cumulative and also include the fix: 2026.1.4 and later, 2025.11.8, and the 2026.2 line.
Likely shape of the fix (our inference, not confirmed by JetBrains). Since no code is public, the following reflects how this vulnerability class is normally fixed rather than the actual change. A correct fix typically does one or more of the following:
- Normalizes or rejects characters outside the ASCII range in fields that reach the
p4command line before validation runs, so the check sees the same characters the process will receive. - Avoids the lossy ANSI conversion entirely, or passes values through environment variables or config files instead of
argv. - Strictly allowlists characters in values such as port, client, stream, and charset.
Intermediate builds are not enough. Only 2026.1.3, 2025.11.7, or later builds contain the complete set of Perforce fixes. Patching to an intermediate build such as 2026.1.2 or 2025.11.6 leaves this issue open.
General hardening. The reviewed sources provide no CVE-specific workaround. JetBrains' general TeamCity security notes recommend deploying the server in a trusted environment where malicious users cannot access it, limiting access to the machine running the server, and enabling and regularly reviewing access logs.
Affected Systems and Versions
- TeamCity 2026.1 line: versions from 2026.1 up to, but not including, 2026.1.3 (CNA range
2026.1 < 2026.1.3) - Earlier lines: all versions before 2025.11.7 (CNA range
0 < 2025.11.7) - Platform: the CVE record lists Windows, which aligns with best-fit mapping being a Windows code page conversion behavior
- Vulnerable configuration: Perforce VCS root settings, reachable by a user with low privileges who can edit those settings
- Fixed builds: 2026.1.3 (build 222742), 2025.11.7 (build 208264), and later cumulative builds (2026.1.4 and later, 2025.11.8, the 2026.2 line)
The CVE record does not state whether TeamCity Cloud is affected or whether specific Perforce configurations are required. The fix was shipped in TeamCity On Premises builds. Confirm deployment-specific applicability through JetBrains security information if it affects your upgrade planning.
Vendor Security History
The Perforce integration in TeamCity has received several security fixes in 2026:
- CVE-2026-49373 (TW-99632, CWE-88): RCE via Perforce connection settings, fixed in 2026.1
- CVE-2026-132232 (TW-101817, CWE-88): argument injection in Perforce settings, fixed in 2026.1.3 and 2025.11.7 alongside this CVE
- CVE-2026-63077: a separate critical issue affecting TeamCity On Premises, for which JetBrains published a dedicated blog post recommending an update to 2025.11.7 or 2026.1.3
The July releases were large security updates overall, with 30 security problems fixed in 2026.1.3 and 22 in 2025.11.7. JetBrains states that TeamCity is SOC 2 Type II compliant, that it conducts regular audits including penetration testing by Cure53, that it uses third-party security scanners, and that critical issues it discovers are addressed in the next bug-fix release. These are vendor statements and do not independently establish security performance.
References
- NVD entry for CVE-2026-132231
- CVE Record: CVE-2026-132231
- JetBrains Fixed Security Issues
- JetBrains Fixed Security Issues, filtered for TeamCity
- TeamCity 2026.1.3 and 2025.11.7 Are Now Available, The JetBrains Blog
- TeamCity 2026.1.3 Release Notes
- TeamCity 2025.11.7 Release Notes (2025.11 documentation)
- TeamCity 2025.11.7 Release Notes
- Critical Security Issue Affecting TeamCity On Premises (CVE-2026-63077), The JetBrains Blog
- TeamCity Security Notes
- TeamCity Security Features
- CWE-1289: Improper Validation of Unsafe Equivalence in Input
- TeamCity product site
- JetBrains company page
- CISA Known Exploited Vulnerabilities Catalog



