Skip to content

← Actionable
High, CVSS 7.8

TiDB authentication bypass vulnerability

CVE-2022-31011GHSA-4whx-7p29-mq22

What to do

Vendor fix available. Upgrade each affected package to the fixed version on its release line (github.com/pingcap/tidb 5.3.1, 1.1.0-beta.0.20220221072141-27ffd1126da1, 0.0.0-20220221072141-27ffd1126da1), redeploy, then verify what is actually installed.

This page has no inventory attached, so it cannot say whether you are affected. A vendor fix is not proof that your deployment is fixed.

Affected packages

  • Go github.com/pingcap/tidb

    Affected
    >= 5.3.0, <= 5.3.0>= 0.0.0-20210808221113-a7fdc2a05663, < 0.0.0-20220221072141-27ffd1126da1>= 1.1.0-beta.0.20210808221113-a7fdc2a05663, < 1.1.0-beta.0.20220221072141-27ffd1126da1
    Fixed in
    5.3.1, 0.0.0-20220221072141-27ffd1126da1, 1.1.0-beta.0.20220221072141-27ffd1126da1

Sources

  • GitHub Advisory Database and maintainer security advisories on GitHub

    GitHub-reviewed advisory GHSA-4whx-7p29-mq22 lists affected ranges: Go github.com/pingcap/tidb >=5.3.0 =0.0.0-20210808221113-a7fdc2a05663 =1.1.0-beta.0.20210808221113-a7fdc2a05663 <1.1.0-beta.0.20220221072141-27ffd1126da1

    VerifiedObserved Structured GitHub Advisory Database record (type=reviewed) from the GitHub REST API.

Severity and exploitation
Exploitation
No confirmed exploitation recorded. Patch Next marks exploitation only from CISA KEV.
CVSS
7.8 · CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS
  • CVE-2022-31011: 0.32% estimated exploitation activity in the next 30 days; percentile 25.44 (FIRST EPSS, 2026-11-03). This is a model estimate, not proof of exploitation or customer exposure.
Source description

As published by the source; long descriptions are shortened.

Impact Under certain conditions, an attacker can construct malicious authentication requests to bypass the authentication process, resulting in privilege escalation or unauthorized access. Only users using TiDB 5.3.0 are affected by this vulnerability. Patches Please upgrade to TiDB 5.3.1 or higher version Workarounds You can also mitigate risks by taking the following measures. Option 1: Turn off SEM (Security Enhanced Mode). Option 2: Disable local login for non-root accounts and ensure that the same IP cannot be logged in as root or normal user at the same time. References https://en.pingcap.com/download/ For more information If you have any questions or comments about this advisory: Email us at security@tidb.io

Dates and revisions
Published by the source
Last modified by the source
Source last checked
  1. Revision 1 · created ·

    Published from ghsa record GHSA-4whx-7p29-mq22

Agent brief

Preview the exact text before you copy it. Commands are read-only suggestions; review them before running anything.

# Patch Next advisory brief: CVE-2022-31011

Advisory: TiDB authentication bypass vulnerability
IDs: CVE-2022-31011, GHSA-4whx-7p29-mq22
Record: https://patchnext.com/advisories/cve-2022-31011 (revision 1, source checked 26 Oct 2026, 15:09 UTC)
Inventory: none attached. This brief comes from a public page and does not say whether any deployment is affected.
Severity: High (CVSS 7.8)
Exploitation: no confirmed exploitation recorded. Patch Next confirms exploitation only from CISA KEV.
Vendor response: Vendor fix available; fixed versions by package: github.com/pingcap/tidb 5.3.1, 1.1.0-beta.0.20220221072141-27ffd1126da1, 0.0.0-20220221072141-27ffd1126da1. A vendor fix does not mean a deployment is fixed.

## Affected components
- Go github.com/pingcap/tidb: affected >= 5.3.0, <= 5.3.0; >= 0.0.0-20210808221113-a7fdc2a05663, < 0.0.0-20220221072141-27ffd1126da1; >= 1.1.0-beta.0.20210808221113-a7fdc2a05663, < 1.1.0-beta.0.20220221072141-27ffd1126da1; fixed in 5.3.1, 0.0.0-20220221072141-27ffd1126da1, 1.1.0-beta.0.20220221072141-27ffd1126da1

## Suggested inspection (read-only)
- Go github.com/pingcap/tidb: check the installed version with your package manager.

## Supported action
Upgrade each affected component to a fixed version on its release line. For a transitive dependency, upgrade the parent package or add an override or constraint, then regenerate the lockfile. Redeploy every environment that ran an affected version.

## Required regression checks
- Run the test suite and a production build.
- Exercise the features that depend on github.com/pingcap/tidb.
- Repeat the inspection and confirm that only fixed versions remain installed.

## Rollback considerations
- Keep the previous lockfile and deployment artifact. Rolling back reinstates the vulnerable version, so apply any documented mitigation while you fix forward.

## Unresolved questions
- Which deployments run an affected version?
- Exploitation status can change. Check again before lowering the priority.
- Mark the work resolved only after the fixed version is verified in production.

## Sources
- Verified: https://github.com/advisories/GHSA-4whx-7p29-mq22 (GitHub-reviewed advisory GHSA-4whx-7p29-mq22 lists affected ranges: Go github.com/pingcap/tidb >=5.3.0 =0.0.0-20210808221113-a7fdc2a05663 =1.1.0-beta.0.20210808221113-a7fdc2a05663 <1.1.0-beta.0.20220221072141-27ffd1126da1)

Commands are suggestions: review each one before running it.

Loading voting…