HIGH8.8
GHSA-pf6m-fxpq-fg8v
Nokogiri implementation of libxslt lacks integer overflow checks
Quick fix
GHSA-pf6m-fxpq-fg8v — nokogiri: upgrade to the fixed version with the command below.
bundle update nokogiriDetails
The xsltAddTextString function in transform.c in libxslt 1.1.29, as used in Nokogiri prior to 1.7.2, lacked a check for integer overflow during a size calculation, which allowed a remote attacker to perform an out of bounds memory write via a crafted HTML page.
Are you affected?
Enter the version of the package you're using.
Affected packages
References
- https://nvd.nist.gov/vuln/detail/CVE-2017-5029[ADVISORY]
- https://github.com/sparklemotion/nokogiri/issues/1634[WEB]
- https://git.gnome.org/browse/libxslt/commit/?id=08ab2774b870de1c7b5a48693df75e8154addae5[WEB]
- https://github.com/advisories/GHSA-pf6m-fxpq-fg8v[ADVISORY]
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/nokogiri/CVE-2017-5029.yml[WEB]
- https://github.com/sparklemotion/nokogiri[PACKAGE]
- https://ubuntu.com/security/CVE-2017-5029[WEB]
- https://ubuntu.com/security/notices/USN-3271-1[WEB]
Check it before you install it
One call answers whether to add this package: known advisories, CISA KEV, and whether the name is a hallucinated or freshly squatted one. No key needed to try it.
curl -s https://vdb.ai.kr/v1/ai/check-packages \
-H 'Content-Type: application/json' \
-d '{"packages":["pkg:gem/nokogiri"]}'