Skip to main content

HTML::Bare CVE-2026-57073

| EUVDEUVD-2026-44965 CRITICAL
Out-of-bounds Read (CWE-125)
2026-07-16 CPANSec GHSA-682p-jxjc-9j4v
9.1
CVSS 3.1 · Vendor: CPANSec
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Submit truncated HTML fragment to app
  2. Delivery
    App calls HTML::Bare parserc_parse
  3. Exploit
    Lookahead reads past buffer end
  4. Execution
    Out-of-bounds heap read
  5. Impact
    Crash or leaked memory in output

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, read limits
MITRE ATT&CK

1 technique across 1 tactic: Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that the target application pass attacker-controlled input to HTML::Bare's C parser (parserc_parse). The concrete trigger is a truncated or malformed token: a fragment like "<a/" whose assumed closing '>' is actually the buffer's NUL terminator, or a partial "<![CDATA" sequence at the end of the buffer - either causes lookahead reads at offsets (cpos+7, cpos+8, cpos+2) that fall outside the allocation. Limiting factors: this is a library, not a standalone service, so there are no special product configuration flags - the real prerequisite is a calling application that (a) uses the vulnerable C parse path and (b) parses untrusted, un-length-validated HTML. Impact is bounded by how few bytes past the buffer are read, favoring crashes over large-scale disclosure.

Impact

The provided CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/C:H/I:N/A:H, base 9.1) rates this critical on the assumption that untrusted HTML reaches the parser over the network with no authentication and yields high confidentiality and availability impact. That is plausible for a library embedded in a web-facing service, but the real-world severity is entirely context-dependent: HTML::Bare is a library, so exploitability requires that the consuming application feed attacker-controlled input to the parser - an attack requirement the base score does not capture. The C:H rating is optimistic for a bug that reads a small, bounded number of bytes past the buffer; realistic outcomes are limited heap disclosure and, more reliably, a crash (availability). No EPSS score, KEV listing, or SSVC decision data was provided, and no public exploit was identified - signals that point to lower immediate real-world urgency than the 9.1 suggests. Treat this as a genuine memory-safety defect worth patching, but calibrate priority to whether your deployment actually parses untrusted HTML with this module.

Exploit ScenarioDerived

An application uses HTML::Bare to parse HTML or XML-like content submitted by users - for example an API endpoint or feed processor. An attacker submits a deliberately truncated fragment such as "<a/" or a tag missing its closing '>', causing parserc_parse to read beyond the input buffer and either crash the worker (denial of service) or leak adjacent heap bytes back into parsed output. No public proof-of-concept was identified, but the trigger is trivial to craft and requires only network-delivered input with no authentication.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 17, 2026

Out-of-bounds read in the HTML::Bare Perl parsing module (versions through 0.04) lets an attacker who supplies truncated or malformed HTML - such as the string "<a/" - force the C-based parserc_parse routine to read past the end of the input buffer. Because the parser performs multi-character lookahead for tokens like "<![CDATA" and element terminators ">" without bounds checks, adjacent heap memory can be disclosed or the process can crash. No public exploit was identified at time of analysis, but an upstream fix (GitHub PR #2) and per-version patches are available.

RemediationAI

Patch available per vendor advisory: apply the CPANSec-published fixes rather than waiting for a tagged release - https://security.metacpan.org/patches/H/HTML-Bare/0.02/CVE-2026-57073-r1.patch for CPAN 0.02 and https://security.metacpan.org/patches/H/HTML-Bare/0.04/CVE-2026-57073-r2.patch for the git 0.04 line, both corresponding to upstream fix PR https://github.com/nanoscopic/perl-HTML-Bare/pull/2. Because no fixed version is published to CPAN, this is best described as an upstream fix (PR/patch) rather than an independently confirmed released version, so pin to the patched source or vendor the corrected parser.c into your build. If you cannot patch immediately, the practical compensating control is to stop passing untrusted input to the C parser: validate/size-cap input length and reject truncated tags before parsing, or switch to the pure-Perl parse path if your integration exposes one (trade-off: slower parsing), and isolate any service that parses attacker-controlled HTML so a crash cannot cascade. See the oss-security advisory https://seclists.org/oss-sec/2026/q3/155 for coordination details.

Affected VersionsENISA

HTML::Bare 0 ≤0.04

Affected Packages

euvd html_bare no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

HTML::Bare is a Perl module whose parsing hot-path is implemented in C (parser.c) for speed, exposing it to classic memory-safety bugs. The root cause is CWE-125 (Out-of-Bounds Read): parserc_parse dereferences fixed offsets from the current cursor - e.g. *(cpos+7)/*(cpos+8) when matching "<![CDATA[", and blind cpos+=2 advances that assume the next byte is '>' - without first confirming those offsets fall inside the NUL-terminated buffer. When input is truncated (e.g. "<a/" or a tag whose assumed '>' is actually the NUL terminator), the cursor advances past the string boundary and subsequent reads touch memory beyond the allocation. The CPE cpe:2.3:a:codechild:html::bare identifies the affected package; the fix adds the missing terminator/NUL checks (require the full "<![CDATA[" before skipping 9 bytes, and only skip the assumed '>' when *(cpos+1) is non-NUL).

Know when Html gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (CPANSec) PRIMARY 9.1 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H
vuln.today AI 6.5 MEDIUM

Network-reachable if the app parses untrusted HTML (AV:N/AC:L/PR:N/UI:N), but a small bounded over-read yields only limited disclosure (C:L) and a likely crash (A:L), not high impact.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:L
4.0 AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N

Primary rating from Vendor (CPANSec).

CVSS VectorVendor: CPANSec

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
None
Availability
High

Lifecycle Timeline

3
CVSS changed
Jul 17, 2026 - 13:22 NVD
9.1 (CRITICAL)
CVE Published
Jul 16, 2026 - 16:15 cve.org
UNKNOWN (no severity yet)
CVE Published
Jul 16, 2026 - 16:15 cve.org
CRITICAL 9.1

DescriptionCVE.org

HTML::Bare versions through 0.04 for Perl have an unbounded character lookahead.

The parserc_parse function attempts to check for multicharacter strings such as "<![CDATA" or element terminators such as ">" without checking that the offsets are within the buffer.

Truncated strings such as "<a/" can trigger an out-of-bounds read.

Note that the latest version available on CPAN is version 0.02. Newer versions are available on the git repository.

Executive ViewAI

Why It Matters

HTML::Bare, a Perl HTML parsing module in versions 0.04 and earlier, contains a critical out-of-bounds memory read flaw that could expose sensitive data or crash services. Organizations running applications that parse user-supplied HTML using this library face immediate risks of confidentiality breach and service disruption.

Business Impact: Severe
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.2%
Top 91% exploitable
Prevalence
Low
niche Perl CPAN module, latest CPAN release only 0.02
Social Media
1
Sightings
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Out-of-Cycle
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
Very High
Technical Impact
Total

Priority Score

46
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +46
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy