-
Notifications
You must be signed in to change notification settings - Fork 2k
docs: cosign kms docs #5808
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
docs: cosign kms docs #5808
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,71 @@ | ||
| --- | ||
| title: "Sigstore Cosign Integration" | ||
| description: "Sign and verify container images and artifacts using Infisical KMS with Sigstore Cosign." | ||
| --- | ||
|
|
||
| Infisical KMS integrates with [Sigstore Cosign](https://github.com/sigstore/cosign) through the [sigstore-kms-infisical](https://github.com/Infisical/sigstore-kms-infisical) plugin, enabling you to sign and verify container images and artifacts using keys managed in Infisical. | ||
|
|
||
| ### KMS Plugin Capabilities | ||
|
|
||
| | Capability | Supported | | ||
| | ---------- | --------- | | ||
| | DefaultAlgorithm | RSA_4096 | | ||
| | SupportedAlgorithms | RSA_4096, ECC_NIST_P256 | | ||
| | CreateKey | ✅ | | ||
| | PublicKey | ✅ | | ||
| | SignMessage | ✅ | | ||
| | VerifyMessage | ✅ | | ||
|
|
||
| ## Setup | ||
|
|
||
| <Steps> | ||
| <Step title="Install the Plugin"> | ||
| For the Sigstore library to invoke the plugin, the binary must be in your system's `PATH`. | ||
|
|
||
| ```bash | ||
| git clone https://github.com/Infisical/sigstore-kms-infisical.git | ||
| cd sigstore-kms-infisical | ||
| go build -o sigstore-kms-infisical | ||
| cp sigstore-kms-infisical /usr/local/bin | ||
| ``` | ||
|
varonix0 marked this conversation as resolved.
|
||
| </Step> | ||
|
|
||
| <Step title="Configure Environment Variables"> | ||
| The plugin uses environment variables for authentication. Currently only [Machine Identity Universal Auth](/documentation/platform/identities/universal-auth) is supported. | ||
|
|
||
| Set the following environment variables: | ||
|
|
||
| ```bash | ||
| export INFISICAL_SITE_URL="https://app.infisical.com" | ||
| export INFISICAL_UNIVERSAL_AUTH_CLIENT_ID="<machine-identity-client-id>" | ||
| export INFISICAL_UNIVERSAL_AUTH_CLIENT_SECRET="<machine-identity-client-secret>" | ||
| export INFISICAL_PROJECT_ID="<infisical-kms-project-id>" | ||
| ``` | ||
|
|
||
| <Note> | ||
| For self-hosted Infisical instances, set `INFISICAL_SITE_URL` to your instance's URL. | ||
| </Note> | ||
| </Step> | ||
| </Steps> | ||
|
|
||
| ## Usage | ||
|
|
||
| ### Signing a Container Image | ||
|
|
||
| ```bash | ||
| cosign sign --key "infisical://{KMS_KEY_NAME}" --tlog-upload=false my-repo/image:v1 | ||
| ``` | ||
|
|
||
| ### Verifying a Container Image | ||
|
|
||
| ```bash | ||
| cosign verify --key "infisical://{KMS_KEY_NAME}" --insecure-ignore-tlog=true my-repo/image:v1 | ||
| ``` | ||
|
|
||
| ### Creating a New Key Pair | ||
|
|
||
| ```bash | ||
| cosign generate-key-pair --kms infisical://{NEW_KEY_NAME} | ||
|
varonix0 marked this conversation as resolved.
|
||
| ``` | ||
|
|
||
| This creates an RSA 4096 KMS key with the specified name, which you can then use for signing and verification. | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.