CVE-2017-9050 Out-of-bounds read in nokogiri

High 7.5 Published Updated

A heap-based buffer over-read in libxml2 allows attackers to cause a denial of service via crafted XML input, affecting applications like PHP.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2017-9050?

CVE-2017-9050 is a high-severity memory corruption vulnerability in Xmlsoft Libxml2, published on 18 May 2017. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

libxml2 20904-GITv2.9.4-16-g0741801 is vulnerable to a heap-based buffer over-read in the xmlDictAddString function in dict.c. This vulnerability causes programs that use libxml2, such as PHP, to crash. This vulnerability exists because of an incomplete fix for CVE-2016-1839.

Weakness: CWE-125, CWE-122

Which versions are affected by CVE-2017-9050?

2 open source packages ship an affected version, including nokogiri. It affects 1 product.

PackageAffectedFixed in
nokogiri RubyGemsAll versions1.8.1
nokogiri RubyGemsAll versions1.8.1

Products include Xmlsoft Libxml2.

How do I fix CVE-2017-9050?

Upgrade nokogiri to 1.8.1 or later.

Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.

Is CVE-2017-9050 being exploited?

There is no known exploitation of CVE-2017-9050 in the wild and no public exploit code.

All Xmlsoft Libxml2 vulnerabilities

Sources

Also known as DEBIAN-CVE-2017-9050, ECHO-671f-1ea4-e79b, GHSA-8c56-cpmw-89x7, UBUNTU-CVE-2017-9050.

Is CVE-2017-9050 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free