CVE-2021-45713 json
Use After Free in rusqlite
published 4y ago modified 4mo ago also CVE-2021-45714 , CVE-2021-45715 , CVE-2021-45716 , CVE-2021-45717 , CVE-2021-45718 , CVE-2021-45719 , GHSA-4qr3-m7ww-hh9g , GHSA-87xh-9q6h-r5cc , GHSA-92cx-4xm7-jr9m , GHSA-cm8g-544f-p9x9 , GHSA-f6f2-3w33-54r9 , GHSA-g4g4-3pqw-8m7f , GHSA-g87r-23vw-7f87 , GHSA-q89g-4vhh-mvvm , RUSTSEC-2021-0128 , EUVD-2022-0538
- cvss
- 7.5
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.2%
- EPSS 1.2% chance of exploitation in 30 days, percentile 68%
- public exploits
- 0
- none known
Summary
An issue was discovered in the rusqlite crate 0.25.x before 0.25.4 and 0.26.x before 0.26.2 for Rust. create_scalar_function has a use-after-free.
Patch / fix
- crates.io rusqlite 0.25.4, 0.26.2
- rusqlite_project rusqlite 0.25.4, 0.26.2
- github.com/rusqlite/rusqlite@30f8c8c commit
- github.com/rusqlite/rusqlite@6121585 commit
- github.com/rusqlite/rusqlite@934e0c7 commit
- github.com/rusqlite/rusqlite@f4f95f8 commit
- github.com/rusqlite/rusqlite#1049 pull request
Is CVE-2021-45713 in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.
Check with FencerVendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2021-45713 updated cvss 7.5
rusqlite: Several security flaws fixed in rusqlite 0.26.2
-
Red Hat All currently supported Red Hat productsnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Exploit prediction
1.22% chance of exploitation in the next 30 days, higher than 68% of all scored CVEs (FIRST EPSS, 2026-11-09).
Exploits and checks
- rustsec.org https://rustsec.org/advisories/RUSTSEC-2021-0128.html referenced PoC, tagged "exploit" by a source, unverified
- raw.githubusercontent.com https://raw.githubusercontent.com/rustsec/advisory-db/main/crates/rusqlite/RUSTSEC-2021-0128.md referenced PoC, tagged "exploit" by a source, unverified
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| NVD | 2.0 | 5.0 | AV:N/AC:L/Au:N/C:N/I:N/A:P |
| GitHub | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| GitHub | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| crates.io | rusqlite | >=0.25.0, <0.25.4 >=0.26.0, <0.26.2 >=0.26.0-0, <0.26.2 |
0.25.4 0.26.2 |
Classification
- Weakness
-
- CWE-416 Use After Free
References
-
github.com
/rusqlite/rusqlite/pull/1049
web
-
github.com
/rusqlite/rusqlite/commit/30f8c8c502675011603c4d066396bf317fd49e71
web
-
github.com
/rusqlite/rusqlite/commit/612158507e90f41d409cd0fa80eb21c992b1bc08
web
-
github.com
/rusqlite/rusqlite/commit/934e0c709e156753881da98b32e9853f9ffe4a1b
web
-
github.com
/rusqlite/rusqlite/commit/f4f95f8caf9fd53bffd0c19530be2484c644cc16
web
-
rustsec.org
/advisories/RUSTSEC-2021-0128.html
web, exploit, issue-tracking, third-party-advisory, advisory
-
raw.githubusercontent.com
/rustsec/advisory-db/main/crates/rusqlite/RUSTSEC-2021-0128.md
web, exploit, third-party-advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-45718
advisory
-
github.com
/rusqlite/rusqlite/issues/1048
web, report
-
github.com
/rusqlite/rusqlite
web, package
-
nvd.nist.gov
/vuln/detail/CVE-2021-45719
advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-45716
advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-45717
advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-45713
advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-45715
advisory
-
nvd.nist.gov
/vuln/detail/CVE-2021-45714
advisory
-
crates.io
/crates/rusqlite
package
Sources
- CVE List CVE-2021-45713
- GitHub Advisory GHSA-g4g4-3pqw-8m7f
- GitHub Advisory GHSA-g87r-23vw-7f87
- GitHub Advisory GHSA-cm8g-544f-p9x9
- GitHub Advisory GHSA-4qr3-m7ww-hh9g
- GitHub Advisory GHSA-q89g-4vhh-mvvm
- GitHub Advisory GHSA-92cx-4xm7-jr9m
- GitHub Advisory GHSA-87xh-9q6h-r5cc
- GitHub Advisory GHSA-f6f2-3w33-54r9
- NVD CVE-2021-45713
- OSV RUSTSEC-2021-0128
Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.