{"answers":{"affected":"6 open source packages ship an affected version, including zotregistry.dev/zot and zotregistry.io/zot. It affects 1 product.","exploited":"There is no known exploitation of CVE-2024-39897 in the wild and no public exploit code.","fix":"Upgrade zotregistry.dev/zot to 2.1.0 or later.","what":"CVE-2024-39897 is a medium-severity missing authorization vulnerability in project-zot zot, published on 9 Jul 2024. Any signed-in user can exploit it over the network, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2024-39897 and fix it if it is affected.\n\nWhat it is: CVE-2024-39897 is a medium-severity missing authorization vulnerability in project-zot zot, published on 9 Jul 2024. Any signed-in user can exploit it over the network, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2024-39897 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- zotregistry.dev/zot (Go): affected all versions; no fix listed\n- zotregistry.dev/zot (Go): affected all versions; fixed in 2.1.0\n- zotregistry.dev/zot (Go): affected all versions; fixed in 2.1.0\n- zotregistry.io/zot (Go): affected all versions; no fix listed\n- zotregistry.io/zot (Go): affected all versions; fixed in 2.1.0\n- zotregistry.io/zot (Go): affected all versions; fixed in 2.1.0\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-2024-39897/ (Markdown: https://insights.sbomify.com/CVE-2024-39897/index.md)","id":"CVE-2024-39897","markdown":"https://insights.sbomify.com/CVE-2024-39897/index.md","name":"CVE-2024-39897","record":{"aliases":["GHSA-55r9-5mx9-qq7r","GO-2024-2979"],"analysis":{"component_type":"server_software","fix_type":"upgrade","impacts":["data_read"],"network_reachable":"yes","non_default_config":false,"product_category":"OCI image registry","requires_auth":"low_privilege","summary":"Attackers can read restricted blobs from other repositories via the cache driver if deduplication is enabled, bypassing access controls.","user_interaction":"not_required","vuln_class":"missing_authorization"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"zot","vendor":"zotregistry"}],"cvss":{"score":4.3,"severity":"medium","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N","version":"3.1"},"cwes":[{"id":"CWE-639","name":"Authorization Bypass Through User-Controlled Key"}],"description":"zot is an OCI image registry. Prior to 2.1.0, the cache driver `GetBlob()` allows read access to any blob without access control check. If a Zot `accessControl` policy allows users read access to some repositories but restricts read access to other repositories and `dedupe` is enabled (it is enabled by default), then an attacker who knows the name of an image and the digest of a blob (that they do not have read access to), they may maliciously read it via a second repository they do have read access to. \n This attack is possible because [`ImageStore.CheckBlob()` calls `checkCacheBlob()`](https://github.com/project-zot/zot/blob/v2.1.0-rc2/pkg/storage/imagestore/imagestore.go#L1158-L1159) to find the blob a global cache by searching for the digest. If it is found, it is copied to the user requested repository with `copyBlob()`. The attack may be mitigated by configuring \"dedupe\": false in the \"storage\" settings. The vulnerability is fixed in 2.1.0.","ecosystems":["Go"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"Cache driver GetBlob() allows read access to any blob without access control check","id":"CVE-2024-39897","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Go","product":null,"products":[],"type":"missing_authorization","year":"2024"},"n_packages":6,"n_references":2,"next":{"headline":"PrivateBin allows shortening of URLs for other domains","id":"CVE-2024-39899"},"packages":[{"ecosystem":"Go","fixed":[],"introduced":["0"],"last_affected":[],"package":"zotregistry.dev/zot","purl":"pkg:golang/zotregistry.dev/zot","source":"GO-2024-2979"},{"ecosystem":"Go","fixed":["2.1.0"],"introduced":["0"],"last_affected":[],"package":"zotregistry.dev/zot","purl":null,"source":"GHSA-55r9-5mx9-qq7r"},{"ecosystem":"Go","fixed":["2.1.0"],"introduced":["0"],"last_affected":[],"package":"zotregistry.dev/zot","purl":"pkg:golang/zotregistry.dev/zot","source":"GHSA-55r9-5mx9-qq7r"},{"ecosystem":"Go","fixed":[],"introduced":["0"],"last_affected":[],"package":"zotregistry.io/zot","purl":"pkg:golang/zotregistry.io/zot","source":"GO-2024-2979"},{"ecosystem":"Go","fixed":["2.1.0"],"introduced":["0"],"last_affected":[],"package":"zotregistry.io/zot","purl":null,"source":"GHSA-55r9-5mx9-qq7r"},{"ecosystem":"Go","fixed":["2.1.0"],"introduced":["0"],"last_affected":[],"package":"zotregistry.io/zot","purl":"pkg:golang/zotregistry.io/zot","source":"GHSA-55r9-5mx9-qq7r"}],"prev":{"headline":"Directus allows SSO User Enumeration","id":"CVE-2024-39896"},"products":["zot"],"published":"2024-07-09","related":[{"cvss_score":7.7,"headline":"zot create-only policy allows overwrite attempts of existing latest tag (update permission not required)","id":"CVE-2026-31801","kev_date_added":null,"published":"2026-03-10"},{"cvss_score":7.3,"headline":"IdP group membership revocation ignored in zot","id":"CVE-2025-23208","kev_date_added":null,"published":"2025-01-17"}],"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":"Go Vulnerability Database","prefix":"GO"},{"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":"none","technical_impact":"partial"},"state":"PUBLISHED","updated":"2024-08-02","vendors":["project-zot"]},"summary":"Attackers can read restricted blobs from other repositories via the cache driver if deduplication is enabled, bypassing access controls.","url":"https://insights.sbomify.com/CVE-2024-39897/"}