Critical severity · published Jan 10, 2022
CVE-2022-22817
PIL.ImageMath.eval in Pillow before 9.0.0 allows evaluation of arbitrary expressions, such as ones that use the Python exec method
9.8
CVSS
3.3%
EPSS
No
On KEV
Description
PIL.ImageMath.eval in Pillow before 9.0.0 allows evaluation of arbitrary expressions, such as ones that use the Python exec method. A lambda expression could also be used.
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Confidentiality
High
Integrity
High
Availability
High
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)3.3% · higher than 89% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
DL
Debian Linux · Debian
9.0; 10.0; 11.0 · source: NVD
PI
Pillow · Python
before 9.0.1 · source: NVD
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2022-22817
CVE.org
https://www.cve.org/CVERecord?id=CVE-2022-22817
Mailing List
https://lists.debian.org/debian-lts-announce/2022/01/msg00018.html
lists.debian.org
https://lists.debian.org/debian-lts-announce/2024/03/msg00021.html
Release Notes
https://pillow.readthedocs.io/en/stable/releasenotes/9.0.0.html#restrict-builtins-available-to-imagemath-eval
Release Notes
https://pillow.readthedocs.io/en/stable/releasenotes/9.0.1.html#security
Third Party Advisory
https://security.gentoo.org/glsa/202211-10
Third Party Advisory
https://www.debian.org/security/2022/dsa-5053
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-24061
GNU InetUtils Argument Injection Vulnerability
