CVE-2025-27789:The vulnerability CVE-2025-27789 is related to inefficient RegExp complexity in generated code with .replace when transpiling named capturing groups in Babel versions prior to 7.26.10 and 8.0.0-alpha.17.

splash
Back

Description Preview

Babel, a compiler for next-generation JavaScript, has a vulnerability in versions prior to 7.26.10 and 8.0.0-alpha.17. When these versions are used to compile regular expression named capturing groups, Babel generates a polyfill for the `.replace` method that has quadratic complexity on some specific replacement pattern strings. The generated code is vulnerable if all the following conditions are met: Using Babel to compile regular expression named capturing groups, using the `.replace` method on a regular expression that contains named capturing groups, and the code using untrusted strings as the second argument of `.replace`. This vulnerability has been fixed in `@babel/helpers` and `@babel/runtime` 7.26.10 and 8.0.0-alpha.17.

Overview

The vulnerability is related to inefficient RegExp complexity in generated code with .replace when transpiling named capturing groups. It has a base score of 6.2 and a base severity of medium. The attack complexity is low and the attack vector is local. The availability impact is high, while the confidentiality and integrity impacts are none.

Remediation

The problem has been fixed in @babel/helpers and @babel/runtime 7.26.10 and 8.0.0-alpha.17. Users are advised to upgrade to these versions. Note that just updating Babel dependencies is not enough; one will also need to re-compile the code. No known workarounds are available.

References

  1. GitHub Advisory
  2. GitHub Pull Request

Industry ExposureMost to least
This section illustrates the prevalence of a specific Common Vulnerabilities and Exposures (CVE) across various industries based on customer reports. The ranking displays industries from the most to least affected by this particular vulnerability, offering valuable insight into where this CVE has been most frequently observed. This information can help organizations within these sectors prioritize their security efforts, understand their relative risk exposure compared to their peers, and focus remediation strategies where they are most needed. By understanding the industry-specific impact, organizations can make more informed decisions regarding patching, resource allocation, and overall risk management related to this CVE.

  1. Manufacturing
    Manufacturing
  2. Professional, Scientific, & Technical Services
    Professional, Scientific, & Technical Services
  3. Finance and Insurance
    Finance and Insurance
  4. Public Administration
    Public Administration
  5. Retail Trade
    Retail Trade
  6. Arts, Entertainment & Recreation
    Arts, Entertainment & Recreation
  7. Management of Companies & Enterprises
    Management of Companies & Enterprises
  8. Health Care & Social Assistance
    Health Care & Social Assistance
  9. Transportation & Warehousing
    Transportation & Warehousing
  10. Educational Services
    Educational Services
  11. Other Services (except Public Administration)
    Other Services (except Public Administration)
  12. Accommodation & Food Services
    Accommodation & Food Services
  13. Administrative, Support, Waste Management & Remediation Services
    Administrative, Support, Waste Management & Remediation Services
  14. Agriculture, Forestry Fishing & Hunting
    Agriculture, Forestry Fishing & Hunting
  15. Construction
    Construction
  16. Information
    Information
  17. Mining
    Mining
  18. Real Estate Rental & Leasing
    Real Estate Rental & Leasing
  19. Utilities
    Utilities
  20. Wholesale Trade
    Wholesale Trade

Focus on What Matters

  1. See Everything.
  2. Identify True Risk.
  3. Proactively Mitigate Threats.

Let's talk!

background
Armis Vulnerability Intelligence Database