{"answers":{"affected":"3 open source packages ship an affected version, including guarddog. It affects 1 product.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2022-23530 exists.","fix":"Upgrade guarddog to 0.1.8 or later.","what":"CVE-2022-23530 is a medium-severity path traversal vulnerability in DataDog guarddog, published on 16 Dec 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2022-23530 and fix it if it is affected.\n\nWhat it is: CVE-2022-23530 is a medium-severity path traversal vulnerability in DataDog guarddog, published on 16 Dec 2022. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2022-23530 exists.\n\nAffected packages and fixed versions:\n- guarddog (PyPI): affected all versions; fixed in 0.1.8\n- guarddog (PyPI): affected all versions; fixed in 0.1.8\n- guarddog (PyPI): affected all versions; fixed in 0.1.8\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2022-23530/ (Markdown: https://insights.sbomify.com/CVE-2022-23530/index.md)","id":"CVE-2022-23530","markdown":"https://insights.sbomify.com/CVE-2022-23530/index.md","name":"CVE-2022-23530","record":{"aliases":["GHSA-78m5-jpmf-ch7v","PYSEC-2022-42993"],"analysis":{"component_type":"developer_tool","fix_type":"upgrade","impacts":["data_modify"],"network_reachable":"yes","non_default_config":false,"product_category":"Python security scanner","requires_auth":"none","summary":"An attacker can overwrite arbitrary files on the system by tricking a user into scanning a malicious PyPI package with GuardDog.","user_interaction":"required","vuln_class":"path_traversal"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"guarddog","vendor":"datadoghq"}],"cvss":{"score":5.8,"severity":"medium","source":"cna","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:L","version":"3.1"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"}],"description":"GuardDog is a CLI tool to identify malicious PyPI packages. Versions prior to v0.1.8 are vulnerable to arbitrary file write when scanning a specially-crafted remote PyPI package. Extracting files using shutil.unpack_archive() from a potentially malicious tarball without validating that the destination file path is within the intended destination directory can cause files outside the destination directory to be overwritten.  This issue is patched in version 0.1.8. Potential workarounds include using a safer module, like zipfile, and validating the location of the extracted files and discarding those with malicious paths.","ecosystems":["PyPI"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"weaponised"},"has_fix":true,"headline":"GuardDog vulnerable to arbitrary file write when scanning a specially-crafted remote PyPI package","id":"CVE-2022-23530","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"PyPI","product":null,"products":[],"type":"path_traversal","year":"2022"},"n_packages":3,"n_references":3,"next":{"headline":"Arbitrary file write when scanning a specially-crafted local PyPI package","id":"CVE-2022-23531"},"packages":[{"ecosystem":"PyPI","fixed":["0.1.8"],"introduced":["0"],"last_affected":[],"package":"guarddog","purl":null,"source":"GHSA-78m5-jpmf-ch7v"},{"ecosystem":"PyPI","fixed":["0.1.8"],"introduced":["0"],"last_affected":[],"package":"guarddog","purl":"pkg:pypi/guarddog","source":"GHSA-78m5-jpmf-ch7v"},{"ecosystem":"PyPI","fixed":["0.1.8"],"introduced":["0"],"last_affected":[],"package":"guarddog","purl":"pkg:pypi/guarddog","source":"PYSEC-2022-42993"}],"prev":{"headline":"DO NOT USE THIS CANDIDATE NUMBER.","id":"CVE-2022-23529"},"products":["guarddog"],"published":"2022-12-16","related":[{"cvss_score":8.7,"headline":"GuardDog Path Traversal Vulnerability Leads to Arbitrary File Overwrite and RCE","id":"CVE-2026-22871","kev_date_added":null,"published":"2026-01-13"},{"cvss_score":7.1,"headline":"GuardDog Zip Bomb Vulnerability in safe_extract() Allows DoS","id":"CVE-2026-22870","kev_date_added":null,"published":"2026-01-13"},{"cvss_score":5.8,"headline":"Arbitrary file write when scanning a specially-crafted local PyPI package","id":"CVE-2022-23531","kev_date_added":null,"published":"2022-12-16"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CC BY 4.0","name":"PyPA Advisory Database","prefix":"PYSEC"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"partial"},"state":"PUBLISHED","updated":"2025-04-17","vendors":["DataDog"]},"summary":"An attacker can overwrite arbitrary files on the system by tricking a user into scanning a malicious PyPI package with GuardDog.","url":"https://insights.sbomify.com/CVE-2022-23530/"}