Advisory Database
  • Advisories
  • Dependency Scanning
  1. cargo
  2. ›
  3. diesel
  4. ›
  5. CVE-2021-28305

CVE-2021-28305: Fix a use-after-free bug in diesels Sqlite backend

May 24, 2022 (updated June 16, 2022)

An issue was discovered in the diesel crate before 1.4.6 for Rust. There is a use-after-free in the SQLite backend because the semantics of sqlite3_column_name are not followed.

References

  • github.com/advisories/GHSA-j8q9-5rp9-4mv9
  • github.com/diesel-rs/diesel
  • github.com/diesel-rs/diesel/pull/2663
  • nvd.nist.gov/vuln/detail/CVE-2021-28305
  • rustsec.org/advisories/RUSTSEC-2021-0037.html

Code Behaviors & Features

Detect and mitigate CVE-2021-28305 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions before 1.4.6

Fixed versions

  • 1.4.6

Solution

Upgrade to version 1.4.6 or above.

Impact 9.8 CRITICAL

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-416: Use After Free

Source file

cargo/diesel/CVE-2021-28305.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:16:12 +0000.