Register for the AI for Security Summit: Join Figma, Perplexity & Wiz

CVE-2023-31124
npm vulnerability analysis and mitigation

Overview

CVE-2023-31124 affects c-ares, an asynchronous resolver library. The vulnerability was discovered in versions prior to 1.19.1 and disclosed on May 22, 2023. The issue occurs when cross-compiling c-ares using the autotools build system, specifically when cross-compiling for aarch64 android, where CARES_RANDOM_FILE is not set (GitHub Advisory).

Technical details

The vulnerability stems from a build system configuration issue where CARES_RANDOM_FILE is not properly set during cross-compilation. This results in the system falling back to using rand() instead of a Cryptographically Secure Pseudo-Random Number Generator (CSPRNG). The vulnerability has been assigned a CVSS v3.1 base score of 3.7 LOW, with a vector of CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:N. The weakness has been categorized as CWE-330 (Use of Insufficiently Random Values) (GitHub Advisory).

Impact

The vulnerability could allow an attacker to take advantage of the lack of entropy by not using a CSPRNG, potentially compromising the security of DNS operations when the library is cross-compiled (GitHub Advisory).

Exploitability

The vulnerability requires high attack complexity and can be exploited remotely without requiring privileges or user interaction. The scope is unchanged, with no impact on confidentiality, low impact on integrity, and no impact on availability (GitHub Advisory).

Mitigation and workarounds

The vulnerability has been patched in c-ares version 1.19.1. As a workaround, users can use the CMake build system instead of autotools. Various distributions have released security updates, including Fedora 37 and 38, and Gentoo (Fedora Update, Gentoo Advisory).

Community reactions

The vulnerability was discovered during a security audit of c-ares performed by X41 D-SEC GmbH, which was funded by the Open Source Technology Improvement Fund (OSTIF). The audit findings led to prompt security patches and updates across multiple distributions (GitHub Release).

Additional resources


SourceThis report was generated using AI

Related npm vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-73566HIGH7.5
  • JavaScript logoJavaScript
  • node-red-5
NoYesAug 13, 2026
CVE-2026-56848HIGH7.5
  • npm logonpm
  • nodejs:26::nodejs-full-i18n
NoYesAug 04, 2026
CVE-2026-58045MEDIUM6.2
  • npm logonpm
  • nodejs:24::nodejs-packaging
NoYesAug 04, 2026
CVE-2026-58042MEDIUM5.9
  • npm logonpm
  • corepack22
NoYesAug 04, 2026
CVE-2026-58044LOW3.7
  • npm logonpm
  • nodejs:24::nodejs.src
NoYesAug 04, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management