{"id":"CVE-2023-36807","published":"2023-06-30T18:38:10Z","modified":"2024-11-06T19:51:43Z","title":"Infinite Loop when reading malformed objects in pypdf","vendor":"py-pdf","product":"pypdf","tier":"tail","description":{"text":"pypdf is a pure-python PDF library capable of splitting, merging, cropping, and transforming the pages of PDF files. In version 2.10.5 an attacker who uses this vulnerability can craft a PDF which leads to an infinite loop. This infinite loop blocks the current process and can utilize a single core of the CPU by 100%. It does not affect memory usage. That is, for example, the case if the user extracted metadata from such a malformed PDF. Versions prior to 2.10.5 throw an error, but do not hang forever. This issue was fixed with https://github.com/py-pdf/pypdf/pull/1331 which has been included in release 2.10.6. Users are advised to upgrade. Users unable to upgrade should modify `PyPDF2/generic/_data_structures.py::read_object` to an an error throwing case. See GHSA-hm9v-vj3r-r55m for details. ","provenance":"source","from":"CVE.org"},"cvss":{"score":6.2,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00573,"percentile":0.48269,"provenance":"source"},"cwes":[{"id":"CWE-835","name":"Loop with Unreachable Exit Condition"}],"references":[{"url":"https://github.com/py-pdf/pypdf/security/advisories/GHSA-hm9v-vj3r-r55m","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/py-pdf/pypdf/issues/1329","tags":["x_refsource_MISC"]},{"url":"https://github.com/py-pdf/pypdf/pull/1331","tags":["x_refsource_MISC"]}],"priority":{"score":14.0,"factors":[{"name":"EPSS percentile","points":9.65},{"name":"CVSS severity","points":4.34}]},"vendorSlug":"py-pdf","affectedVersions":[{"vendor":"py-pdf","product":"pypdf","versions":["2.10.5"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial","timestamp":"2024-11-06T19:51:03.876776Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"PyPDF2","vulnerableRanges":[">=2.10.5, <2.10.6"],"patched":["2.10.6"],"from":["GHSA-hm9v-vj3r-r55m","PYSEC-2026-1836"],"provenance":"source"}],"summary":{"text":"A flaw in the pypdf Python PDF library (version 2.10.5) causes its object-reading routine to enter an infinite loop when it parses a crafted, malformed PDF object. An attacker who can supply such a PDF to a local process, for example by getting a user to open or extract metadata from it, can hang that process and pin one CPU core at 100%, with no memory impact.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:40:14Z"},"euvd":{"id":"EUVD-2023-1823","exploited":false,"provenance":"source"}}