{"id":"UBUNTU-CVE-2021-32837","details":"mechanize, a library for automatically interacting with HTTP web servers, contains a regular expression that is vulnerable to regular expression denial of service (ReDoS) prior to version 0.4.6. If a web server responds in a malicious way, then mechanize could crash. Version 0.4.6 has a patch for the issue.","modified":"2025-10-24T04:50:21Z","published":"2023-01-17T22:15:00Z","upstream":["CVE-2021-32837"],"references":[{"type":"REPORT","url":"https://ubuntu.com/security/CVE-2021-32837"},{"type":"REPORT","url":"https://securitylab.github.com/advisories/GHSL-2021-108-python-mechanize-mechanize/"},{"type":"REPORT","url":"https://github.com/python-mechanize/mechanize/blob/3acb1836f3fd8edc5a758a417dd46b53832ae3b5/mechanize/_urllib2_fork.py#L878-L879"},{"type":"REPORT","url":"https://github.com/python-mechanize/mechanize/releases/tag/v0.4.6"},{"type":"REPORT","url":"https://www.cve.org/CVERecord?id=CVE-2021-32837"}],"affected":[{"package":{"name":"python-mechanize","ecosystem":"Ubuntu:16.04:LTS","purl":"pkg:deb/ubuntu/python-mechanize@1:0.2.5-3?arch=source&distro=xenial"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1:0.2.5-3"],"ecosystem_specific":{"binaries":[{"binary_name":"python-clientform","binary_version":"1:0.2.5-3"},{"binary_name":"python-mechanize","binary_version":"1:0.2.5-3"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-32837.json"}},{"package":{"name":"python-mechanize","ecosystem":"Ubuntu:18.04:LTS","purl":"pkg:deb/ubuntu/python-mechanize@1:0.2.5-3?arch=source&distro=bionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1:0.2.5-3"],"ecosystem_specific":{"binaries":[{"binary_name":"python-clientform","binary_version":"1:0.2.5-3"},{"binary_name":"python-mechanize","binary_version":"1:0.2.5-3"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-32837.json"}},{"package":{"name":"python-mechanize","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/python-mechanize@1:0.4.5-2?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1:0.2.5-3","1:0.4.3-2","1:0.4.5-1","1:0.4.5-2"],"ecosystem_specific":{"binaries":[{"binary_name":"python3-mechanize","binary_version":"1:0.4.5-2"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-32837.json"}}],"schema_version":"1.7.3","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"},{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"},{"type":"Ubuntu","score":"medium"}]}