← Home / Nathan's Short News

Critical JetBrains TeamCity Flaw Exploited to Hijack Build Agents

According to BleepingComputer, attackers are actively exploiting a critical authentication bypass vulnerability in JetBrains TeamCity On-Premises to hijack build agents. Security teams using self-hosted TeamCity installations must patch immediately or restrict agent endpoints to protect their software supply chains.

Background

JetBrains TeamCity On-Premises is a self-hosted platform used by software developers to automate code compilation, testing, and application deployment. Within this ecosystem, a build agent refers to the worker software executing tasks assigned by the central TeamCity server. BleepingComputer reports that build infrastructure remains a target for threat actors, noting that in September 2026, the US Cybersecurity and Infrastructure Security Agency (CISA) warned federal agencies about ransomware operators targeting another TeamCity On-Premises flaw, CVE-2026-63077, to execute arbitrary operating system commands.

What happened

According to BleepingComputer, cybersecurity researchers at offensive security company watchTowr observed in-the-wild exploitation attempts targeting a newly disclosed critical vulnerability, tracked as CVE-2026-136858, just one day after its public disclosure. The flaw is an authentication bypass issue that enables an attacker to impersonate a legitimate worker software that the TeamCity server already trusts.

To execute the attack, threat actors must guess a build agent identification (ID) number. However, researchers noted that guessing IDs is not a real obstacle because these numbers typically start at “1” and are relatively easy to predict. Once an attacker successfully impersonates a build agent, the TeamCity server begins assigning software build jobs directly to the unauthorized entity.

JetBrains issued a security bulletin on 2 December strongly recommending that all users update their software. While JetBrains stated in its bulletin that it had not directly observed active exploitation, watchTowr confirmed detecting active takeover attempts across its client base.

Who is affected

According to BleepingComputer, the vulnerability affects all versions of JetBrains TeamCity On-Premises prior to versions 2026.1.7, 2026.2.3, and 2026.3. Organisations using TeamCity Cloud are unaffected because the vendor has already applied the fix to the cloud service, requiring no action from cloud customers.

Why it matters

According to BleepingComputer, hijacking a build agent gives an attacker dangerous control over an organisation’s software pipeline. By receiving jobs intended for legitimate build agents, malicious actors could expose sensitive credentials passed into those build tasks. Furthermore, attackers could report false build results or return modified output files designed to execute attacker-supplied code when used in downstream software builds.

For IT leaders, security teams, and business owners, this vulnerability represents a serious supply chain security threat. If malicious output files are integrated into production releases or client deployments, business continuity, intellectual property, and downstream customer environments could be compromised.

What to do now

  1. Upgrade JetBrains TeamCity On-Premises installations immediately to version 2026.1.7, 2026.2.3, or 2026.3.
  2. Install JetBrains’ security patch plugin on version 2021.2 or later if an immediate server restart and full upgrade are not currently possible.
  3. Restrict network access to ‘/app/agents’ and its subpaths so that only expected source IP addresses of legitimate build agents can connect.
  4. Inspect ‘teamcity-server.log’ files for entries containing ‘of the existing agent, but different authorization token .' to identify potential takeover attempts.
  5. Review the connection history, source IP, and build timeline surrounding any non-empty authorization tokens discovered during log analysis.
  6. Preserve logs and build outputs, rotate all exposed credentials, and treat compiled build artifacts as untrusted until verified if compromise is suspected.

Key takeaways

  • Attackers began exploiting CVE-2026-136858 in the wild just one day after its public disclosure.
  • Hijacked build agents allow attackers to steal build credentials and inject malicious code into output files.
  • TeamCity On-Premises users must apply patches immediately or restrict agent IP paths to secure their pipelines.

This is a summary of reporting by BleepingComputer. For full details, read the original: Critical JetBrains TeamCity flaw exploited to hijack build agents.