# CVE-2022-31026: Use of Uninitialized Variable in trilogy

- Severity: Medium 5.9 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.09%, higher than 66% of CVEs (2026-12-01)
- Published: 2022-06-06T21:05:14.000Z
- Modified: 2026-06-17T04:44:38.027Z
- Also known as: GHSA-5g4r-2qhx-vqfm
- Weaknesses: CWE-908
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Trilogy is a client library for MySQL. When authenticating, a malicious server could return a specially crafted authentication packet, causing the client to read and return up to 12 bytes of data from an uninitialized variable in stack memory. Users of the trilogy gem should upgrade to version 2.1.1 This issue can be avoided by only connecting to trusted servers.

(As written by CVE List.)

## Affected

- github trilogy: < 2.1.1
- trilogy (RubyGems): before 2.1.1
- trilogy_project trilogy: before 2.1.1

## Every score

- GitHub_M: CVSS:3.1 5.9 Medium `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H`
- GitHub: CVSS:3.1 5.9 Medium `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H`
- NVD: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- NVD: CVSS:2.0 5.0 Medium `AV:N/AC:L/Au:N/C:P/I:N/A:N`

## References

- <https://github.com/github/trilogy/security/advisories/GHSA-5g4r-2qhx-vqfm> (third-party-advisory, web)
- <https://github.com/github/trilogy/commit/6bed62789eaf119902b0fe247d2a91d56c31a962> (patch, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2022-31026> (advisory)
- <https://github.com/github/trilogy> (package)
- <https://github.com/rubysec/ruby-advisory-db/blob/master/gems/trilogy/CVE-2022-31026.yml> (web)

## Sources

- CVE List: [CVE-2022-31026](https://www.cve.org/CVERecord?id=CVE-2022-31026), CVE Terms of Use, modified 2025-04-23
- GitHub Advisory Database: [GHSA-5g4r-2qhx-vqfm](https://github.com/advisories/GHSA-5g4r-2qhx-vqfm), CC-BY-4.0, modified 2023-11-08
- NVD: [CVE-2022-31026](https://nvd.nist.gov/vuln/detail/CVE-2022-31026), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2022-31026 · Whole record: https://cve.day/CVE-2022-31026.json · Rebuilt by cve.day 2026-11-25T22:58:12.184Z
