{"id":"CVE-2022-22817","details":"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.","aliases":["BIT-pillow-2022-22817","GHSA-8vj2-vxx3-667w","PYSEC-2022-10"],"modified":"2026-04-16T04:30:51.204661571Z","published":"2022-01-10T14:12:55.160Z","related":["ALSA-2022:0643","SUSE-SU-2022:1729-1","SUSE-SU-2024:0290-1","openSUSE-SU-2024:11814-1","openSUSE-SU-2025:14645-1"],"references":[{"type":"WEB","url":"https://lists.debian.org/debian-lts-announce/2024/03/msg00021.html"},{"type":"ADVISORY","url":"https://lists.debian.org/debian-lts-announce/2022/01/msg00018.html"},{"type":"ADVISORY","url":"https://pillow.readthedocs.io/en/stable/releasenotes/9.0.0.html#restrict-builtins-available-to-imagemath-eval"},{"type":"ADVISORY","url":"https://pillow.readthedocs.io/en/stable/releasenotes/9.0.1.html#security"},{"type":"ADVISORY","url":"https://security.gentoo.org/glsa/202211-10"},{"type":"ADVISORY","url":"https://www.debian.org/security/2022/dsa-5053"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/python-pillow/pillow","events":[{"introduced":"0"},{"fixed":"6deac9e3a23caffbfdd75c00d3f0a1cd36cdbd5d"},{"introduced":"0"},{"last_affected":"82541b6dec8452cb612067fcebba1c5a1a2bfdc8"},{"introduced":"0"},{"last_affected":"6e28ed1f36d0eb74053af54e1eddc9c29db698cd"},{"introduced":"0"},{"last_affected":"204aae6682fc936f5350b3fe70335776f81480a7"}],"database_specific":{"versions":[{"introduced":"0"},{"fixed":"9.0.1"},{"introduced":"0"},{"last_affected":"9.0"},{"introduced":"0"},{"last_affected":"10.0"},{"introduced":"0"},{"last_affected":"11.0"}]}}],"versions":["1.0","1.2","1.7.7","1.7.8","10.0.0","10.1.0","10.2.0","10.3.0","10.4.0","11.0.0","2.0.0","2.1.0","2.2.0","2.2.1","2.3.0","2.5.0","2.7.0","2.8.0","2.8.1","2.9.0","2.9.0.dev0","2.9.0.dev1","2.9.0.dev2","3.1.0","3.1.0-rc1","3.2.0","3.3.0","3.4.0","4.0.0","4.0.0a","4.1.0","4.2.0","4.3.0","5.0.0","5.1.0","5.2.0","5.3.0","5.4.0","6.0.0","6.1.0","6.2.0","7.0.0","7.1.0","7.2.0","8.0.0","8.1.0","8.2.0","8.3.0","8.4.0","9.0.0","9.1.0","9.2.0","9.3.0","9.4.0","9.5.0"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2022-22817.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"}]}