All CVEs / Activerecord Project
CVE-2023-22794Activerecord Project Activerecord
High 8.8
Follow: this CVE · Activerecord Project · Activerecord Project Activerecord We alert you by email or Slack (account required).
- Priority
- 53
- CVSS 3.1
- 8.8
- EPSS
- 2.0% probability of exploitation in 30 days · percentile 82
- Auth required
- Yes
- Published
- Feb 9, 2023
- Updated
- Oct 23, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-89
- Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
What happens
A vulnerability in ActiveRecord <6.0.6.1, v6.1.7.1 and v7.0.4.1 related to the sanitization of comments. If malicious user input is passed to either the `annotate` query method, the `optimizer_hints` query method, or through the QueryLogs interface which automatically adds annotations, it may be sent to the database withinsufficient sanitization and be able to inject SQL outside of the comment.
What to do
- Apply the vendor's security update for Activerecord.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| RubyGems | activerecord |
≥ 6.0.0 < 6.0.6.1 |
6.0.6.1 |
gem "activerecord", ">= 6.0.6.1" |
| RubyGems | activerecord |
≥ 6.1.0 < 6.1.7.1 |
6.1.7.1 |
gem "activerecord", ">= 6.1.7.1" |
| RubyGems | activerecord |
≥ 7.0.0 < 7.0.4.1 |
7.0.4.1 |
gem "activerecord", ">= 7.0.4.1" |
Per OSV / GitHub Advisories (GHSA-hq7p-j377-6v63). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| activerecord_project | activerecord | ≥ 6.0.0 < 6.0.6.1 |
| activerecord_project | activerecord | ≥ 6.1.0 < 6.1.7.1 |
| activerecord_project | activerecord | ≥ 7.0.0 < 7.0.4.1 |
Official advisories
- Red Hat Security Advisory: Satellite 6.14 security and bug fix update · Red Hat · RHSA-2023:6818 · Oct 2, 2024 High
Vendor, CERT and distribution advisories that name this CVE. Original titles.
Official sources
References
Links published by the sources. Open them with care.
- discuss.rubyonrails.org Exploit Patch Vendor Advisory
- security.netapp.com
- www.debian.org