CVE-2023-31147: Insufficient randomness in generation of DNS query IDs in c-ares
Noroxi assessment
Priority: Monitor (action score 26/100)
- The sources we track (CISA KEV, Exploit-DB, Metasploit, Nuclei, GitHub) show no public exploit code or exploitation in the wild.
- Probability of exploitation in the next 30 days: 0.90% (FIRST EPSS); higher than 60.2% of all records.
- Anyone who can reach it over the internet can trigger it. No account or password is required. No user action is required. No special conditions are required; it is repeatable.
- Fixed version: c-ares c-ares 1.19.1; azl3 grpc 1.42.0-7 on Azure Linux 3.0 1.62.0-2; azl3 grpc 1.62.0-2 on Azure Linux 3.0 1.62.0-2.
Low priority for now. Upgrade to c-ares c-ares 1.19.1; azl3 grpc 1.42.0-7 on Azure Linux 3.0 1.62.0-2; azl3 grpc 1.62.0-2 on Azure Linux 3.0 1.62.0-2 or later.
Generated automatically from the record's data: CVSS (NVD and CNA), CISA KEV and SSVC, FIRST EPSS, exploit sources, fixed versions. How we calculate it
Primary sources: NVD · CVE.org · FIRST EPSS
c-ares is an asynchronous resolver library. When /dev/urandom or RtlGenRandom() are unavailable, c-ares uses rand() to generate random numbers used for DNS query ids. This is not a CSPRNG, and it is also not seeded by srand() so will generate predictable output. Input from the random number generator is fed into a non-compilant RC4 implementation and may not be as strong as the original RC4 implementation. No attempt is made to look for modern OS-provided CSPRNGs like arc4random() that is widely available. This issue has been fixed in version 1.19.1.
- ALSA-2023:3577
- ALSA-2023:3586
- ALSA-2023:4034
- ALSA-2023:4035
- ALSA-2023:6635
- openSUSE-SU-2024:12951-1
- RHSA-2023:3577
- RHSA-2023:3586
- RHSA-2023:4033
- RHSA-2023:4034
- RHSA-2023:4035
- RHSA-2023:4036
- RHSA-2023:4039
- RHSA-2023:6635
- RLSA-2023:3577
- RLSA-2023:4034
- RLSA-2023:4035
- SUSE-SU-2023:2313-1
- SUSE-SU-2023:2477-1
- SUSE-SU-2023:2655-1
- Published
- May 25, 2023
- Updated
- Jun 17, 2026
- EPSS
- 0.9% · 60th percentile
- CWE
- CWE-330
Report tools
Action score
26
Low priority for now.
- CVSS
- 26 / 40 · 6.5 / 10
- CISA KEV
- 0 / 30 · Not listed
- EPSS
- 0 / 30 · 0.9%
CISA SSVC decision
- Exploitation
- none
- Automatable
- no
- Technical impact
- partial
Vulnrichment: CISA's decision-tree inputs.
CNA vs NVD score
- NVD
- 6.5
- CNA · GitHub_M
- 5.9
- 0.6 point gap
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N
The score given by the assigning authority versus NVD’s independent score. A gap means the severity is contested.
Get told when this record changes
- Not in KEV: no record of exploitation in the wild
- No public exploit code on record
- A fix has been released
If any of these changes, we'll tell you in the daily email digest.
Is your version affected? Check itNoroxi analysis
What does it mean in your environment?
The assessment above is generated automatically from the record's data; it doesn't know your environment. Our team verifies on your systems whether this vulnerability is actually exploitable and which mitigation is enough.
We use this product, ask for helpAffected systems
Is your version affected?
Pick the product and type the version you run. It's compared with this record's version ranges in your browser; the version isn't sent anywhere.
| Vendor | Product | CPE |
|---|---|---|
| c-ares project | c-ares | cpe:2.3:a:c-ares_project:c-ares |
| fedoraproject | fedora | cpe:2.3:o:fedoraproject:fedora |
Versions reported by the vendor
Affected version ranges reported by the assigning authority (GitHub_M). Independent of NVD's CPE analysis and usually ahead of it.
c-ares c-ares
- < 1.19.1affected
Affected versions
NVD version ranges (for catalog products). Add the product to your stack with a version and matching uses these.
- c-ares project c-aresbefore 1.19.1
- fedoraproject fedora37
- fedoraproject fedora38
Package-level exposure
OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.
| Ecosystem | Package | Affected range | Fix |
|---|---|---|---|
| AlmaLinux:8 | nodejs | before 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 | 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 |
| AlmaLinux:8 | nodejs | before 1:18.14.2-3.module_el8.8.0+3587+ee652244 | 1:18.14.2-3.module_el8.8.0+3587+ee652244 |
| AlmaLinux:8 | nodejs-devel | before 1:18.14.2-3.module_el8.8.0+3587+ee652244 | 1:18.14.2-3.module_el8.8.0+3587+ee652244 |
| AlmaLinux:8 | nodejs-devel | before 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 | 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 |
| AlmaLinux:8 | nodejs-docs | before 1:18.14.2-3.module_el8.8.0+3587+ee652244 | 1:18.14.2-3.module_el8.8.0+3587+ee652244 |
| AlmaLinux:8 | nodejs-docs | before 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 | 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 |
| AlmaLinux:8 | nodejs-full-i18n | before 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 | 1:16.19.1-2.module_el8.8.0+3586+d4fc0b72 |
| AlmaLinux:8 | nodejs-full-i18n | before 1:18.14.2-3.module_el8.8.0+3587+ee652244 | 1:18.14.2-3.module_el8.8.0+3587+ee652244 |
| AlmaLinux:8 | nodejs-nodemon | before 2.0.20-2.module_el8.8.0+3587+ee652244 | 2.0.20-2.module_el8.8.0+3587+ee652244 |
| AlmaLinux:8 | nodejs-nodemon | before 2.0.20-3.module_el8.8.0+3586+d4fc0b72 | 2.0.20-3.module_el8.8.0+3586+d4fc0b72 |
| AlmaLinux:8 | nodejs-packaging | before 25-1.module_el8.5.0+2605+45d748af | 25-1.module_el8.5.0+2605+45d748af |
| AlmaLinux:8 | nodejs-packaging | before 2021.06-4.module_el8.7.0+3343+ea2b7901 | 2021.06-4.module_el8.7.0+3343+ea2b7901 |
| AlmaLinux:8 | nodejs-packaging-bundler | before 2021.06-4.module_el8.7.0+3343+ea2b7901 | 2021.06-4.module_el8.7.0+3343+ea2b7901 |
| AlmaLinux:8 | npm | before 1:9.5.0-1.18.14.2.3.module_el8.8.0+3587+ee652244 | 1:9.5.0-1.18.14.2.3.module_el8.8.0+3587+ee652244 |
| AlmaLinux:8 | npm | before 1:8.19.3-1.16.19.1.2.module_el8.8.0+3586+d4fc0b72 | 1:8.19.3-1.16.19.1.2.module_el8.8.0+3586+d4fc0b72 |
| AlmaLinux:9 | c-ares | before 1.19.1-1.el9 | 1.19.1-1.el9 |
| AlmaLinux:9 | c-ares-devel | before 1.19.1-1.el9 | 1.19.1-1.el9 |
| AlmaLinux:9 | nodejs | before 1:16.19.1-2.el9_2 | 1:16.19.1-2.el9_2 |
| AlmaLinux:9 | nodejs | before 1:18.14.2-3.module_el9.2.0+30+e3312493 | 1:18.14.2-3.module_el9.2.0+30+e3312493 |
| AlmaLinux:9 | nodejs-devel | before 1:18.14.2-3.module_el9.2.0+30+e3312493 | 1:18.14.2-3.module_el9.2.0+30+e3312493 |
| AlmaLinux:9 | nodejs-docs | before 1:18.14.2-3.module_el9.2.0+30+e3312493 | 1:18.14.2-3.module_el9.2.0+30+e3312493 |
| AlmaLinux:9 | nodejs-docs | before 1:16.19.1-2.el9_2 | 1:16.19.1-2.el9_2 |
| AlmaLinux:9 | nodejs-full-i18n | before 1:18.14.2-3.module_el9.2.0+30+e3312493 | 1:18.14.2-3.module_el9.2.0+30+e3312493 |
| AlmaLinux:9 | nodejs-full-i18n | before 1:16.19.1-2.el9_2 | 1:16.19.1-2.el9_2 |
+96
Same product
c-ares project: all recordsOther highest-scoring records for the same primary product.
- CVE-2022-4904A flaw was found in the c-ares package.34Monitor
- CVE-2023-320670-byte UDP payload DoS in c-ares30Monitor
- CVE-2023-31130Buffer Underwrite in ares_inet_net_pton()25Monitor
Published before and after this one in the same product
- ← EarlierCVE-2021-3672Nov 23, 2021 · A flaw was found in c-ares library, where a missing input validation check of host names returned by DNS (Domain Name Servers) can lead to…23Monitor
- ← EarlierCVE-2023-31124May 25, 2023 · AutoTools does not set CARES_RANDOM_FILE during cross compilation14Monitor
Remediation
Which version to upgrade to
Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.
| Product / package | Fixed version | Source |
|---|---|---|
| c-ares c-ares | 1.19.1 · description | Vendor (CNA) |
| azl3 grpc 1.42.0-7 on Azure Linux 3.0 | 1.62.0-2 · CBL-Mariner Releases | Microsoft (MSRC) |
| azl3 grpc 1.62.0-2 on Azure Linux 3.0 | 1.62.0-2 · CBL-Mariner Releases | Microsoft (MSRC) |
| cbl2 c-ares 1.19.1-1 on CBL Mariner 2.0 | 1.19.1-1 · CBL-Mariner Releases | Microsoft (MSRC) |
| cbl2 fluent-bit 2.1.10-1 on CBL Mariner 2.0 | 2.1.10-1 · CBL-Mariner Releases | Microsoft (MSRC) |
| cbl2 grpc 1.42.0-10 on CBL Mariner 2.0 | 1.42.0-10 · CBL-Mariner Releases | Microsoft (MSRC) |
| cbl2 nodejs 16.20.1-2 on CBL Mariner 2.0 | 16.20.1-2 · CBL-Mariner Releases | Microsoft (MSRC) |
| cbl2 nodejs18 18.17.1-2 on CBL Mariner 2.0 | 18.17.1-2 · CBL-Mariner Releases | Microsoft (MSRC) |
| cbl2 python-gevent 21.1.2-3 on CBL Mariner 2.0 | 21.1.2-3 · CBL-Mariner Releases | Microsoft (MSRC) |
| cm1 c-ares 1.19.1-1 on CBL Mariner 1.0 | 1.19.1-1 · CBL-Mariner Releases | Microsoft (MSRC) |
| almalinux:c-ares | 1.19.1-1.el9 · AlmaLinux:9 | Package registry (OSV) |
| almalinux:c-ares-devel | 1.19.1-1.el9 · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs | 1:18.14.2-3.module_el9.2.0+30+e3312493 · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs-devel | 1:18.14.2-3.module_el9.2.0+30+e3312493 · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs-docs | 1:18.14.2-3.module_el9.2.0+30+e3312493 · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs-full-i18n | 1:18.14.2-3.module_el9.2.0+30+e3312493 · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs-libs | 1:16.19.1-2.el9_2 · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs-nodemon | 2.0.20-2.module_el9.2.0+29+de583a0b · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs-packaging | 2021.06-4.module_el9.1.0+13+d9a595ea · AlmaLinux:9 | Package registry (OSV) |
| almalinux:nodejs-packaging-bundler | 2021.06-4.module_el9.1.0+13+d9a595ea · AlmaLinux:9 | Package registry (OSV) |
| almalinux:npm | 1:9.5.0-1.18.14.2.3.module_el9.2.0+30+e3312493 · AlmaLinux:9 | Package registry (OSV) |
| debian:c-ares | 1.19.1-2 · Debian:13 | Package registry (OSV) |
| opensuse:c-ares | 1.19.1-150000.3.23.1 · openSUSE:Leap Micro 5.3 | Package registry (OSV) |
| opensuse:nodejs16 | 16.20.1-150400.3.21.1 · openSUSE:Leap 15.4 | Package registry (OSV) |
| opensuse:nodejs18 | 18.16.1-150400.9.9.1 · openSUSE:Leap 15.4 | Package registry (OSV) |
| red hat:nodejs | 1:18.14.2-3.module+el9.2.0.z+18964+42696395 · Red Hat:enterprise_linux:9::appstream | Package registry (OSV) |
| red hat:nodejs-debuginfo | 1:18.14.2-3.module+el9.2.0.z+18964+42696395 · Red Hat:enterprise_linux:9::appstream | Package registry (OSV) |
| red hat:nodejs-debugsource | 1:18.14.2-3.module+el9.2.0.z+18964+42696395 · Red Hat:enterprise_linux:9::appstream | Package registry (OSV) |
| red hat:nodejs-devel | 1:18.14.2-3.module+el9.2.0.z+18964+42696395 · Red Hat:enterprise_linux:9::appstream | Package registry (OSV) |
| red hat:nodejs-docs | 1:18.14.2-3.module+el9.2.0.z+18964+42696395 · Red Hat:enterprise_linux:9::appstream | Package registry (OSV) |
+16
Exploit status
No known public exploit
No public exploit has been observed yet. That doesn't mean you're safe, only that the bar is a little higher.
Research context
For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.
Timeline
From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.
No dated events beyond publication.
Not on record for this CVE: EPSS history · patch commit or PR link · researcher credit · variant or chain candidate · public bounty program.
Technical details
Attack conditions
- Anyone who can reach it over the internet can trigger it.
- No account or password is required.
- No user action is required.
- No special conditions are required; it is repeatable.
If successful
- Confidentiality
- low · data can be read
- Integrity
- low · data or configuration can be modified
- Availability
- none
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- None
- Scope
- Unchanged
- Confidentiality impact
- Low
- Integrity impact
- Low
- Availability impact
- None
Weakness class (CWE)
CWE-330 · Use of Insufficiently Random ValuesCVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N
nvd-primary
Attack context
MITRE CAPEC attack patterns and ATT&CK techniques for this weakness class (CWE). A starting point for detection rules and threat hunting.
Change log (1)
- Fix✗ → ✓
For records you follow, these changes also arrive as notifications. →
References
Show all references (4 more)Show less
- github.com/c-ares/c-ares/security/advisories/GHSA-8r8p-23f3-64c2
- lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/B5Z5XFNXTNPTCBBVXFDNZQVLLIE6VRBY/
- lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/UBFWILTA33LOSV23P44FGTQQIDRJHIY7/
- security.gentoo.org/glsa/202310-09
Vendor advisories and official records. Exploit/PoC links are deliberately left out.