Skip to content
Heist/ feed
Back to feed
Medium

Cache driver GetBlob() allows read access to any blob without access control check

Type: advisorySources: OSV

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. 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.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2024-39897
Confirmed fixed CVEs
Not specified
Updated in this feed
3 Nov 2026, 07:08 UTC · Revision 1

Source evidence

Cache driver GetBlob() allows read access to any blob without access control check

core-osv · Original source

Published 9 Jul 2024, 18:48 UTC

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. 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.

osv:CVE-2024-39897
Complete source record
{
  "id": "06a565291067be001940ed0d0ef9a0c1b17d47243f8f018c7a4eb23ead9313d9",
  "url": "https://osv.dev/vulnerability/CVE-2024-39897",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Cache driver GetBlob() allows read access to any blob without access control check",
    "summary": "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. 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.",
    "evidence": "osv:CVE-2024-39897",
    "products": [],
    "severity": "medium",
    "structured": {
      "id": "CVE-2024-39897",
      "aliases": [
        "CVE-2024-39897",
        "GHSA-55r9-5mx9-qq7r",
        "GO-2024-2979"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/project-zot/zot",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "e5eacaa082c9fa9f85fb4548841e8dc9f1918590"
                },
                {
                  "fixed": "aaee0220e46bdadd12115ac67c19f9d3153eb1df"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:zotregistry:zot:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "2.1.0"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "range": [
                      {
                        "fixed": "aaee0220e46bdadd12115ac67c19f9d3153eb1df"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v2.1.0-rc2",
            "v2.1.0-rc1",
            "v2.0.4",
            "v2.0.3",
            "v2.0.2-rc3",
            "v2.0.2",
            "v2.0.2-rc2",
            "v2.0.2-rc1",
            "v2.0.1",
            "v2.0.1-rc2",
            "v2.0.1-rc1",
            "v2.0.0-rc8",
            "v2.0.0",
            "v2.0.0-rc7",
            "v2.0.0-rc6",
            "v2.0.0-rc5",
            "v2.0.0-rc4",
            "v2.0.0-rc3",
            "v2.0.0-rc2",
            "v2.0.0-rc1",
            "v1.4.3-rc9",
            "v1.4.3",
            "v1.4.3-rc8",
            "v1.4.3-rc7",
            "v1.4.3-rc6",
            "v1.4.3-rc5",
            "v1.4.3-rc4",
            "v1.4.3-rc3",
            "v1.4.3-rc2",
            "v1.4.3-rc1",
            "v1.4.2",
            "v1.4.2-rc6",
            "v1.4.2-rc5",
            "v1.4.2-rc4",
            "v1.4.2-rc3",
            "v1.4.2-rc2",
            "v1.4.2-rc1",
            "v1.4.1-rc6",
            "v1.4.1",
            "v1.4.1-rc5",
            "v1.4.1-rc4",
            "v1.4.1-rc3",
            "v1.4.1-rc2",
            "v1.4.1-rc1",
            "v1.4.0-rc4",
            "v1.4.0",
            "v1.4.0-rc3",
            "v1.4.0-rc2",
            "v1.4.0-rc1",
            "v1.3.9",
            "v1.3.8",
            "v1.3.8-rc3",
            "v1.3.8-rc2",
            "v1.3.7",
            "v1.3.6",
            "v1.3.5",
            "v1.3.4",
            "v1.3.3",
            "v1.3.2",
            "v1.3.1",
            "v1.3.0",
            "v1.2.8",
            "v1.2.7",
            "v1.2.6",
            "v1.2.5",
            "v1.2.4",
            "v1.2.3",
            "v1.2.2",
            "v1.2.1",
            "v1.2.0",
            "v1.1.14",
            "v1.1.13",
            "v1.1.12",
            "v1.1.11",
            "v1.1.10",
            "v1.1.9",
            "v1.1.8",
            "v1.1.7",
            "v1.1.6",
            "v1.1.5",
            "v1.1.4",
            "v1.1.3",
            "v1.1.2",
            "v1.1.1",
            "v1.1.0",
            "v1.0.1",
            "v1.0.0",
            "v0.3.10",
            "v0.3.9",
            "v0.3.8",
            "v0.3.7",
            "v0.3.6",
            "v0.3.5",
            "v0.3.4",
            "v0.3.3",
            "v0.3.2",
            "v0.3.1",
            "v0.3.0",
            "0.3.0",
            "v0.2.9",
            "v0.2.8",
            "v0.2.7",
            "v0.2.6"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-39897.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:26.996413348Z",
      "provider": "osv",
      "references": [
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/39xxx/CVE-2024-39897.json",
        "https://github.com/project-zot/zot/security/advisories/GHSA-55r9-5mx9-qq7r",
        "https://nvd.nist.gov/vuln/detail/CVE-2024-39897",
        "https://github.com/project-zot/zot/commit/aaee0220e46bdadd12115ac67c19f9d3153eb1df"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-639"
        ],
        "cna_assigner": "GitHub_M",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/39xxx/CVE-2024-39897.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2024-39897",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 493231,
  "published_at": "2024-07-09T18:48:24.335+00:00"
}