High severity · published Sep 7, 2022
CVE-2022-40023
Sqlalchemy mako before 1.2.2 is vulnerable to Regular expression Denial of Service when using the Lexer class to parse
7.5
CVSS
2.2%
EPSS
No
On KEV
Description
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.
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Confidentiality
None
Integrity
None
Availability
High
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)2.2% · higher than 82% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
DL
Debian Linux · Debian
10.0 · source: NVD
MA
Mako · Sqlalchemy
before 1.2.2 · source: NVD
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2022-40023
CVE.org
https://www.cve.org/CVERecord?id=CVE-2022-40023
Exploit
https://github.com/sqlalchemy/mako/blob/c2f392e0be52dc67d1b9770ab8cce6a9c736d547/mako/ext/extract.py#L21
Patch
https://github.com/sqlalchemy/mako/commit/925760291d6efec64fda6e9dd1fd9cfbd5be068c
Issue Tracking
https://github.com/sqlalchemy/mako/issues/366
Mailing List
https://lists.debian.org/debian-lts-announce/2022/09/msg00026.html
Exploit
https://pyup.io/posts/pyup-discovers-redos-vulnerabilities-in-top-python-packages/
Third Party Advisory
https://pyup.io/vulnerabilities/CVE-2022-40023/50870/
More from Debian Linux
10.0
CVE-2025-32433
Erlang/OTP SSH Vulnerable to Pre-Authentication RCE
10.0
CVE-2025-24201
Apple Multiple Products WebKit Out-of-Bounds Write Vulnerability
10.0
CVE-2021-44228
Apache Log4j2 JNDI features do not protect against attacker controlled LDAP and other JNDI related endpoints
10.0
CVE-2015-3306
ProFTPD Improper Access Control Vulnerability
9.8
CVE-2026-111497
Out-of-Bounds Write in Google Brotli Decoder
