Skip to content
FlawDB
Sign in
Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

CVE-2026-48591

MEDIUM 4.8EPSS 5%

Stored XSS via unescaped HTML attribute values in earmark

Mitigation

  • Vendor workaround: Migrate to a maintained Markdown library such as MDEx (https://hex.pm/packages/mdex). The earmark package has been retired on Hex and no patched release will be made.

Who should check

  • Anyone running pragdave earmark >= 1.4.1, < *
  • Anyone running pragdave earmark >= 8236a0570bd894b50e360da08131ec3294c20799, < *

Vulnerability facts

Affected
pragdave earmark >= 1.4.1, < *; pragdave earmark >= 8236a0570bd894b50e360da08131ec3294c20799, < *
Fixed in
No fix listed yet
Exploited in the wild
Not in CISA KEV
Public exploit / PoC
None known
Remote exploitation
Not remotely exploitable (local or adjacent access needed)
CVSS
4.8 (v4.0, CNA)CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:NOpen in CVSS calculator
Show all 11 CVSS metrics
  • Attack vector: Local
  • Attack complexity: Low
  • Attack requirements: None
  • Privileges required: None
  • User interaction: Passive
  • Confidentiality impact: Low
  • Integrity impact: Low
  • Availability impact: None
  • Confidentiality impact on other systems: Low
  • Integrity impact on other systems: Low
  • Availability impact on other systems: None
EPSS
0.20% chance of exploitation in 30 days (percentile 5, 2026-11-26)
CWE
CWE-83
Published
Modified

Description

Improper Neutralization of Script in Attributes in a Web Page vulnerability in pragdave earmark allows stored cross-site scripting via unescaped HTML attribute values. Earmark.Transform._make_att1/2 in lib/earmark/transform.ex splices attribute values verbatim between two literal " bytes: [" ", name, "=\"" , value, "\""]. Text nodes are routed through the existing escape function which encodes " as &quot;, but attribute values never visit that path. A markdown link whose URL or title contains a bare " closes the attribute early and lets the trailing bytes be parsed by the browser as fresh HTML attributes. For example, [click](http://example.com/?a=x" onerror="alert(1)) renders as <a href="http://example.com/?a=x" onerror="alert(1)">click</a>, executing arbitrary JavaScript in the victim's browser. The earmark library is no longer maintained and has been retired on Hex. No patched version will be released. All releases from 1.4.1 onward are affected, and users should migrate to a maintained Markdown library such as MDEx. This issue affects earmark: from 1.4.1 onward.

Affected and fixed versions

Package / productAffectedFixedSource
pragdave earmark>= 1.4.1, < *—cvelist
pragdave earmark>= 8236a0570bd894b50e360da08131ec3294c20799, < *—cvelist

Check your systems with an agent

Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.

Check whether anything I run is affected by CVE-2026-48591. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-48591.md
Affected: pragdave earmark >= 1.4.1, < *; pragdave earmark >= 8236a0570bd894b50e360da08131ec3294c20799, < *
Fixed in: no fixed version listed yet

Steps:
1. Search this machine and project for pragdave earmark: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.

References

FAQ

Is CVE-2026-48591 being exploited?

There is no confirmed exploitation: CVE-2026-48591 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.20% chance of exploitation in the next 30 days (as of 2026-11-26).

How serious is CVE-2026-48591?

Medium: CVSS 4.8 (v4.0, scored by CNA). Not remotely exploitable (local or adjacent access needed). A user has to take an action, such as opening a link, for the attack to work.

Which versions are affected by CVE-2026-48591?

pragdave earmark >= 1.4.1, < *; pragdave earmark >= 8236a0570bd894b50e360da08131ec3294c20799, < *.

Is there a fix for CVE-2026-48591?

No fixed version is listed in the sources yet. Vendor workaround: Migrate to a maintained Markdown library such as MDEx (https://hex.pm/packages/mdex). The earmark package has been retired on Hex and no patched release will be made.

How do I check if I'm affected by CVE-2026-48591?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

Sponsors