CVE catalog

CVE-2026-57236

Nokogiri is an open source XML and HTML library for the Ruby programming language. Prior to 1.19.4, calling Document#encoding= with an invalid encoding (e.g., a non-string, or a string containing a nu

[CVE catalog]

Severity
Medium · CVSS 6.5CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:H
Published
Source
[NVD] · [CVE record]
EPSS
0.43% · Oct 25, 2026

Nokogiri is an open source XML and HTML library for the Ruby programming language. Prior to 1.19.4, calling Document#encoding= with an invalid encoding (e.g., a non-string, or a string containing a null byte) raises an exception, but only after freeing the document's current encoding string without replacing it. The document is left referencing freed memory, so the next call to Document#encoding reads invalid memory, which can cause a segfault or leak freed bytes into a Ruby String. Affects the CRuby (libxml2) implementation only; JRuby is not affected. This vulnerability is fixed in 1.19.4.

Vulnerable and fixed packages

Distribution-reported package versions and fixes. These do not depend on matching against the OpenFactory package catalog.

DistributionPackageReleaseVersionStatus
Debianruby-nokogirisid1.19.4+dfsg-1fixed
Debianruby-nokogiriforky1.19.4+dfsg-1fixed
Debianruby-nokogiritrixie1.18.2+dfsg-1vulnerable
Debianruby-nokogiribookworm1.13.10+dfsg-2vulnerable
Cperuby-nokogiriNot reportedNot reportedvulnerable
CpenokogiriNot reported1.19.4fixed
CpenokogiriNot reported1.19.4fixed

Fixed-version evidence

DistributionPackageTypeReleaseFixed versionUrgencyOriginBugs
Debianruby-nokogirisourcesid1.19.4+dfsg-1not yet assignedNot reported[1140769]
Debianruby-nokogirisourceforky1.19.4+dfsg-1not yet assignedNot reported[1140769]
Debianruby-nokogirisourcetrixie(unfixed)not yet assignedNot reported[1140769]
Debianruby-nokogirisourcebookworm(unfixed)not yet assignedNot reported[1140769]
CpenokogiricpeNot reported1.19.4Not reportedNot reportedNot reported
CpenokogiricpeNot reported1.19.4Not reportedNVD-CVE-2026-57236Not reported

[Debian bug #1140769]

Notes

[trixie] ruby-nokogiri: Minor issue [bookworm] ruby-nokogiri: Minor issue

OpenFactory catalog packages

[Debian 12 (Bookworm)]

  • [ruby-nokogiri]Affected

    Source package: [ruby-nokogiri]

    Details (2)
    • 1.13.10+dfsg-2+b1 · amd64 · bookworm

      Affected

      nvd · ruby-nokogiri · debian · bookworm; nvd · ruby-nokogiri · debian · 12

    • 1.13.10+dfsg-2+b1 · arm64 · bookworm

      Affected

      nvd · ruby-nokogiri · debian · bookworm; nvd · ruby-nokogiri · debian · 12

[Debian 13 (Trixie)]

  • [ruby-nokogiri]Affected

    Source package: [ruby-nokogiri]

    Details (2)
    • 1.18.2+dfsg-1+b1 · amd64 · trixie

      Affected

      nvd · ruby-nokogiri · debian · 13

    • 1.18.2+dfsg-1+b1 · arm64 · trixie

      Affected

      nvd · ruby-nokogiri · debian · 13

Observed:

References