JetBrains has fixed a critical authentication bypass in TeamCity On-Premises that lets anyone who can reach the server over HTTP(S) pose as one of its build agents, with no TeamCity account and no password. Tracked as CVE-2026-136858 and scored 9.1 under CVSS 3.1, it affects every on-premises version.

    The company disclosed it on December 2 in a JetBrains security advisory, eight days after security researcher Jiawei Guo reported it privately on November 24.

    Why a fake build agent is so dangerous

    CI servers used to be the forgotten box in the corner that ran the nightly build and emailed someone when the tests broke, but these days the agents they direct hold deploy keys, tokens and signing credentials for nearly everything a team ships. That is what makes this one sting.

    JetBrains hasn’t shared the root cause. Its list of fixed security issues describes the bug as an authentication bypass during agent registration and files it under CWE-639, authorization bypass through a user-controlled key.

    Once an attacker displaces a legitimate agent, the server hands over the builds assigned to it. The attacker can then read the credentials and other secrets passed to that agent, return falsified build results and publish tampered artifacts.

    The artifacts are the part worth pausing on. Any downstream build that consumes a poisoned one could end up running code the attacker supplied, so a single exposed CI server becomes a supply chain problem.

    Attacks began about a day after disclosure

    JetBrains said it knew of no active exploitation when it published the advisory. It also applied fixes to TeamCity Cloud and found no evidence that any Cloud environment had been exploited through the flaw.

    That quiet didn’t last. watchTowr reported that attackers had reverse-engineered the flaw and hit its honeypot network roughly a day after disclosure, taking over an agent in as few as two HTTP requests.

    The only real hurdle is guessing the ID of an active agent. IDs start at 1 and count upward, so the attackers watchTowr captured simply started low and worked through the numbers.

    Fixed versions and the patch plugin

    The fix ships in TeamCity 2026.1.7, 2026.2.3 and 2026.3. TeamCity Cloud customers don’t need to do anything.

    For servers that can’t be restarted right away, JetBrains has a security patch plugin for TeamCity 2021.2 and later. It closes only this vulnerability, so it buys time rather than replacing a full upgrade.

    A workaround at the proxy

    Admins who can do neither yet can use a reverse proxy or other path-aware access control to accept requests to /app/agents and its subpaths only from IP addresses where real build agents are expected.

    That allowlist has to include the outbound addresses cloud agents use and any NAT gateways they connect through. Miss one, and you lock out your own fleet.

    Checking whether someone got in first

    Patching closes the door but says nothing about who walked through it beforehand. JetBrains points admins to teamcity-server.log, where entries about an existing agent presenting a different authorization token are the ones to look for.

    An empty token in those entries is normal. A non-empty one may mean a takeover attempt, and the secrets that agent’s builds handled are the first things to rotate.

    The second critical TeamCity flaw since July

    This is the second critical, unauthenticated TeamCity bug in a little over four months. CVE-2026-63077, a code execution flaw rated 9.8 and patched in late July, was added to CISA’s Known Exploited Vulnerabilities catalog about a week after disclosure.

    The window between a patch and the first attacks keeps shrinking, as with the WP Rocket plugin flaw exploited days after its fix. Developer tooling keeps drawing attackers as well, as the fake Claude Code skills that spread malware across GitHub repos showed.

    Anyone running TeamCity on their own hardware should update now, then go read the logs.

    Paul Mills is a web developer and writer at webcode.tools. He covers the site's generators and online utilities, with a focus on making everyday HTML, CSS, and JavaScript tasks quicker for people who would rather build something than look up syntax for the tenth time.