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
// Taken from https://issues.redhat.com/browse/OCPSTRAT-918
20
-
* You have a sigstore-supported public key infrastructure (PKI) or a link:https://docs.sigstore.dev/cosign/[Cosign public and private key pair] for signing operations.
20
+
* You have a sigstore-supported public key infrastructure (PKI) key, a Bring Your Own Public Key Infrastructure (BYOPKI) certificate, or provide a link:https://docs.sigstore.dev/cosign/signing/overview/[Cosign public and private key pair] for signing operations.
21
21
* You have a signing process in place to sign your images.
22
22
* You have access to a registry that supports Cosign signatures, if you are using Cosign signatures.
23
23
* If registry mirrors are configured for the {product-title} release image repositories, `quay.io/openshift-release-dev/ocp-release` and `quay.io/openshift-release-dev/ocp-v4.0-art-dev`, before enabling the Technology Preview feature set, you must mirror the sigstore signatures for the {product-title} release images into your mirror registry. Otherwise, the default `openshift` cluster image policy, which enforces signature verification for the release repository, blocks the ability of the Cluster Version Operator to move the CVO pod to new nodes, preventing the node update that results from the feature set change.
* If you are using a BYOPKI certificate as the root of trust, you enabled the required Technology Preview features for your cluster by editing the `FeatureGate` CR named `cluster`:
34
+
+
35
+
[source,terminal]
36
+
----
37
+
$ oc edit featuregate cluster
38
+
----
39
+
+
40
+
.Example `FeatureGate` CR
41
+
[source,yaml]
42
+
----
43
+
apiVersion: config.openshift.io/v1
44
+
kind: FeatureGate
45
+
metadata:
46
+
name: cluster
47
+
spec:
48
+
featureSet: TechPreviewNoUpgrade <1>
49
+
----
50
+
<1> Enables the required `SigstoreImageVerificationPKI` feature.
51
+
+
52
+
[WARNING]
53
+
====
54
+
Enabling the `TechPreviewNoUpgrade` feature set on your cluster cannot be undone and prevents minor version updates. This feature set allows you to enable these Technology Preview features on test clusters, where you can fully test them. Do not enable this feature set on production clusters.
55
+
====
56
+
33
57
.Procedure
34
58
35
59
. Create a cluster image policy object similar to the following examples. See "About image policy parameters" for specific details on these parameters.
@@ -58,7 +82,7 @@ spec:
58
82
<2> Defines a list of repositories or images assigned to this policy. In a cluster image policy, make sure that the policy does not block the deployment of the {product-title} images in the `quay.io/openshift-release-dev/ocp-release` and `quay.io/openshift-release-dev/ocp-v4.0-art-dev` repositories. Images in these repositories are required for cluster operation.
59
83
<3> Specifies the parameters that define how the images are verified.
60
84
<4> Defines a root of trust for the policy.
61
-
<5> Specifies the policy types that define the root of trust, either a public keyor a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certifice]. Here, a public key with Rekor verification.
85
+
<5> Specifies the policy types that define the root of trust, either a public key, a BYOPKI certificate, or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. This example uses a public key with Rekor verification.
62
86
<6> For a public key policy, specifies a base64-encoded public key in the PEM format. The maximum length is 8192 characters.
63
87
<7> Optional: Specifies a base64-encoded Rekor public key in the PEM format. The maximum length is 8192 characters.
64
88
<8> Optional: Specifies one of the following processes to verify the identity in the signature and the actual image identity:
@@ -69,6 +93,41 @@ spec:
69
93
--
70
94
+
71
95
--
96
+
.Example cluster image policy object for a BYOPKI policy and the `MatchRepository` match policy
<2> Defines a list of repositories or images assigned to this policy. In a cluster image policy, make sure that the policy does not block the deployment of the {product-title} images in the `quay.io/openshift-release-dev/ocp-release` and `quay.io/openshift-release-dev/ocp-v4.0-art-dev` repositories. Images in these repositories are required for cluster operation.
120
+
<3> Specifies the parameters that define how the images are verified.
121
+
<4> Defines a root of trust for the policy.
122
+
<5> Specifies the policy types that define the root of trust, either a public key, a BYOPKI certificate, or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. This example uses a BYOPKI certificate.
123
+
<6> For a BYOPKI certificate, specify `caRootsData`. This parameter specifies a base64-encoded CA root certificate in the PEM format. The maximum length is 8192 characters. Optionally with `caIntermediatesData`, specifies a base64-encoded intermediate CA root certificate in the PEM format. The maximum length is 8192 characters.
124
+
<7> Specifies a subject alternative name (SAN) to authenticate the user’s identity by using a hostname and an email address:
125
+
* `email`. Specifies the email address specified when the certificate was generated.
126
+
* `hostname`. Specifies the hostname specified when the certificate was generated.
127
+
<8> For a BYOPKI certificate, specify the `MatchRepository` parameter to verify the identity in the signature and the actual image identity. The default signed identity is `matchRepoDigestOrExact`, which requires a digest reference in the signature identity for verification. The signature identity in this case uses a repository reference, and does not include the image digest.
128
+
--
129
+
+
130
+
--
72
131
.Example cluster image policy object with a Fulcio certificate policy and the `remapIdentity` match policy
73
132
[source,yaml]
74
133
----
@@ -98,7 +157,7 @@ spec:
98
157
<2> Defines a list of repositories or images assigned to this policy. In a cluster image policy, make sure that the policy does not block the deployment of the {product-title} images in the `quay.io/openshift-release-dev/ocp-release` and `quay.io/openshift-release-dev/ocp-v4.0-art-dev` repositories. Images in these repositories are required for cluster operation.
99
158
<3> Specifies the parameters that define how the images are verified.
100
159
<4> Defines a root of trust for the policy.
101
-
<5> Specifies the policy types that define the root of trust, either a public keyor a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. Here, a Fulcio certificate with required Rekor verification.
160
+
<5> Specifies the policy types that define the root of trust, either a public key, a BYOPKI certificate, or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. This example uses a Fulcio certificate with required Rekor verification.
102
161
<6> For a Fulcio certificate policy, the following parameters are required:
103
162
* `fulcioCAData`: Specifies a base64-encoded Fulcio certificate in the PEM format. The maximum length is 8192 characters.
104
163
* `fulcioSubject`: Specifies the OIDC issuer and the email of the Fulcio authentication configuration.
@@ -119,7 +178,7 @@ spec:
119
178
$ oc create -f <file_name>.yaml
120
179
----
121
180
+
122
-
The Machine Config Operator (MCO) updates the machine config pools (MCP) in your cluster.
181
+
The Machine Config Operator (MCO) updates the machine config pools (MCP) in your cluster. Scheduling on each node is disabled as the change is being applied.
Copy file name to clipboardExpand all lines: modules/nodes-sigstore-configure-image-policy.adoc
+87-3Lines changed: 87 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,9 +17,32 @@ The following example shows general guidelines on how to configure an `ImagePoli
17
17
18
18
.Prerequisites
19
19
// Taken from https://issues.redhat.com/browse/OCPSTRAT-918
20
-
* You have a sigstore-supported public key infrastructure (PKI) or provide link:https://docs.sigstore.dev/cosign/[Cosign public and private key pair] for signing operations.
20
+
* You have a sigstore-supported public key infrastructure (PKI) key, a Bring Your Own Public Key Infrastructure (BYOPKI) certificate, or provide a link:https://docs.sigstore.dev/cosign/signing/overview/[Cosign public and private key pair] for signing operations.
21
21
* You have a signing process in place to sign your images.
22
22
* You have access to a registry that supports Cosign signatures, if you are using Cosign signatures.
23
+
* If you are using a BYOPKI certificate as the root of trust, you enabled the required Technology Preview features for your cluster by editing the `FeatureGate` CR named `cluster`:
24
+
+
25
+
[source,terminal]
26
+
----
27
+
$ oc edit featuregate cluster
28
+
----
29
+
+
30
+
.Example `FeatureGate` CR
31
+
[source,yaml]
32
+
----
33
+
apiVersion: config.openshift.io/v1
34
+
kind: FeatureGate
35
+
metadata:
36
+
name: cluster
37
+
spec:
38
+
featureSet: TechPreviewNoUpgrade <1>
39
+
----
40
+
<1> Enables the required `SigstoreImageVerification` feature.
41
+
+
42
+
[WARNING]
43
+
====
44
+
Enabling the `TechPreviewNoUpgrade` feature set on your cluster cannot be undone and prevents minor version updates. This feature set allows you to enable these Technology Preview features on test clusters, where you can fully test them. Do not enable this feature set on production clusters.
45
+
====
23
46
24
47
.Procedure
25
48
@@ -51,7 +74,7 @@ spec:
51
74
<3> Defines a list of repositories or images assigned to this policy.
52
75
<4> Specifies the parameters that define how the images are verified.
53
76
<5> Defines a root of trust for the policy.
54
-
<6> Specifies the policy types that define the root of trust, either a public key or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. Here, a public key with Rekor verification.
77
+
<6> Specifies the policy types that define the root of trust, either a public key, a BYOPKI certificate, or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. Here, a public key with Rekor verification.
55
78
<7> For a public key policy, specifies a base64-encoded public key in the PEM format. The maximum length is 8192 characters.
56
79
<8> Optional: Specifies a base64-encoded Rekor public key in the PEM format. The maximum length is 8192 characters.
57
80
<9> Optional: Specifies one of the following processes to verify the identity in the signature and the actual image identity:
@@ -62,6 +85,44 @@ spec:
62
85
--
63
86
+
64
87
--
88
+
.Example image policy object for a BYOPKI policy and the `MatchRepository` match policy
<2> Specifies the namespace where the image policy is applied.
113
+
<3> Defines a list of repositories or images assigned to this policy.
114
+
<4> Specifies the parameters that define how the images are verified.
115
+
<5> Defines a root of trust for the policy.
116
+
<6> Specifies the policy types that define the root of trust, either a public key, a BYOPKI certificate, or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. Here, a BYOPKI certificate.
117
+
<7> For a BYOPKI certificate, specify `caRootsData`. This parameter specifies a base64-encoded CA root certificate in the PEM format. The maximum length is 8192 characters. Optionally with `caIntermediatesData`, specifies a base64-encoded intermediate CA root certificate in the PEM format. The maximum length is 8192 characters.
118
+
<8> Specifies a subject alternative name (SAN) to authenticate the user’s identity by using a hostname and an email address:
119
+
* `email`. Specifies the email address specified when the certificate was generated.
120
+
* `hostname`. Specifies the hostname specified when the certificate was generated.
121
+
<9> For a BYOPKI certificate, specify `MatchRepository` to verify the identity in the signature and the actual image identity. The default signed identity is `matchRepoDigestOrExact`, which requires digest specification. The signature in this case was not created for digested image.
122
+
--
123
+
// <9> is from the test case: https://polarion.engineering.redhat.com/polarion/#/project/OSE/workitem?id=OCP-83752
124
+
+
125
+
--
65
126
.Example image policy object with a Fulcio certificate policy and the `ExactRepository` match policy
66
127
[source,yaml]
67
128
----
@@ -92,7 +153,7 @@ spec:
92
153
<3> Defines a list of repositories or images assigned to this policy.
93
154
<4> Specifies the parameters that define how the images are verified.
94
155
<5> Defines a root of trust for the policy.
95
-
<6> Specifies the policy types that define the root of trust, either a public key or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. Here, a Fulcio certificate with required Rekor verification.
156
+
<6> Specifies the policy types that define the root of trust, either a public key, a BYOPKI certificate, or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate]. Here, a Fulcio certificate with required Rekor verification.
96
157
<7> For a Fulcio certificate policy, the following parameters are required:
97
158
* `fulcioCAData`: Specifies a base64-encoded Fulcio certificate in the PEM format. The maximum length is 8192 characters.
98
159
* `fulcioSubject`: Specifies the OIDC issuer and the email of the Fulcio authentication configuration.
Copy file name to clipboardExpand all lines: modules/nodes-sigstore-configure.adoc
+7-1Lines changed: 7 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -65,8 +65,14 @@ If multiple scopes match a single scope in the same a cluster or image policy, t
65
65
If a scoped image or repository in an image policy is nested under one of the scoped images or repositories in a cluster image policy, only the policy from cluster image policy is applied. However, the image policy object is created. For example, if an image policy specifies `example.com/global/image`, and the cluster image policy specifies `example.com/global`, the namespace inherits the policy from the cluster image policy.
66
66
67
67
`policy`:: Contains configuration to allow images from the sources listed in `scopes` to be verified, and defines how images not matching the verification policy are treated. You must configure a `rootOfTrust` and optionally, a `signedIdentity`.
68
-
* `rootOfTrust`: Specifies the root of trust for the policy. Configure either a public key or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate].
68
+
* `rootOfTrust`: Specifies the root of trust for the policy. Configure either a public key, a Bring Your Own Public Key Infrastructure (BYOPKI) certificate, or a link:https://docs.sigstore.dev/certificate_authority/overview/[Fulcio certificate].
69
69
** `publicKey`: Indicates that the policy relies on a sigstore public key. You must specify a base64-encoded PEM format public key. You can optionally include link:https://docs.sigstore.dev/logging/overview/[Rekor verification].
70
+
** `PKI` Indicates that the policy relies on a certificate from your own public key infrastructure (PKI) that is compatible with Cosign Bring Your Own Public Key Infrastructure (BYOPKI) verification. You must specify a base64-encoded PEM format public key. BYOPKI enables you to validate container images using an existing X.509 certificate while aligning with Cosign's bring-your-own PKI signing workflow.
71
+
+
72
+
--
73
+
:FeatureName: sigstore BYOPKI support
74
+
include::snippets/technology-preview.adoc[]
75
+
--
70
76
** `FulcioCAWithRekor`: Indicates that the policy is based on a Fulcio certificate. You must specify the following parameters:
0 commit comments