{"id":"CVE-2026-73248","state":"PUBLISHED","title":"calibre: Bypass of Python template restrictions via nested `template()` leading to RCE","description":"calibre is an e-book manager. Prior to 9.12.0, calibre processes attacker-controlled composite_template metadata from a malicious EPUB, OPF, PDF, or similar file through program: and a nested template() call whose formatter does not inherit allow_python_templates=False, allowing a nested python: template to reach compile_python_template and execute arbitrary Python code when the file is opened or imported. This issue is fixed in version 9.12.0.","publishedAt":"2026-08-11T21:56:08.569Z","updatedAt":"2026-08-12T13:52:18.881Z","severity":{"score":8.5,"label":"High","version":"4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","source":"GitHub_M"},"assigner":"GitHub_M","products":["kovidgoyal calibre"],"affected":[{"vendor":"kovidgoyal","product":"calibre","versions":[{"version":"< 9.12.0","status":"affected"}]}],"references":["https://github.com/kovidgoyal/calibre/security/advisories/GHSA-4f7g-rjfp-hmvx","https://github.com/kovidgoyal/calibre/commit/dac9990458374a81a5372a768bba6527d965aac8","https://github.com/kovidgoyal/calibre/releases/tag/v9.12.0"],"weaknesses":["CWE-94","CWE-95"],"ingestedAt":"2026-10-29T20:12:58.252Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/73xxx/CVE-2026-73248.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-73248","state":"PUBLISHED","datePublished":"2026-08-11T21:56:08.569Z","dateUpdated":"2026-08-12T13:52:18.881Z","assignerShortName":"GitHub_M","assignerOrgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateReserved":"2026-08-11T17:18:01.597Z"},"containers":{"cna":{"title":"calibre: Bypass of Python template restrictions via nested `template()` leading to RCE","descriptions":[{"lang":"en","value":"calibre is an e-book manager. Prior to 9.12.0, calibre processes attacker-controlled composite_template metadata from a malicious EPUB, OPF, PDF, or similar file through program: and a nested template() call whose formatter does not inherit allow_python_templates=False, allowing a nested python: template to reach compile_python_template and execute arbitrary Python code when the file is opened or imported. This issue is fixed in version 9.12.0."}],"affected":[{"vendor":"kovidgoyal","product":"calibre","versions":[{"version":"< 9.12.0","status":"affected"}]}],"references":[{"url":"https://github.com/kovidgoyal/calibre/security/advisories/GHSA-4f7g-rjfp-hmvx","name":"https://github.com/kovidgoyal/calibre/security/advisories/GHSA-4f7g-rjfp-hmvx","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/kovidgoyal/calibre/commit/dac9990458374a81a5372a768bba6527d965aac8","name":"https://github.com/kovidgoyal/calibre/commit/dac9990458374a81a5372a768bba6527d965aac8","tags":["x_refsource_MISC"]},{"url":"https://github.com/kovidgoyal/calibre/releases/tag/v9.12.0","name":"https://github.com/kovidgoyal/calibre/releases/tag/v9.12.0","tags":["x_refsource_MISC"]}],"metrics":[{"cvssV4_0":{"attackVector":"LOCAL","attackComplexity":"LOW","attackRequirements":"NONE","privilegesRequired":"NONE","userInteraction":"PASSIVE","vulnConfidentialityImpact":"HIGH","vulnIntegrityImpact":"HIGH","vulnAvailabilityImpact":"HIGH","subConfidentialityImpact":"NONE","subIntegrityImpact":"NONE","subAvailabilityImpact":"NONE","baseScore":8.5,"baseSeverity":"HIGH","vectorString":"CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","version":"4.0"}}],"problemTypes":[{"descriptions":[{"cweId":"CWE-94","lang":"en","description":"CWE-94: Improper Control of Generation of Code ('Code Injection')","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-95","lang":"en","description":"CWE-95: Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')","type":"CWE"}]}],"providerMetadata":{"shortName":"GitHub_M","orgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateUpdated":"2026-08-11T21:56:08.569Z"},"source":{"advisory":"GHSA-4f7g-rjfp-hmvx","discovery":"UNKNOWN"}},"adp":[{"title":"CISA ADP Vulnrichment","references":[{"url":"https://github.com/kovidgoyal/calibre/security/advisories/GHSA-4f7g-rjfp-hmvx","tags":["exploit"]}],"metrics":[{"other":{"type":"ssvc","content":{"timestamp":"2026-08-12T12:41:56.579042Z","id":"CVE-2026-73248","options":[{"Exploitation":"poc"},{"Automatable":"no"},{"Technical Impact":"total"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-08-12T13:52:18.881Z"}}]}}}