Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. Mako
  4. ›
  5. CVE-2022-40023

CVE-2022-40023: mako is vulnerable to Regular Expression Denial of Service

September 16, 2022 (updated September 30, 2024)

Sqlalchemy mako before 1.2.2 is vulnerable to Regular expression Denial of Service when using the Lexer class to parse. This also affects babelplugin and linguaplugin.

References

  • github.com/advisories/GHSA-v973-fxgf-6xhp
  • github.com/pypa/advisory-database/tree/main/vulns/mako/PYSEC-2022-260.yaml
  • github.com/sqlalchemy/mako
  • github.com/sqlalchemy/mako/blob/c2f392e0be52dc67d1b9770ab8cce6a9c736d547/mako/ext/extract.py
  • github.com/sqlalchemy/mako/commit/925760291d6efec64fda6e9dd1fd9cfbd5be068c
  • github.com/sqlalchemy/mako/issues/366
  • lists.debian.org/debian-lts-announce/2022/09/msg00026.html
  • nvd.nist.gov/vuln/detail/CVE-2022-40023
  • pyup.io/posts/pyup-discovers-redos-vulnerabilities-in-top-python-packages
  • pyup.io/vulnerabilities/CVE-2022-40023/50870

Code Behaviors & Features

Detect and mitigate CVE-2022-40023 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 1.2.2

Fixed versions

  • 1.2.2

Solution

Upgrade to version 1.2.2 or above.

Impact 7.5 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-1333: Inefficient Regular Expression Complexity

Source file

pypi/Mako/CVE-2022-40023.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:15:00 +0000.