{"id":"CVE-2022-31011","aliases":["CVE-2022-31011","GHSA-4whx-7p29-mq22"],"related":[],"kind":"vulnerability","state":"published","title":"TiDB authentication bypass vulnerability","summary":"TiDB is an open-source NewSQL database that supports Hybrid Transactional and Analytical Processing (HTAP) workloads. 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. TiDB version 5.3.1 contains a patch for this issue. Other mitigation strategies include turning off Security Enhanced Mode (SEM), disabling local login for non-root accounts, and ensuring that the same IP cannot be logged in as root and normal user at the same time.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"TiDB is an open-source NewSQL database that supports Hybrid Transactional and Analytical Processing (HTAP) workloads. 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. TiDB version 5.3.1 contains a patch for this issue. Other mitigation strategies include turning off Security Enhanced Mode (SEM), disabling local login for non-root accounts, and ensuring that the same IP cannot be logged in as root and normal user at the same time.","source":"cvelist"},{"lang":"en","text":"### Impact\nUnder certain conditions, an attacker can construct malicious authentication requests to bypass the authentication process, resulting in privilege escalation or unauthorized access.\nOnly users using TiDB 5.3.0 are affected by this vulnerability.\n\n### Patches\nPlease upgrade to TiDB 5.3.1 or higher version\n\n### Workarounds\nYou can also mitigate risks by taking the following measures.\nOption 1: Turn off SEM (Security Enhanced Mode).\nOption 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.\n\n### References\nhttps://en.pingcap.com/download/\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Email us at security@tidb.io","format":"markdown","source":"ghsa"},{"lang":"es","text":"TiDB es una base de datos NewSQL de código abierto que soporta cargas de trabajo de Procesamiento Transaccional y Analítico Híbrido (HTAP). Bajo determinadas condiciones, un atacante puede construir peticiones de autenticación maliciosas para omitir el proceso de autenticación, resultando en una escalada de privilegios o un acceso no autorizado. Sólo los usuarios usando TiDB versión 5.3.0, están afectados por esta vulnerabilidad. TiDB versión 5.3.1, contiene un parche para este problema. Otras estrategias de mitigación incluyen la deshabilitación del modo mejorado de seguridad (SEM), la deshabilitación del inicio de sesión local para las cuentas que no son root y la garantía de que la misma IP no puede iniciar sesión como root y usuario normal al mismo tiempo","source":"nvd"}],"published":"2022-05-31T19:30:18.000Z","modified":"2026-06-17T04:44:36.047Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:L/AC:L/Au:N/C:P/I:P/A:P","score":4.6,"rating":"MEDIUM"}],"cwes":["CWE-287"],"affected":[{"ranges":[{"version":"= 5.3.0","status":"affected"}],"vendor":"pingcap","product":"tidb","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"5.3.0","status":"affected","fixed":"5.3.1"}],"ecosystem":"Go","package":"github.com/pingcap/tidb","purl":"pkg:golang/github.com/pingcap/tidb","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0.0.0-20210808221113-a7fdc2a05663","status":"affected","fixed":"0.0.0-20220221072141-27ffd1126da1"}],"ecosystem":"Go","package":"github.com/pingcap/tidb","purl":"pkg:golang/github.com/pingcap/tidb","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"1.1.0-beta.0.20210808221113-a7fdc2a05663","status":"affected","fixed":"1.1.0-beta.0.20220221072141-27ffd1126da1"}],"ecosystem":"Go","package":"github.com/pingcap/tidb","purl":"pkg:golang/github.com/pingcap/tidb","source":"ghsa"},{"ranges":[{"status":"affected","version":"5.3.0"}],"vendor":"pingcap","product":"tidb","cpe":"cpe:2.3:a:pingcap:tidb:5.3.0:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/pingcap/tidb/security/advisories/GHSA-4whx-7p29-mq22","tags":["mitigation","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/pingcap/tidb/releases/tag/v5.3.1","tags":["release-notes","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-31011","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/pingcap/tidb","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2025-04-23T15:52:41.646Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-31011","url":"https://www.cve.org/CVERecord?id=CVE-2022-31011","licence":"CVE Terms of Use","modified":"2025-04-23T18:20:55.933Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-4whx-7p29-mq22","url":"https://github.com/advisories/GHSA-4whx-7p29-mq22","licence":"CC-BY-4.0","modified":"2025-07-09T15:49:23.000Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-31011","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-31011","licence":"Public domain","modified":"2026-06-17T04:44:36.047Z"}],"updatedAt":"2026-11-25T22:58:12.015Z","epss":{"score":0.00323,"percentile":0.27395,"date":"2026-12-01T12:00:22.000Z"}}