GHSA-5j5w-g665-5m35 json
Ambiguous OCI manifest parsing
published 4y ago modified 2mo ago also GO-2022-0360
- cvss
- 3.0
- version 3.1, GitHub
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- —
- no score, EPSS covers CVEs only
- public exploits
- 0
- none known
Summary
### Impact
In the OCI Distribution Specification version 1.0.0 and prior and in the OCI Image Specification version 1.0.1 and prior, manifest and index documents are ambiguous without an accompanying Content-Type HTTP header. Versions of containerd prior to 1.4.12 and 1.5.8 treat the Content-Type header as trusted and deserialize the document according to that header. If the Content-Type header changed between pulls of the same ambiguous document (with the same digest), the document may be interpreted differently, meaning that the digest alone is insufficient to unambiguously identify the content of the image.
### Patches
This issue has been fixed in containerd 1.4.12 and 1.5.8. Image pulls for manifests that contain a “manifests” field or indices which contain a “layers” field are rejected.
### Workarounds
Ensure you only pull images from trusted sources.
### References
https://github.com/opencontainers/distribution-spec/security/advisories/GHSA-mc8v-mgrf-8f4m https://github.com/opencontainers/image-spec/security/advisories/GHSA-77vh-xpmg-72qh
### For more information If you have any questions or comments about this advisory: * Open an issue in [containerd](https://github.com/containerd/containerd/issues/new/choose) * Email us at [security@containerd.io](mailto:security@containerd.io)
Patch / fix
- go github.com/containerd/containerd 1.4.12, 1.5.8
Is GHSA-5j5w-g665-5m35 in your dependencies? Fencer shows which of your repositories are affected as soon as an advisory lands, and opens the fix as a pull request.
Check with FencerCVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| GitHub | 3.1 | 3.0 | CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:C/C:N/I:L/A:N |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| go | github.com/containerd/containerd | <1.4.12 >=1.5.0, <1.5.8 |
1.4.12 1.5.8 |
Classification
- Weakness
-
- CWE-843 Access of Resource Using Incompatible Type
References
-
github.com
/containerd/containerd/commit/26c76a3014e71af5ad2f396ec76e0e0ecc8e25a3
web, patch
-
github.com
/containerd/containerd/commit/db00065a969a983ceb0a409833f93f705f284ea4
web, patch
-
github.com
/containerd/containerd/security/advisories/GHSA-5j5w-g665-5m35
web, advisory
-
github.com
/opencontainers/distribution-spec/security/advisories/GHSA-mc8v-mgrf-8f4m
web
-
github.com
/opencontainers/image-spec/security/advisories/GHSA-77vh-xpmg-72qh
web
-
github.com
/containerd/containerd
package
-
github.com
/containerd/containerd/releases/tag/v1.4.12
web
-
github.com
/containerd/containerd/releases/tag/v1.5.8
web
Sources
- GitHub Advisory GHSA-5j5w-g665-5m35
- OSV GO-2022-0360
Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.