Junglewise Threat Intelligence

@asymmetric-effort/nogginlessdom ReDoS via unvalidated regex in HTMLInputElement

Severity: medium · CVSS 4 · Published 2026-07-02

Technologies: @asymmetric-effort/nogginlessdom (npm), Asymmetric Effort Nogginlessdom. Vendors: npm, Asymmetric Effort.

Executive brief

@asymmetric-effort/nogginlessdom is a JavaScript library that provides DOM element validation. The library's HTMLInputElement.checkValidity() method constructs regular expressions directly from user-controlled input patterns without sanitization, allowing an attacker to craft malicious regex patterns that cause catastrophic backtracking and freeze the application's event loop, resulting in a denial of service.

Technical details

This is a Regular Expression Denial of Service (ReDoS) vulnerability in the HTMLInputElement.checkValidity() method. The vulnerable component directly constructs a RegExp object from the user-controlled pattern property without sanitization or timeout protection, enabling an attacker to inject patterns with nested quantifiers (e.g., (a+)+) that trigger exponential backtracking. The attack requires no authentication or special privileges; any caller of checkValidity() with an attacker-controlled pattern can exploit this. A successful exploit freezes the event loop, causing the application to become unresponsive. The vulnerability was patched in version 0.0.22 by adding a 1024-character pattern length limit and nested quantifier detection that rejects dangerous patterns before regex compilation.

Affected products

  • asymmetric-effort nogginlessdom <= 0.0.21

Timeline

  • 2026-07-02: disclosed: Advisory GHSA-x4hg-hfwf-p9mw published
  • 2026-07-02: patched: Fix released in version 0.0.22 with pattern length limit and nested quantifier detection

References

Related threats