Categories
CVE-2026-104252 critical CVSS 9.8

Cross-Site Scripting (XSS) in vitess.io/vitess (CVE-2026-104252)

Summary

Cross-site scripting in vitess.io/vitess (CVE-2026-104252). Successful exploitation can lead to full system takeover. Exploitable via twopczHandler. Mitigation: upgrade to 20.0.4 or later.

Original description

The description as published by the source.

From: xylove21
To: security@vitess.io
Subject: [Security Report] Vitess vttablet /twopcz reflected XSS
Date: Tue, 24 Jun 2026 14:30:00 +0800

Summary

The twopczHandler in
go/vt/vttablet/tabletserver/twopcz.go (line 185) reflects the Action
and dtid form values directly into the HTML response body via
fmt.Fprintln(w, msg) — without HTML escaping. The response is served
as text/html; charset=utf-8, and Vitess's default acl policy is
allow-all, so the endpoint is reachable by anyone who can hit the
vttablet's HTTP port (default 15999, multiplexed with gRPC and MySQL
wire-protocol ports).

A crafted Action or dtid value yields a reflected XSS that
executes in the operator's browser with same-origin access to the
vttablet's debug endpoints. This includes /queryz (live query plans),
/querylogz (recent queries with bound values), /txlogz (transactions),
/debug/env (environment variables — may include MySQL/topology
credentials), /debug/vars (expvar stats), and /debug/pprof/* if
enabled.

The bug was introduced before v20.0.0 (long-standing) and was silently
fixed in commit 3140c1846c (merged 2026-06-09, PR #20255,
"tabletserver: escape reflected form values in twopcz handler"). The
fix replaces fmt.Fprintln(w, msg) with
fmt.Fprintln(w, html.EscapeString(msg)). No released version of
Vitess contains the fix
— the fix lives only on main (current tip
33a3c0fafe69, 2026-06-23). There is no CVE, GHSA, or OSV entry
for this…

Source: NIST National Vulnerability Database NVD GitHub Advisory

Auto-generated summary

Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.

A vulnerability tracked as CVE-2026-104252 has been found in vitess.io/vitess.
Attackers can target a specific entry point like twopczHandler over the network to misuse the product.
Successful exploitation can lead to full system takeover. CVSS score: 9.8/10.
What to do: upgrade vitess.io/vitess to 20.0.4 or later.
If unsure, ask your IT team or search "vitess.io/vitess CVE-2026-104252" on the vendor's site.

CVE-2026-104252 (vitess.io/vitess) — CWE-79 / CVSS v3 9.8
Attack vector: remote (network-reachable) / unauthenticated / no user interaction
Attack surface: twopczHandler / Action / dtid / acl
Patched: 20.0.4 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.

❓ What is the problem

Cross-site scripting (XSS) (CWE-79) exists in vitess.io/vitess. Attackers reach the vulnerable code path via twopczHandler without authentication.

📍 Affected scope

Check the vendor advisory for the affected versions of vitess.io/vitess. Attack surface: twopczHandler / Action / dtid / acl.

🔥 Severity

Severity: Critical (CVSS 9.8/10). Successful exploitation can lead to full system takeover.

🔧 How to fix

Update to 20.0.4.

🛡️ Workaround

Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.

🔍 Detection

Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'vitess.io/vitess' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.

Response actions

Concrete steps and command examples for SOC/SRE teams to execute in order

  1. 1
    Identify exposure identify
    grep -r 'vitess.io/vitess' . | grep -v node_modules

    リポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で vitess.io/vitess を grep し、稼働しているサービス・バージョンを把握する。

  2. 2
    Apply patch patch
    Upgrade vitess.io/vitess to 20.0.4

    ステージング環境で 20.0.4 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。

  3. 3
    Post-deployment verification verify
    Confirm patched version is live in production

    パッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。

Affected packages

go vitess.io/vitess
[{"type":"SEMVER","events":[{"introduced":"0.24.0"},{"fixed":"0.24.2"}]}]

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details