Saltar al contenido
Fali Fuentes

JetBrains TeamCity: critical build agent bypass (CVE-2026-136858) — patches and plugin

Leer este artículo en español

On December 2, JetBrains disclosed CVE-2026-136858, a critical authorization bypass (CVSS 9.1) in the build agent registration of TeamCity On-Premises that allows anyone who can reach the server via HTTP(S) to impersonate an authorized agent, intercept builds, access secrets — cloud credentials, signing keys, deployment tokens — and forge artifacts that downstream builds then consume. It affects all On-Premises versions; TeamCity Cloud is already mitigated. It matters today because watchTowr detected exploitation attempts in honeypots the next day and Ireland’s NCSC urges patching with maximum priority, while TeamCity’s history in CISA’s KEV catalog (four previous CVEs with confirmed ransomware) raises operational urgency.

The bypass allows agent impersonation without credentials and theft of build secrets

The vulnerability (CWE-639) resides in the agent registration flow: an unauthenticated attacker (PR:N) can pose as an existing agent and receive the credentials the server passes for the build. This exposes sensitive secrets and allows injection of malicious artifacts that propagate the attack to the supply chain. JetBrains rates it CVSS 3.1 9.1 (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N) and confirms it requires no user interaction or prior credentials, per the JetBrains advisory.

Exploitation attempts observed within 24 hours and Ireland NCSC advisories

On December 2, JetBrains stated it had no evidence of active exploitation at that time, but watchTowr reported activity in its Attacker Eye honeypot network on December 3. On December 4, Ireland’s NCSC issued an advisory recommending installing updates “with maximum priority,” and BleepingComputer echoed it. CISA KEV (version 2026.12.04) does not yet include it, but four previous TeamCity vulnerabilities (CVE-2023-42793, CVE-2024-27198, CVE-2024-27199, CVE-2026-63077) are already in KEV with ransomware use marked as Known. That combination of CVSS 9.1, exposed surface, and early observation of attempts justifies immediate patching, per the Rescana analysis.

Upgrade to 2026.1.7, 2026.2.3, or 2026.3; plugin for 2021.2+ without restart

The JetBrains-recommended path is to upgrade to the fixed versions: 2026.1.7, 2026.2.3, or 2026.3 (via download or auto-update). If you can’t upgrade right now, there is a security patch plugin for TeamCity 2021.2 onward that mitigates only this CVE and installs without a restart. In 2024.03–2026.2.1, review and apply it in Administration → Updates → Available security updates; in 2026.2.2+, configure Install automatically to receive future patches automatically. Versions prior to 2021.2 have no plugin: the only option is to upgrade to a fixed release. As an additional measure, restrict /app/agents/* in a reverse proxy or WAF to legitimate agent IPs (including cloud agent NAT), but this does not replace patching.

Search logs before patching and rotate secrets at the original issuer

Before applying a patch or upgrade, examine teamcity-server.log searching for the string of the existing agent, but different authorization token "<token>". A non-empty token indicates a takeover attempt; an empty token ("") is normal behavior. Correlate hostname, IP, builds, and affected artifacts. If you confirm or cannot rule out compromise, rotate the exposed secrets at the original issuer (cloud provider, registry, HSM, etc.), not just in TeamCity, and treat artifacts from suspicious builds as untrusted: track their deployment and consumption, and rebuild from a trusted agent. Inventory all your TeamCity On-Premises servers (including test and legacy environments) and verify version and installed plugin; the version number does not reveal whether the plugin is applied. Also assess suppliers that use TeamCity On-Premises to build software you consume: a compromised agent in their chain can leak secrets and inject artifacts into yours.

SYSTEM_EXPERT
Rafael Fuentes – BIO

I am a seasoned cybersecurity expert with over twenty years of experience leading strategic projects in the industry. Throughout my career, I have specialized in comprehensive cybersecurity risk management, advanced data protection, and effective incident response. I hold a certification in Industrial Cybersecurity, which has provided me with deep expertise in compliance with critical cybersecurity regulations and standards. My experience includes the implementation of robust security policies tailored to the specific needs of each organization, ensuring a secure and resilient digital environment.

Share
Scroll al inicio