You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are working on the OCI support in Harbor 2.0 and we will improve the user experience of artifact scanning in this release.
In Harbor 2.0, the vulnerabilities info of the artifact will display in the portal only when the artifact can be scanned by the scanner, and only scannable artifact can click the Scan button in the portal.
Harbor will use the consumes_mime_types of capabilities from scanner metadata to decide whether the artifact supported by the scanner.
Currently, the consumes_mime_types returns by the scanner always be application/vnd.oci.image.manifest.v1+json and application/vnd.docker.distribution.manifest.v2+json. These mime tyeps are the manifest media type of the artifact, and they mean that the scanner support docker image and oci image.
According to the OCI spec the manifest media type of the artifact always application/vnd.oci.image.manifest.v1+json and application/vnd.oci.image.index.v1+json. application/vnd.docker.distribution.manifest.v2+json and application/vnd.docker.distribution.manifest.list.v2+json are also supported for the backwards and forwards compatible.
The result is that the scanner supports to scan all OCI artifacts includes helm chart, regular file and others. This is not true for the scanner. Now in Harbor 2.0 we use a black list to deal this problem, when the type of the artifact in the list, we assert that the artifact is not scannable. It works but what can we do when the scanner support to scan helm chart?
In Harbor 2.0 the manifest media type for helm charts, docker image are application/vnd.oci.image.manifest.v1+json and application/vnd.docker.distribution.manifest.v2+json, but their media type are different. The media type of the helm chart is application/vnd.cncf.helm.config.v1+json and the media type of the docker image is application/vnd.docker.container.image.v1+json. So I suggest to use the artifact media type as consumes_mime_types of capabilities for the scanner.
The text was updated successfully, but these errors were encountered:
We are working on the OCI support in Harbor 2.0 and we will improve the user experience of artifact scanning in this release.
In Harbor 2.0, the vulnerabilities info of the artifact will display in the portal only when the artifact can be scanned by the scanner, and only scannable artifact can click the
Scan
button in the portal.Harbor will use the
consumes_mime_types
of capabilities from scanner metadata to decide whether the artifact supported by the scanner.Currently, the
consumes_mime_types
returns by the scanner always beapplication/vnd.oci.image.manifest.v1+json
andapplication/vnd.docker.distribution.manifest.v2+json
. These mime tyeps are the manifest media type of the artifact, and they mean that the scanner support docker image and oci image.According to the OCI spec the manifest media type of the artifact always
application/vnd.oci.image.manifest.v1+json
andapplication/vnd.oci.image.index.v1+json
.application/vnd.docker.distribution.manifest.v2+json
andapplication/vnd.docker.distribution.manifest.list.v2+json
are also supported for the backwards and forwards compatible.The result is that the scanner supports to scan all OCI artifacts includes
helm chart
,regular file
and others. This is not true for the scanner. Now in Harbor 2.0 we use a black list to deal this problem, when the type of the artifact in the list, we assert that the artifact is not scannable. It works but what can we do when the scanner support to scan helm chart?In Harbor 2.0 the manifest media type for helm charts, docker image are
application/vnd.oci.image.manifest.v1+json
andapplication/vnd.docker.distribution.manifest.v2+json
, but their media type are different. The media type of the helm chart isapplication/vnd.cncf.helm.config.v1+json
and the media type of the docker image isapplication/vnd.docker.container.image.v1+json
. So I suggest to use the artifact media type asconsumes_mime_types
of capabilities for the scanner.The text was updated successfully, but these errors were encountered: