GHSA-28ph-f7gx-fqj8 CVE-2020-35866 CVE-2020-35867 CVE-2020-35868 CVE-2020-35869 CVE-2020-35870 CVE-2020-35871 CVE-2020-35872 CVE-2020-35873 GHSA-3cgf-9m6x-pwwr GHSA-6q5w-m3c5-rv95 GHSA-8h4j-vm3r-vcq3 GHSA-8r7q-r9mx-35rh GHSA-g4w7-3qr8-5623 GHSA-q3cc-7p7g-392c GHSA-rjh8-p66p-jrh5 RUSTSEC-2020-0014
Data races in rusqlite
- Severity
- 9.8 / 10
- Critical · CVSS 3.1
- Exploit chance (EPSS)
- 1.75%
- Chance of exploitation in the next 30 days. Higher than 77.88% of scored vulnerabilities.
- Known exploited
- No
- Not in CISA's catalog
- Weakness
- CWE-362 Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')
- Fix
0.23.0- Upgrade rusqlite to this version or later
Description
An issue was discovered in the rusqlite crate before 0.23.0 for Rust. Memory safety can be violated via create_module.
Affected versions
crates.io
How to fix
Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.
rusqlite crates.io → 0.23.0
- cargo
cargo update -p rusqlite --precise 0.23.0
Severity breakdown
CVSS 3.1 9.8
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- None
- Scope
- Unchanged
- Confidentiality
- High
- Integrity
- High
- Availability
- High
Weakness
CWE-362: Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')
The product contains a concurrent code sequence that requires temporary, exclusive access to a shared resource, but a timing window exists in which the shared resource can be modified by another code sequence operating concurrently.
How to prevent it
- Architecture and Design: In languages that support it, use synchronization primitives. Only wrap these around critical code to minimize the impact on performance.
- Architecture and Design: Use thread-safe capabilities such as the data access abstraction in Spring.
- Architecture and Design: Minimize the usage of shared resources in order to remove as much complexity as possible from the control flow and to reduce the likelihood of unexpected conditions occurring. Additionally, this will minimize the amount of synchronization necessary and may even help to reduce the likelihood of a denial of service where an attacker may be able to repeatedly trigger a critical section (CWE-400).
- Implementation: When using multithreading and operating on shared variables, only use thread-safe functions.
- Implementation: Use atomic operations on shared variables. Be wary of innocent-looking constructs such as "x++". This may appear atomic at the code layer, but it is actually non-atomic at the instruction layer, since it involves a read, followed by a computation, followed by a write.
- Implementation: Use a mutex if available, but be sure to avoid related weaknesses such as CWE-412.
- Implementation: Avoid double-checked locking (CWE-609) and other implementation errors that arise when trying to avoid the overhead of synchronization.
- Implementation: Disable interrupts or signals over critical parts of the code, but also make sure that the code does not go into a large or infinite loop.
- Implementation: Use the volatile type modifier for critical variables to avoid unexpected compiler optimization or reordering. This does not necessarily solve the synchronization problem, but it can help.
- Architecture and Design, Operation: Run your code using the lowest privileges that are required to accomplish the necessary tasks [REF-76]. If possible, create isolated accounts with limited privileges that are only used for a single task. That way, a successful attack will not immediately give the attacker access to the rest of the software or its environment. For example, database applications rarely need to run as the database administrator, especially in day-to-day operations.
References
Advisories
- nvd.nist.gov/vuln/detail/CVE-2020-35867
- nvd.nist.gov/vuln/detail/CVE-2020-35868
- nvd.nist.gov/vuln/detail/CVE-2020-35866
- nvd.nist.gov/vuln/detail/CVE-2020-35870
- nvd.nist.gov/vuln/detail/CVE-2020-35869
- nvd.nist.gov/vuln/detail/CVE-2020-35872
- nvd.nist.gov/vuln/detail/CVE-2020-35873
- nvd.nist.gov/vuln/detail/CVE-2020-35871
Packages
Other links
- github.com/rusqlite/rusqlite/commit/3c6b57fe1b2cc87e7ebecde43dd836ffb1c4ea5c
- github.com/rusqlite/rusqlite/releases/tag/0.23.0
- rustsec.org/advisories/RUSTSEC-2020-0014.html
- github.com/rusqlite/rusqlite/commit/45fd77ee43c38eea4d6f4e2e56c1667a55ec654f
- github.com/rusqlite/rusqlite/commit/c9ef5bd63cad5c0c123344c072b490a1a9bcbe1f
- github.com/rusqlite/rusqlite/commit/2ef3628dac35aeba0a97d5fb3a57746b4e1d62b3
- github.com/rusqlite/rusqlite/commit/2327d3b774927fdf48903c0bdc1ca7ec93c7c8d0
- github.com/rusqlite/rusqlite/commit/71b2f5187b0cbace3f8b6ff53432ff2ca0defcf0
- github.com/rusqlite/rusqlite/commit/ac30e169ae51b262bc8cf7026469851ce39b23c6
Timeline
- Published
- Last updated by the source
- Latest EPSS score
Related advisories
| Advisory | Severity | Why it's related |
|---|---|---|
| GHSA-4qr3-m7ww-hh9g Use After Free in rusqlite | High | Also affects rusqlite |
| GHSA-5wjr-9356-4wc8 Tokio: Race condition in `tokio::time::Interval` | Medium | Same weakness, CWE-362 |
| GHSA-44jh-23m7-hpcf @better-auth/drizzle-adapter: Concurrent requests can exceed rate limits on PostgreSQL | Medium | Same weakness, CWE-362 |
| GHSA-494h-xx7x-5frh Microsoft Security Advisory CVE-2026-70183 - ASP.NET Core Security Feature Bypass Vulnerability | High | Same weakness, CWE-362 |
| GO-2026-6617 HTTP/2 server crash due to HPACK encoder race in net/http | High | Same weakness, CWE-362 |
| GHSA-xvgh-hmx8-9xxf Backstage: Improper task state validation in Scaffolder backend | High | Same weakness, CWE-362 |
| GHSA-pr7f-p5mw-fc87 vLLM: Incomplete CVE-2025-62164 remediation can be bypassed by concurrent prompt parts | Medium | Same weakness, CWE-362 |
| GHSA-2hw9-mc66-jc2q Wasmtime: Preemption and traps during bulk operations enable breaking internal VM state | Low | Same weakness, CWE-362 |
MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.
Check your repos with MergeHarbor