CVE-2023-31130
Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.
NVD · uneditedc-ares is an asynchronous resolver library. ares_inet_net_pton() is vulnerable to a buffer underflow for certain ipv6 addresses, in particular "0::00:00:00/2" was found to cause an issue. C-ares only uses this function internally for configuration purposes which would require an administrator to configure such an address via ares_set_sortlist(). However, users may externally use ares_inet_net_pton() for other purposes and thus be vulnerable to more severe issues. This issue has been fixed in 1.19.1.
Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.
dbcve analysis · high confidenceThe ares_inet_net_pton() function in c-ares library contains a buffer underflow vulnerability when parsing certain specially crafted IPv6 addresses like '0::00:00:00/2'. This function is primarily used internally for configuring sortlist options via ares_set_sortlist() but may also be called directly by external users.
Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.
Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.
NVD · CPE data= 37= 38= 10.0= 11.0< 1.19.1CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.
From the vector- Attack vector
- Local
- Complexity
- High
- Privileges
- High
- User interaction
- None
- Scope
- Unchanged
- Confidentiality
- High
- Integrity
- High
- Availability
- High
CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:H
Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.
dbcve checksWork through these to decide whether this CVE applies to you.
-
Identify c-ares library installationRun 'pkg-config --modversion c-ares' or check your system's package manager for the installed c-ares version (e.g., 'rpm -q c-ares' on Fedora, 'dpkg -l libc-ares' on Debian)Affected if The installed version is lower than 1.19.1 (e.g., 1.19.0, 1.18.x, or earlier)
-
Locate the c-ares library fileRun 'ldconfig -p | grep c-ares' or search for 'libcares.so' on the system to find the shared library path and confirm c-ares is presentAffected if c-ares library is present on the system and the version cannot be determined or is below 1.19.1
-
Identify applications using ares_set_sortlistSearch application source code for calls to ares_set_sortlist() function, or if using a binary, run 'objdump -T /path/to/binary | grep ares_set_sortlist' or 'nm -D /path/to/binary | grep ares_set_sortlist'Affected if The application calls ares_set_sortlist() and passes IPv6 addresses to it
-
Identify direct usage of ares_inet_net_ptonSearch application source code for direct calls to ares_inet_net_pton(), or run 'objdump -T /path/to/binary | grep ares_inet_net_pton'Affected if The application directly calls ares_inet_net_pton() with IPv6 network addresses
-
Review sortlist configurationIf using ares_set_sortlist(), examine the configuration or input passed to it for any IPv6 addresses in format similar to '0::00:00:00/2' or other crafted IPv6 network addressesAffected if The sortlist configuration contains IPv6 addresses in the problematic format
-
Check for external input handling IPv6 addressesReview how the application processes and validates IPv6 address input from external sources, particularly network addresses with prefix lengthsAffected if Untrusted IPv6 network addresses from external sources are passed to c-ares functions without validation
The environment is affected if c-ares version is below 1.19.1 AND the application uses ares_set_sortlist() or directly calls ares_inet_net_pton() with IPv6 network addresses, especially from untrusted sources.
Generated from the published advisory. Verify against your own configuration.
Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.
dbcve · scoped1.19.1
Upgrade c-ares to version 1.19.1 or later to receive the patch; if immediate upgrading is not feasible, avoid passing untrusted IPv6 network addresses to ares_inet_net_pton().
c-ares version 1.19.1 or later
- Identify the current version of c-ares library installed in your system
- Upgrade c-ares to version 1.19.1 or later
- Verify the upgrade was successful by checking the installed c-ares version
- Rebuild any applications that statically link against c-ares to ensure they use the fixed version
Generated from the published advisory — verify against the referenced sources before acting.
- Consultation1.0 h
- Implementation2.0 h
- Testing2.0 h
- Review / QA1.0 h
An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $1,664.
Scan for this in your stack
Free · runs locallyCheck whether your project pulls in CVE-2023-31130 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.
References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.
Primary sourcesPractitioner notes
ContributedPeer-ranked notes from engineers who’ve handled CVE-2023-31130 in production — separate from our analysis above.
The advisory tells you what broke. It rarely tells you what actually worked. If you’ve dealt with this one, that detail is what the next engineer is searching for.
- The version that genuinely resolved it — not the one the vendor claimed
- A config change or rule that shut the vector down
- A gotcha in the upgrade path that cost you an afternoon
No notes yet
Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.
A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.
- Verified mitigations, workarounds, and config changes
- Version or environment caveats, and links to real fixes
- No weaponised exploit code, or anything meant to cause harm
- No spam, self-promotion, credentials, or personal data