Skip to main content

Inefficient Regular Expression Complexity

CVE-2023-22467

Severity High
Score 7.5/10

Summary

Luxon is a library for working with dates and times in JavaScript. In versions prior to 1.28.1, 2.0.x prior to 2.5.2, and 3.0.x prior to 3.2.1, Luxon's "DateTime.fromRFC2822()" has quadratic (N^2) complexity on some specific inputs. This causes a noticeable slowdown for inputs with lengths above 10k characters. Users providing untrusted data to this method are therefore vulnerable to (Re)DoS attacks. This issue also appears in Moment as CVE-2022-31129. As a workaround, limit the length of the input.

  • LOW
  • NETWORK
  • NONE
  • UNCHANGED
  • NONE
  • NONE
  • NONE
  • HIGH

CWE-1333 - Inefficient Regular Expression Complexity

The product uses a regular expression with an inefficient, possibly exponential worst-case computational complexity that consumes excessive CPU cycles.

References

Advisory Timeline

  • Published