{"id":64291,"date":"2025-06-03T18:32:12","date_gmt":"2025-06-03T15:02:12","guid":{"rendered":"https:\/\/afaghhosting.net\/blog\/cve-2025-4330-python-tarfile-symlink-extraction-vulnerability\/"},"modified":"2025-06-03T18:32:12","modified_gmt":"2025-06-03T15:02:12","slug":"cve-2025-4330-python-tarfile-symlink-extraction-vulnerability","status":"publish","type":"post","link":"https:\/\/afaghhosting.net\/blog\/cve-2025-4330-python-tarfile-symlink-extraction-vulnerability\/","title":{"rendered":"CVE-2025-4330 &#8211; Python Tarfile Symlink Extraction Vulnerability"},"content":{"rendered":"<p><strong>CVE ID : <\/strong>CVE-2025-4330<br \/>\n<br \/>\n<strong>Published : <\/strong> June 3, 2025, 1:15 p.m. | 1\u00a0hour, 14\u00a0minutes ago<br \/>\n<br \/>\n<strong>Description : <\/strong>Allows the extraction filter to be ignored, allowing symlink targets to point outside the destination directory, and the modification of some file metadata.<\/p>\n<p>You are affected by this vulnerability if using the tarfile\u00a0module to extract untrusted tar archives using TarFile.extractall()\u00a0or TarFile.extract()\u00a0using the filter=\u00a0parameter with a value of &#8220;data&#8221;\u00a0or &#8220;tar&#8221;. See the tarfile  extraction filters documentation https:\/\/docs.python.org\/3\/library\/tarfile.html#tarfile-extraction-filter \u00a0for more information. Only Python versions 3.12 or later are affected by these vulnerabilities, earlier versions don&#8217;t include the extraction filter feature.<\/p>\n<p>Note that for Python 3.14 or later the default value of filter=\u00a0changed from &#8220;no filtering&#8221; to `&#8221;data&#8221;, so if you are relying on this new default behavior then your usage is also affected.<\/p>\n<p>Note that none of these vulnerabilities significantly affect the installation of source distributions which are tar archives as source distributions already allow arbitrary code execution during the build process. However when evaluating source distributions it&#8217;s important to avoid installing source distributions with suspicious links.<br \/>\n<br \/>\n<strong>Severity:<\/strong> 7.5 | HIGH<br \/>\n<br \/>\nVisit the link for more details, such as CVSS details, affected products, timeline, and more&#8230;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>CVE ID : CVE-2025-4330 Published : June 3, 2025, 1:15 p.m. | 1\u00a0hour, 14\u00a0minutes ago Description : Allows the extraction filter to be ignored, allowing symlink targets to point outside the destination directory, and the modification of some file metadata. You are affected by this vulnerability if using the tarfile\u00a0module to extract untrusted tar archives &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[26],"tags":[],"class_list":["post-64291","post","type-post","status-publish","format-standard","hentry","category-vulnerability"],"_links":{"self":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/64291","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/comments?post=64291"}],"version-history":[{"count":0,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/64291\/revisions"}],"wp:attachment":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/media?parent=64291"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/categories?post=64291"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/tags?post=64291"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}