The Morning Patch Wire

CYBER SECURITY NEWS REPORT

EXPLAINER · THURSDAY, DECEMBER 3, 2026

TeamCity CVE-2026-136858: patch, then check one log line for a build agent takeover

JetBrains fixed a flaw in every TeamCity On-Premises version that lets anyone who can reach the server pose as a real build agent, with no login. That can expose build secrets and let an attacker swap build results. JetBrains also gave a log check, and this page turns it into steps.

This explains reporting by JetBrains: Critical Security Issue Affecting TeamCity On-Premises (CVE-2026-136858).
Read the original first: https://blog.jetbrains.com/teamcity/2026/12/cve-2026-136858/

In one minute

What broke

A build agent is the machine that runs your builds. The TeamCity server hands it jobs, plus the passwords and keys those jobs need.

JetBrains says an attacker who can reach the server over HTTP(S) could pose as an existing, approved agent. The attacker needs no TeamCity account. The real agent can be pushed aside, and its builds go to the attacker.

From there, JetBrains lists three harms: the attacker sees secrets passed to the agent, can fake build results, and can publish tampered artifacts. Later builds that use those artifacts could run the attacker's code.

JetBrains did not publish how the takeover works. The Hacker News reports a CVSS score of 9.1; the JetBrains post we read does not give a score.

Patch it

Check whether someone tried

JetBrains says to search teamcity-server.log for this text: of the existing agent, but different authorization token. Entries with an empty token are normal. A non-empty token may be a takeover attempt.

These are plain commands. We did not run them against a real TeamCity server. Run them in your TeamCity logs folder.

# All entries with the phrase JetBrains names
grep -n 'of the existing agent, but different authorization token' teamcity-server.log*

# Drop the normal ones with an empty token
grep -n 'of the existing agent, but different authorization token' teamcity-server.log* | grep -v 'token ""'

If you get a hit, JetBrains says to use its time to look at that agent's connection history and the builds it got. Check that the host name and IP address are the ones you expect. Then compare build logs, results and artifacts.

If you think it worked: keep the logs, patch, rotate every credential passed to those builds, and treat their artifacts as untrusted until checked. Find where those artifacts were used or deployed.

Fence off the agent door

JetBrains also suggests a network rule. Let requests to /app/agents and the paths under it come only from the IP addresses your agents really use. Include cloud agents' outbound addresses and any NAT gateways.

An example for nginx in front of TeamCity. This is our sketch, not from JetBrains, and not tested:

location /app/agents {
    allow 10.20.0.0/16;    # your agents' addresses
    allow 203.0.113.10;    # a cloud agent NAT gateway
    deny  all;
    proxy_pass http://teamcity_upstream;
}

JetBrains's wider advice: keep TeamCity on trusted networks, use a VPN for outside users and agents, and run the server and agents on different hosts.

Who is affected

CaseStatus
TeamCity On-Premises, all versions before the fixAffected.
2026.1.7, 2026.2.3, 2026.3Fixed.
2021.2 and later with the patch pluginFixed for this bug only.
TeamCity CloudFixed by JetBrains. No action.

What to do

What is still unknown

Sources

Today's full edition: Cyber Security News Report · every headline, every morning.