Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.
TypeScript acmeagentsai-agentscertificate-managementdevsecopsenvironment-variableskubernetesopen-sourcepampkipostgresprivate-caprivileged-access-managementsecret-managementsecret-managersecretssecrets-managementsecuritysecurity-toolsvault
docs(kms): overhaul section (#8686)
Adrian Kahali95464d25ee3f
diff --git a/docs/docs.json b/docs/docs.jsonindex 732f8ec921..aa5d2ad45f 100644--- a/docs/docs.json+++ b/docs/docs.json@@ -612,17 +612,31 @@"icon": "lock","pages": ["documentation/platform/kms/overview",+ "documentation/platform/kms/concepts",{- "group": "Infisical KMS",+ "group": "Key management",+ "pages": [+ "documentation/platform/kms/keys",+ "documentation/platform/kms/encrypt-decrypt",+ "documentation/platform/kms/sign-verify",+ "documentation/platform/kms/mac",+ "documentation/platform/kms/key-rotation",+ "documentation/platform/kms/export-import"+ ]+ },+ {+ "group": "KMIP",+ "pages": [+ "documentation/platform/kms/kmip",+ "documentation/platform/kms/kmip-server",+ "documentation/platform/kms/kmip-clients",+ "documentation/platform/kms/kmip-dell-poweredge"+ ]+ },+ {+ "group": "Integrations","pages": ["documentation/platform/kms/kubernetes-encryption",- {- "group": "KMIP integration",- "pages": [- "documentation/platform/kms/kmip",- "documentation/platform/kms/kmip-dell-poweredge"- ]- },"documentation/platform/kms/sigstore-cosign"]}diff --git a/docs/documentation/getting-started/choose-a-product/kms.mdx b/docs/documentation/getting-started/choose-a-product/kms.mdxindex 031bfbbc69..c1aa28143d 100644--- a/docs/documentation/getting-started/choose-a-product/kms.mdx+++ b/docs/documentation/getting-started/choose-a-product/kms.mdx@@ -13,10 +13,10 @@ Infisical KMS is a key management service that stores cryptographic keys and per## Use cases<CardGroup cols={2}>- <Card title="Encrypt and decrypt with a KMS key" icon="lock" href="/documentation/platform/kms/overview">+ <Card title="Encrypt and decrypt with a KMS key" icon="lock" href="/documentation/platform/kms/encrypt-decrypt">Encrypt sensitive data by reference to a key that never leaves Infisical.</Card>- <Card title="Sign and verify with a KMS key" icon="pen-tool" href="/documentation/platform/kms/overview">+ <Card title="Sign and verify with a KMS key" icon="pen-tool" href="/documentation/platform/kms/sign-verify">Sign payloads with an asymmetric key managed centrally, and verify signatures without holding the key.</Card><Card title="Back the root key with an HSM" icon="cpu" href="/self-hosting/guides/hsm-integration">diff --git a/docs/documentation/getting-started/quickstarts.mdx b/docs/documentation/getting-started/quickstarts.mdxindex 53c783438f..a47465a1d4 100644--- a/docs/documentation/getting-started/quickstarts.mdx+++ b/docs/documentation/getting-started/quickstarts.mdx@@ -86,7 +86,7 @@ mode: "frame"| [Back Infisical KMS with an HSM](/self-hosting/guides/hsm-integration) | Use a hardware security module to protect the root key. || [Encrypt Kubernetes secrets with Infisical KMS](/documentation/platform/kms/kubernetes-encryption) | Use Infisical KMS as the encryption provider for Kubernetes secrets. || [Sign container images with Cosign](/documentation/platform/kms/sigstore-cosign) | Use a key from Infisical KMS to sign and verify container images with Cosign. |-| [Serve keys through KMIP](/documentation/platform/kms/kmip) | Expose keys from Infisical KMS to KMIP clients. |+| [Serve keys through KMIP](/documentation/platform/kms/kmip-server) | Expose keys from Infisical KMS to KMIP clients. |</section>diff --git a/docs/documentation/platform/kms/concepts.mdx b/docs/documentation/platform/kms/concepts.mdxnew file mode 100644index 0000000000..43723f545e--- /dev/null+++ b/docs/documentation/platform/kms/concepts.mdx@@ -0,0 +1,41 @@+---+title: "Key management"+sidebarTitle: "Concepts"+description: "Learn how a key management service keeps keys out of your applications."+---++## What is a key management service?++A _key management service_ (KMS) stores cryptographic keys in one place and runs operations with them, such as encryption and signing, for the applications that need them. An application tells the KMS which key to use and sends the data to process, and gets back the result. The key itself never reaches the application.++If an application stores its own keys, the keys end up in configuration files, container images, and backups, and anyone who can read one of those copies can use the key. Rotating the key means updating every one of those copies. With a KMS, each key exists in one place, and you control and audit who can use it.++## Keys in Infisical KMS++You [create keys](/documentation/platform/kms/keys) in a KMS project. Each key has a usage, which decides the operations the key supports:++- **Encrypt/Decrypt**: [Encrypt and decrypt data](/documentation/platform/kms/encrypt-decrypt) with an AES key+- **Sign/Verify**: [Sign data and verify signatures](/documentation/platform/kms/sign-verify) with an asymmetric key pair+- **Generate/Verify MAC**: [Generate and verify message authentication codes (MACs)](/documentation/platform/kms/mac), which show that data hasn't changed since the MAC was generated++You can't change a key's usage or algorithm after you create the key.++Infisical doesn't store the data you send it. It runs the operation and returns the result.++## Keeping key material inside Infisical++Applications refer to a key by its ID, so they don't need the key material. If a key's key material must never leave Infisical, turn off **Allow Export** when you create the key. No one can export that key, whatever their permissions, and you can't turn export back on later. To learn how to export keys that allow it, see [Export and import keys](/documentation/platform/kms/export-import).++Infisical encrypts every key with a root key. If you self-host Infisical, you can keep the root key in a [hardware security module (HSM)](/self-hosting/guides/hsm-integration).++## Key versions++Each key starts at version 1. When you [rotate a key](/documentation/platform/kms/key-rotation), Infisical creates new key material and increases the version, but the key keeps its ID and name, so your applications don't need to change. Infisical keeps every earlier version, so it can still decrypt data that was encrypted before the rotation.++## Using keys from other tools++Besides the Infisical UI and API, you can use Infisical KMS keys from:++- [KMIP](/documentation/platform/kms/kmip) clients, such as storage arrays and databases that manage their own encryption+- [Kubernetes](/documentation/platform/kms/kubernetes-encryption), to encrypt Kubernetes secrets at rest+- [Sigstore Cosign](/documentation/platform/kms/sigstore-cosign), to sign container imagesdiff --git a/docs/documentation/platform/kms/encrypt-decrypt.mdx b/docs/documentation/platform/kms/encrypt-decrypt.mdxnew file mode 100644index 0000000000..be632b6851--- /dev/null+++ b/docs/documentation/platform/kms/encrypt-decrypt.mdx@@ -0,0 +1,100 @@+---+title: "Encrypt and decrypt data"+sidebarTitle: "Encrypt and decrypt"+description: "Encrypt and decrypt data with a key in Infisical KMS."+---++To encrypt data, send it to Infisical with an Encrypt/Decrypt key, and Infisical returns the ciphertext. To read the data again, send the ciphertext back with the same key. Infisical doesn't store your data or the ciphertext.++## Prerequisites++- An [Encrypt/Decrypt key](/documentation/platform/kms/keys#create-a-key)+- The **Member** role to follow the UI steps, or the **Cryptographic Operator** role to follow the API steps (see [Who can use a key](/documentation/platform/kms/keys#who-can-use-a-key))++## Encrypt data++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the key's row, then select **Encrypt Data**.+ </Step>+ <Step>+ Enter your data in **Data (Plaintext)**. If your data is already Base64 encoded, turn on **Data is Base64 encoded**.+ </Step>+ <Step>+ Select **Encrypt**, then copy the ciphertext from **Encrypted Data (Ciphertext)**.+ </Step>+ </Steps>+ </Tab>+ <Tab title="API">+ Base64 encode your data, then call [the encrypt endpoint](/api-reference/endpoints/kms/encryption/encrypt) with the key's ID:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/encrypt \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "plaintext": "SGVsbG8sIFdvcmxkIQ=="+ }'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>++ The response contains the ciphertext:++ ```json+ {+ "ciphertext": "<base64-encoded-ciphertext>"+ }+ ```+ </Tab>+</Tabs>++## Decrypt data++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the row of the key that encrypted the data, then select **Decrypt Data**.+ </Step>+ <Step>+ Paste the ciphertext into **Encrypted Data (ciphertext)**. If the data you encrypted was plain text, turn on **Decode Base64**, so Infisical shows the text instead of its Base64 encoding.+ </Step>+ <Step>+ Select **Decrypt**, then copy your data from **Decrypted Data (plaintext)**.+ </Step>+ </Steps>+ </Tab>+ <Tab title="API">+ Call [the decrypt endpoint](/api-reference/endpoints/kms/encryption/decrypt) with the ID of the key that encrypted the data:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/decrypt \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "ciphertext": "<base64-encoded-ciphertext>"+ }'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>++ The response contains your data, Base64 encoded:++ ```json+ {+ "plaintext": "SGVsbG8sIFdvcmxkIQ=="+ }+ ```+ </Tab>+</Tabs>++If you [rotated the key](/documentation/platform/kms/key-rotation) after you encrypted the data, Infisical still decrypts it with the key version that encrypted it.diff --git a/docs/documentation/platform/kms/export-import.mdx b/docs/documentation/platform/kms/export-import.mdxnew file mode 100644index 0000000000..8fdb813641--- /dev/null+++ b/docs/documentation/platform/kms/export-import.mdx@@ -0,0 +1,134 @@+---+title: "Export and import keys"+description: "Move key material in and out of Infisical KMS."+---++You can export a key's key material to back it up, or to move the key to another project or Infisical instance. To move keys in, import them from a JSON file.++You can export a key only if **Allow Export** was turned on when the key was created. Keys that you can't export show a lock icon in the key list.++<Warning>+ An export contains the key material in plain text. Anyone who has the file can use the keys, so store it as carefully as the keys themselves.+</Warning>++## Export one key++<Note>+ To export keys, you need the **Admin** role in the KMS project, or a [custom role](/documentation/platform/access-controls/role-based-access-controls) that can export keys.+</Note>++<Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the key's row, then select **Export Key**.+ </Step>+ <Step>+ Copy or download the key material. For a Sign/Verify key, you can also copy or download the public key.+ </Step>+</Steps>++To get a key's private key or key material through the API, call [the private key endpoint](/api-reference/endpoints/kms/keys/private-key).++A Sign/Verify key's public key isn't secret, so any member who can see the key can get its public key, even if the key doesn't allow export. To get the public key through the API, call [the public key endpoint](/api-reference/endpoints/kms/keys/public-key).++## Export several keys++<Note>+ To export keys, you need the **Admin** role in the KMS project, or a custom role that can export keys.+</Note>++You can export up to 100 keys into one JSON file. You can't select disabled keys, or keys that don't allow export.++<Steps>+ <Step>+ In your KMS project, go to **Overview** and select the checkbox on each key's row.+ </Step>+ <Step>+ Select **Export** in the bar above the table.+ </Step>+</Steps>++Infisical downloads a file named `kms-keys-export-<date>.json`. To export keys through the API, call [the bulk export endpoint](/api-reference/endpoints/kms/keys/bulk-export-private-keys).++## Import keys++<Note>+ To import keys, you need the **Admin** or **Member** role in the KMS project, or a custom role that can create keys.+</Note>++<Steps>+ <Step>+ In your KMS project, go to **Overview** and select **Add Key** > **Import Keys**.+ </Step>+ <Step>+ Upload a JSON file in the [import file format](#import-file-format).+ </Step>+ <Step>+ Check the keys in the preview, then select **Import**. The button shows the number of keys, such as **Import 3 Keys**.+ </Step>+</Steps>++Infisical imports every key it can, and lists the keys it couldn't import. If the project already has a key with the same name, Infisical doesn't import that key, and doesn't change the existing key.++Every imported key starts at version 1, so ciphertexts encrypted with an earlier version of the key on another instance can't be decrypted with the imported key.++## Import file format++An import file is a JSON array of up to 100 keys, in the same format as an export file:++```json+[+ {+ "name": "my-aes-key",+ "keyType": "encrypt-decrypt",+ "algorithm": "aes-256-gcm",+ "keyMaterial": "<base64-encoded-key-material>"+ },+ {+ "name": "my-rsa-key",+ "keyType": "sign-verify",+ "algorithm": "RSA_4096",+ "privateKey": "<base64-encoded-private-key>"+ },+ {+ "name": "my-hmac-key",+ "keyType": "generate-verify-mac",+ "algorithm": "HMAC_SHA_256",+ "keyMaterial": "<base64-encoded-key-material>",+ "isExportable": false+ }+]+```++Each key in the file has the following fields:++<ResponseField name="name" type="string" required>+The key's name, made of lowercase letters, numbers, and hyphens, up to 32 characters.+</ResponseField>++<ResponseField name="keyType" type="string" required>+`encrypt-decrypt`, `sign-verify`, or `generate-verify-mac`.+</ResponseField>++<ResponseField name="algorithm" type="string" required>+One of the [algorithms](/documentation/platform/kms/keys#choosing-an-algorithm) for the key type.+</ResponseField>++<ResponseField name="keyMaterial" type="string">+For an Encrypt/Decrypt or Generate/Verify MAC key, the key material, Base64 encoded. An Encrypt/Decrypt key must be 16 or 32 bytes, and a Generate/Verify MAC key must be 16 to 1024 bytes.+</ResponseField>++<ResponseField name="privateKey" type="string">+For a Sign/Verify key, the private key in PKCS#8 format, Base64 encoded.++<Note>+Use PEM encoding for an RSA, ECC, or Ed25519 key, and DER encoding for an ML-DSA key. Infisical derives the public key from the private key, so you don't need to include `publicKey`.+</Note>+</ResponseField>++<ResponseField name="isExportable" type="boolean" default="true">+Set to `false` to stop anyone from exporting the imported key. You can't change this after the import.+</ResponseField>++<ResponseField name="hasDeleteProtection" type="boolean" default="false">+Set to `true` to protect the imported key from deletion.+</ResponseField>diff --git a/docs/documentation/platform/kms/key-rotation.mdx b/docs/documentation/platform/kms/key-rotation.mdxnew file mode 100644index 0000000000..30d36f40c3--- /dev/null+++ b/docs/documentation/platform/kms/key-rotation.mdx@@ -0,0 +1,54 @@+---+title: "Rotate keys"+description: "Replace a key's key material without changing your applications."+---++When you rotate a key, Infisical creates new key material for it and increases the key's version by one. The key keeps its ID and name, so your applications keep working without any changes:++- Infisical encrypts new data with the new key material+- Infisical keeps every earlier version of the key material, and decrypts each ciphertext with the version that encrypted it+- Infisical doesn't re-encrypt data you encrypted before the rotation. To move that data to the new key material, decrypt the data and encrypt it again++You can rotate only Encrypt/Decrypt keys. To replace a Sign/Verify or Generate/Verify MAC key, create a new key and update your applications to use it.++<Warning>+ Only Infisical has the earlier versions of the key material. If a system keeps its own copy of the key material, it gets only the new version after the rotation, and can't decrypt data it encrypted with an earlier version:++ - **KMIP clients**: Don't rotate a key that a [KMIP client](/documentation/platform/kms/kmip) uses. Create a new key for the client instead+ - **Exported keys**: An export contains only the current version. If you keep exported key material as a backup, [export the key](/documentation/platform/kms/export-import) again after each rotation, and keep every export+</Warning>++## Prerequisites++- An [Encrypt/Decrypt key](/documentation/platform/kms/keys#create-a-key) that isn't disabled+- The **Admin** or **Member** role in the key's project++## Rotate a key++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the key's row, then select **Rotate Key**.+ </Step>+ <Step>+ Type `confirm`, then select **Rotate**.+ </Step>+ </Steps>++ The key's **Version** column shows the new version.+ </Tab>+ <Tab title="API">+ Call [the rotate key endpoint](/api-reference/endpoints/kms/keys/rotate) with the key's ID:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/rotate \+ --header 'Authorization: Bearer <access-token>'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>+ </Tab>+</Tabs>diff --git a/docs/documentation/platform/kms/keys.mdx b/docs/documentation/platform/kms/keys.mdxnew file mode 100644index 0000000000..90f601af34--- /dev/null+++ b/docs/documentation/platform/kms/keys.mdx@@ -0,0 +1,114 @@+---+title: "Create and manage keys"+description: "Create the keys that your applications use."+---++Every key in Infisical KMS belongs to a KMS project. To see a project's keys, open the project and go to **Overview**.++## Prerequisites++- A KMS project where you have the **Admin** or **Member** role (to create a project, go to **KMS** in your organization and select **New Project**)++## Create a key++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview** and select **Add Key** > **Create Key**.+ </Step>+ <Step>+ Fill in the fields:++ - **Name**: A name made of lowercase letters, numbers, and hyphens, up to 32 characters+ - **Key Usage**: The operations the key supports (see [Choosing an algorithm](#choosing-an-algorithm))+ - **Algorithm**: The algorithm the key uses+ - **Description (optional)**: What the key is for+ - **Allow Export**: Whether members with the export permission can export the key material (you can't change this after you create the key)+ - **Delete Protection**: Whether the key is protected from deletion+ </Step>+ <Step>+ Select **Add Key**.+ </Step>+ </Steps>+ </Tab>+ <Tab title="API">+ Call [the create key endpoint](/api-reference/endpoints/kms/keys/create) with the project ID, a name, the key usage, and the algorithm:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "projectId": "<project-id>",+ "name": "my-secret-key",+ "keyUsage": "encrypt-decrypt",+ "algorithm": "aes-256-gcm"+ }'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>++ To create a key that can't be exported, add `"isExportable": false`. To protect the key from deletion, add `"hasDeleteProtection": true`.++ The response includes the key's `id`, which you pass to every other KMS endpoint. To look up a key's ID from its name, call [the get key by name endpoint](/api-reference/endpoints/kms/keys/get-by-name).+ </Tab>+</Tabs>++## Choosing an algorithm++Each key usage supports the following algorithms:++| Key usage | API value | Algorithms |+| --- | --- | --- |+| Encrypt/Decrypt | `encrypt-decrypt` | AES-256-GCM (default), AES-128-GCM |+| Sign/Verify | `sign-verify` | RSA-4096 (default), ECC-NIST-P256, ECC-NIST-P384, ECC-NIST-P521, ED25519, ML-DSA-44, ML-DSA-65, ML-DSA-87 |+| Generate/Verify MAC | `generate-verify-mac` | HMAC-SHA-256 (default), HMAC-SHA-384, HMAC-SHA-512, HMAC-SHA-1, HMAC-SHA-224 |++- ECC-NIST-P384 and ECC-NIST-P521 are available only through the API+- ML-DSA is a post-quantum signature algorithm, and is available under Infisical's [Enterprise](https://infisical.com/pricing) plan+- HMAC-SHA-1 and HMAC-SHA-224 are marked **Legacy** in Infisical, so use them only if another system requires them++## Who can use a key++A project's roles decide what each member and machine identity can do with its keys:++| Role | Can do |+| --- | --- |+| **Admin** | Everything, including exporting key material |+| **Member** | Everything except exporting key material |+| **Viewer** | See keys, but not use them |+| **Cryptographic Operator** | Use keys for encryption, signing, and MACs through the API, but not see, create, or change them |++Give an application's [machine identity](/documentation/platform/identities/machine-identities) the **Cryptographic Operator** role, so the application can use your keys but can't change them. To set up your own permissions, create a [custom role](/documentation/platform/access-controls/role-based-access-controls).++## Edit a key++To change a key's name, description, or **Delete Protection** setting, select the options menu on the key's row, then select **Edit Key**. You can't change a key's usage, algorithm, or **Allow Export** setting.++## Disable a key++If you disable a key, Infisical rejects every operation with the key, and you can't export the key until you enable it again. To disable a key, select the options menu on the key's row, then select **Disable Key**. To enable the key again, select **Enable Key**.++## Delete a key++<Warning>+ If you delete a key, you can't decrypt data that was encrypted with it, or verify data that was signed with it. You can't recover a deleted key.+</Warning>++<Steps>+ <Step>+ If the key has **Delete Protection** turned on, select the options menu on the key's row, select **Edit Key**, turn off **Delete Protection**, and select **Update Key**.+ </Step>+ <Step>+ Select the options menu on the key's row, then select **Delete Key**.+ </Step>+ <Step>+ Type `confirm`, then select **Delete**.+ </Step>+</Steps>++If you delete a KMS project, Infisical deletes every key in it, including keys with **Delete Protection** turned on.diff --git a/docs/documentation/platform/kms/kmip-clients.mdx b/docs/documentation/platform/kms/kmip-clients.mdxnew file mode 100644index 0000000000..d7dc596451--- /dev/null+++ b/docs/documentation/platform/kms/kmip-clients.mdx@@ -0,0 +1,94 @@+---+title: "Connect KMIP clients"+description: "Connect a KMIP client to the keys in a KMS project."+---++Each KMIP client is registered in one KMS project, and can use only that project's keys. The client authenticates to the [KMIP server](/documentation/platform/kms/kmip-server) with a certificate that Infisical issues for it.++## Prerequisites++- A running [KMIP server](/documentation/platform/kms/kmip-server)+- A KMS project where you have the **Admin** role+- A KMIP client that supports KMIP 1.0 to 1.4, and can reach the KMIP server on port 5696++## Step 1: Register the client++<Steps>+ <Step>+ In your KMS project, go to **KMIP** and select **Add KMIP Client**.+ </Step>+ <Step>+ Enter a **Name**, and select the **Permissions** for the KMIP operations the client can run, such as **Create**, **Get**, and **Locate**.+ </Step>+ <Step>+ Select **Add KMIP Client**.+ </Step>+</Steps>++## Step 2: Create the client's certificate++<Steps>+ <Step>+ Select the options menu on the client's row, then select **Generate Certificate**.+ </Step>+ <Step>+ Pick a **Request Method**:++ - **Managed**: Infisical creates the client's private key and certificate. Enter a **Key Algorithm**+ - **Certificate Signing Request (CSR)**: If the client creates its own private key, paste the client's CSR. The CSR's subject must use the **Client ID** as the common name (CN) and the **Project ID** as the organizational unit (OU), as shown under **Certificate Subject Values**+ </Step>+ <Step>+ Enter a **TTL** for the certificate, such as `1y`, then select **Generate Certificate** or **Sign Certificate**.+ </Step>+ <Step>+ Before you close the dialog, save the **Certificate Body**, the **Certificate Chain**, and, for a **Managed** certificate, the **Certificate Private Key**.+ </Step>+</Steps>++## Step 3: Configure the client++The settings differ between clients, but most clients need the following:++- **Server address**: One of the hostnames or IP addresses you set on the KMIP server, with port `5696`, such as `kmip.example.com:5696`+- **Client certificate**: The **Certificate Body**+- **Client private key**: The **Certificate Private Key**+- **CA certificate**: The **Certificate Chain**, which the client uses to check the KMIP server's certificate++For example, a [PyKMIP](https://pykmip.readthedocs.io/) client configuration looks like this:++```ini+[client]+host=kmip.example.com+port=5696+certfile=/path/to/client-cert.pem+keyfile=/path/to/client-key.pem+ca_certs=/path/to/cert-chain.pem+```++To check the connection, run a simple operation from the client, such as creating a test key.++## Troubleshooting++<AccordionGroup>+ <Accordion title="The client can't connect to the KMIP server">+ - Check that the client can reach the KMIP server on the port it’s listening on (5696 by default)+ - Check that the KMIP server's `--listen-address` is an address the client can reach. If it’s bound to 127.0.0.1, only clients on the same machine can connect. Use the server’s network IP, or 0.0.0.0 to listen on all interfaces.+ - Check that the server address the client uses is one of the hostnames or IP addresses set on the KMIP server+ - Check that the client's certificate hasn't expired++ To see the details of the TLS connection, run the following command from the client's machine:++ ```bash+ openssl s_client -connect kmip.example.com:5696 \+ -cert client-cert.pem -key client-key.pem \+ -CAfile cert-chain.pem -tls1_2 -showcerts+ ```++ If the connection works, the output includes the KMIP server's certificate chain.+ </Accordion>+ <Accordion title="The client connects, but an operation fails">+ Check that the client has the permission for the operation. In your KMS project, go to **KMIP**, select the options menu on the client's row, and select **Edit KMIP Client**.++ For more detail, check the KMIP server's logs.+ </Accordion>+</AccordionGroup>diff --git a/docs/documentation/platform/kms/kmip-dell-poweredge.mdx b/docs/documentation/platform/kms/kmip-dell-poweredge.mdxindex f4090452fb..4942c052a7 100644--- a/docs/documentation/platform/kms/kmip-dell-poweredge.mdx+++ b/docs/documentation/platform/kms/kmip-dell-poweredge.mdx@@ -1,64 +1,81 @@---title: "Dell PowerEdge SEKM"-description: "Integrate Infisical KMIP with Dell PowerEdge servers using Secure Enterprise Key Management (SEKM) for Self-Encrypting Drives."+description: "Encrypt the drives in Dell PowerEdge servers with keys from Infisical KMS."----This guide walks you through setting up Secure Enterprise Key Management (SEKM) on Dell PowerEdge servers with iDRAC to encrypt Self-Encrypting Drives (SEDs) using Infisical as your key management server.+Dell PowerEdge servers can encrypt their self-encrypting drives (SEDs) with keys from a KMIP key manager, through a feature of iDRAC called Secure Enterprise Key Management (SEKM). This guide sets up iDRAC as a [KMIP client](/documentation/platform/kms/kmip-clients) of Infisical KMS.## Prerequisites-- Infisical KMIP server deployed and running (see [KMIP Integration](/documentation/platform/kms/kmip))-- Dell PowerEdge server with iDRAC Enterprise license-- SEKM license installed on iDRAC-- Network connectivity between iDRAC and KMIP server on port 5696+- A running [KMIP server](/documentation/platform/kms/kmip-server) that iDRAC can reach on port 5696+- A KMS project where you have the **Admin** role+- A Dell PowerEdge server with an iDRAC Enterprise license and an SEKM license-## Integration steps+## Step 1: Register iDRAC as a KMIP client<Steps>- <Step title="Create a KMIP Client in Infisical">- In your KMS project, navigate to **KMIP** and create a KMIP client for the iDRAC.+ <Step>+ In your KMS project, go to **KMIP** and select **Add KMIP Client**.</Step>-- <Step title="Configure SEKM on iDRAC">- 1. Log into the iDRAC web interface- 2. Navigate to **iDRAC Settings > Services**- 3. Expand **iDRAC Key Management** and select **SEKM**- 4. Enter the KMIP server address and port (default: 5696)- 5. Select **Next**+ <Step>+ Enter a **Name**, select every operation under **Permissions**, then select **Add KMIP Client**.+ </Step>+ <Step>+ Select the options menu on the client's row, select **Generate Certificate**, and set **Request Method** to **Certificate Signing Request (CSR)**. Keep the dialog open: you need the **Client ID** and **Project ID** it shows in the next step.</Step>+</Steps>- <Step title="Generate Certificate Request on iDRAC">- When iDRAC prompts you to generate a certificate request, you'll need to enter subject values. You can find the required values in Infisical by selecting **Generate Certificate** on your KMIP client and selecting the **CSR** request method - the modal will display the exact **Client ID** and **Project ID** to use.-- 1. Click **Generate CSR** on iDRAC- 2. Enter the certificate information:- - **Common Name (CN)**: Enter the **Client ID** shown in Infisical- - **Organizational Unit (OU)**: Enter the **Project ID** shown in Infisical- - Fill in other fields as needed (Organization, Country, etc.)- 3. Click **Generate** and download the certificate request file+## Step 2: Create a certificate request on iDRAC++<Steps>+ <Step>+ In the iDRAC web interface, go to **iDRAC Settings** > **Services**, expand **iDRAC Key Management**, and select **SEKM**.</Step>+ <Step>+ Enter the KMIP server's address and port `5696`, then select **Next**.+ </Step>+ <Step>+ Select **Generate CSR**, and fill in the certificate fields:- <Step title="Sign the Certificate in Infisical">- 1. In the Infisical modal, paste the certificate request content from iDRAC- 2. Set the certificate validity period (e.g., "1y" for one year)- 3. Select **Sign Certificate**- 4. Download the signed certificate and certificate chain+ - **Common Name (CN)**: The **Client ID** from Infisical+ - **Organizational Unit (OU)**: The **Project ID** from Infisical+ - Any other fields your organization requires, such as **Organization** and **Country**+ </Step>+ <Step>+ Select **Generate**, and download the certificate request.</Step>+</Steps>++## Step 3: Sign the certificate in Infisical- <Step title="Upload Certificate to iDRAC">- 1. In iDRAC, upload the signed client certificate- 2. Upload the certificate chain as the KMS CA certificate- 3. Select **Test Network Connection** to verify connectivity- 4. Complete the SEKM configuration+<Steps>+ <Step>+ In the Infisical dialog, paste the certificate request into **Certificate Signing Request (CSR)**.+ </Step>+ <Step>+ Enter a **TTL**, such as `1y`, then select **Sign Certificate**.</Step>+ <Step>+ Download the **Certificate Body** and the **Certificate Chain**.+ </Step>+</Steps>- <Step title="Enable Encryption on Storage Controller">- Once SEKM is configured, you can enable encryption on your storage controller (PERC, HBA, or NVMe) through iDRAC.+## Step 4: Finish the setup on iDRAC++<Steps>+ <Step>+ In iDRAC, upload the **Certificate Body** as the client certificate, and the **Certificate Chain** as the KMS CA certificate.+ </Step>+ <Step>+ Select **Test Network Connection**, then finish the SEKM setup.+ </Step>+ <Step>+ Turn on encryption for your storage controller (PERC, HBA, or NVMe) in iDRAC.</Step></Steps>## Troubleshooting-- **Certificate validation fails**: Make sure you used the correct Client ID and Project ID when generating the certificate request on iDRAC.-- **Connection timeout**: Verify network connectivity and that firewall rules allow traffic on port 5696.-- **Authentication errors**: Ensure you uploaded both the signed certificate and the certificate chain to iDRAC.+- **Certificate validation fails**: Check that the certificate request used the **Client ID** as the common name and the **Project ID** as the organizational unit+- **Connection times out**: Check that iDRAC can reach the KMIP server, and that your firewall allows traffic on port 5696+- **Authentication fails**: Check that you uploaded both the client certificate and the certificate chain to iDRACdiff --git a/docs/documentation/platform/kms/kmip-server.mdx b/docs/documentation/platform/kms/kmip-server.mdxnew file mode 100644index 0000000000..2f5a7a9421--- /dev/null+++ b/docs/documentation/platform/kms/kmip-server.mdx@@ -0,0 +1,114 @@+---+title: "Deploy a KMIP server"+description: "Run the KMIP server that your KMIP clients connect to."+---++A [KMIP](/documentation/platform/kms/kmip) server accepts connections from your KMIP clients and passes their requests on to Infisical. You create the KMIP server in Infisical once for your organization, then run it with the Infisical CLI on a machine that your clients can reach.++## Prerequisites++- An organization on Infisical's [Enterprise](https://infisical.com/pricing) plan+- A Linux machine, VM, or container that your KMIP clients can reach, with the [Infisical CLI](/cli/overview) installed+- A firewall that allows the following traffic:++| Direction | Port | Purpose |+| --- | --- | --- |+| Inbound | TCP 5696 | KMIP clients connecting to the KMIP server |+| Outbound | TCP 443 | The KMIP server connecting to Infisical |++## Step 1: Create the KMIP server in Infisical++<Steps>+ <Step>+ In your organization, go to **KMS** > **KMIP Servers**, then select **Create KMIP Server**.+ </Step>+ <Step>+ Fill in the fields, then select **Create KMIP Server**:++ - **Name**: A name for the KMIP server+ - **Hostnames or IPs**: A comma-separated list of the hostnames or IP addresses that clients use to reach the KMIP server, such as `kmip.example.com` (Infisical adds them to the server's TLS certificate, so clients can't connect through any other address)+ - **Key algorithm**: The algorithm of the key that signs the server's TLS certificate+ </Step>+ <Step>+ Optionally, change how the KMIP server authenticates to Infisical. On the KMIP server's page, select the edit icon next to **Authentication**, and pick a **Method**:++ - **Token Auth** (default): The KMIP server enrolls with a one-time token that expires after 1 hour+ - **AWS Auth**: The KMIP server authenticates with the AWS credentials on its machine, such as an instance role. Enter the **Allowed Principal ARNs** or **Allowed Account IDs** of your machines+ </Step>+</Steps>++The server's TLS certificate is valid for one year, and the KMIP server renews it automatically. To set a different validity period, create the KMIP server with [the create KMIP server endpoint](/api-reference/endpoints/kmip-servers/create) and set `ttl`.++## Step 2: Run the KMIP server++<Steps>+ <Step>+ On the KMIP server's page, go to the **Deployment** section. If the KMIP server uses **Token Auth**, select **Generate Deploy Command**.+ </Step>+ <Step>+ Pick a tab, and copy the command:++ - **System Service**: Installs the KMIP server as a systemd service that starts with the machine (use this in production)+ - **CLI**: Runs the KMIP server in your terminal+ </Step>+ <Step>+ By default, the KMIP server listens only on `localhost:5696`, so only clients on the same machine can connect. If your clients run on other machines, add `--listen-address` to the command with an address they can reach:++ - **One network interface**: The machine's IP address on the network your clients use, such as `--listen-address="10.0.1.50:5696"`+ - **Every network interface**: `--listen-address="0.0.0.0:5696"`, which exposes the KMIP server on every network the machine is on+ </Step>+ <Step>+ Run the command on your machine. For example, a systemd install with **Token Auth** that listens on one network interface looks like this:++ ```bash+ sudo infisical kmip systemd install <server-name> \+ --enroll-method=token \+ --token=<enrollment-token> \+ --listen-address="10.0.1.50:5696" \+ --domain=https://app.infisical.com+ sudo systemctl start infisical-kmip+ ```++ With **AWS Auth**, the command uses `--enroll-method=aws` and `--kmip-server-id=<kmip-server-id>` instead of a token.++ <Note>+ If you use EU Cloud or self-host Infisical, `--domain` is `https://eu.infisical.com` or the address of your instance. The command you copied already sets it.+ </Note>+ </Step>+ <Step>+ Check the KMIP server's logs for a `Listening on` line and a `Next certificate renewal scheduled in` line. For a systemd install, run:++ ```bash+ sudo journalctl -u infisical-kmip -f+ ```+ </Step>+</Steps>++To restart the KMIP server, run the same command again. With **Token Auth**, the KMIP server reuses the access token from its first enrollment, so the expired enrollment token doesn't matter.++Next, [connect your KMIP clients](/documentation/platform/kms/kmip-clients).++## Manage a KMIP server++On the KMIP server's page:++- **Change the TLS certificate**: Select the edit icon next to **Certificate Configuration** to change the hostnames, IP addresses, or key algorithm. The KMIP server uses the new settings when it next renews its certificate, or when you restart it+- **Get a new enrollment token**: In **Deployment**, select **Regenerate Command**. A running KMIP server stays connected+- **Disconnect the KMIP server**: Select **Options** > **Revoke Access**. The KMIP server can't reach Infisical until it enrolls again+- **Delete the KMIP server**: Select **Options** > **Delete KMIP Server**++## Troubleshooting++<AccordionGroup>+ <Accordion title="The logs show 'Certificate renewal failed'">+ If Infisical was briefly unreachable, you don't need to do anything. The KMIP server keeps using its current certificate, and tries again more often as the certificate gets closer to expiring.++ If the error is about authentication, such as after you revoked the KMIP server's access:++ - **AWS Auth**: The KMIP server authenticates again on its own+ - **Token Auth**: Select **Regenerate Command**, and run the new command on the machine+ </Accordion>+ <Accordion title="The enrollment token expired before I ran the command">+ Enrollment tokens expire after 1 hour, and work only once. Select **Regenerate Command** to get a new one.+ </Accordion>+</AccordionGroup>diff --git a/docs/documentation/platform/kms/kmip.mdx b/docs/documentation/platform/kms/kmip.mdxindex 65df9324d1..5e7a35eadd 100644--- a/docs/documentation/platform/kms/kmip.mdx+++ b/docs/documentation/platform/kms/kmip.mdx@@ -1,320 +1,68 @@----title: "Overview"-description: "Learn more about integrating with Infisical KMS using KMIP (Key Management Interoperability Protocol)."+title: "KMIP"+sidebarTitle: "Overview"+description: "Let devices and software that support KMIP manage their keys."----<Note>- KMIP integration is an Enterprise-only feature. Please reach out to- [email protected] if you have any questions.-</Note>--Infisical KMS provides Key Management Interoperability Protocol (KMIP) support for integration with KMIP-compatible clients. This allows for enhanced key management across various applications that support the KMIP 1.4 protocol.--## How KMIP works with Infisical--At a high level, the KMIP integration follows this architecture:-----At a high level, the KMIP integration works as follows:--1. KMIP clients (your applications or tools) communicate with the KMIP server-2. The KMIP server acts as a proxy and forwards requests to Infisical KMS-3. The KMIP server authenticates to Infisical using an enrollment-based access token--The KMIP server itself is deployed using the Infisical CLI (`infisical kmip start` command) and serves as an intermediary between your KMIP clients and Infisical's key management system.--You create a KMIP server entity in Infisical, then enroll a deployed server against it using a one-time enrollment token or AWS authentication. This is the same enrollment model used by [Gateways](/documentation/platform/gateways/overview) and [Relays](/documentation/platform/gateways/relay-deployment).--### Supported operations--The Infisical KMIP server supports the following operations for symmetric keys:--- **Create** - Generate symmetric keys-- **Register** - Register externally created keys-- **Locate** - Find keys using attributes-- **Get** - Retrieve keys securely-- **Activate** - Enable keys for usage-- **Revoke** - Revoke existing keys-- **Destroy** - Permanently remove keys-- **Get Attributes** - Retrieve metadata associated with keys-- **Query** - Query server capabilities and supported operations--### Compatibility--Infisical KMIP supports KMIP versions 1.0 to 1.4, ensuring compatibility with a wide range of clients and security tools.--### Network requirements--Ensure the following network connectivity is in place:--- **KMIP Client → KMIP Server**: KMIP clients must be able to reach the KMIP server on port 5696 (or your configured port). Ensure firewalls allow this traffic and DNS resolution works if using hostnames.--- **KMIP Server → Infisical Platform**: The KMIP server needs outbound HTTPS access to Infisical. For self-hosted instances, ensure connectivity to your custom domain.--All connections from the KMIP server are outbound; no inbound ports need to be opened on the server's network for it to reach Infisical.--## Configure and deploy the KMIP server--A KMIP server is created as an organization-wide entity in Infisical and then enrolled from the host where you run it.--<Steps>- <Step title="Create the KMIP Server in the UI">- 1. In the Infisical dashboard, open **Infisical KMS** and select **KMIP Servers**.- 2. Select **Create KMIP Server** and fill in:- - **Name** of the server.- - **Hostnames or IPs**: a comma-separated list of the hostnames or IPs that KMIP clients will use to reach this server (for example `kmip.example.com` or `10.0.1.50`). These become the Subject Alternative Names (SANs) of the server's TLS certificate, so they must match how clients connect.- - **Key Algorithm**: key algorithm used to sign the server certificate.-- The server certificate is issued with a one-year validity period and renews automatically before it expires, so there is no TTL to configure. If you need a custom validity period (for example, to meet a compliance requirement), set `ttl` via the [API](/api-reference/endpoints/kmip-servers/update).-- This certificate configuration is stored on the server entity. The CLI reads it on start, so you do not pass it on the command line. You can change it later from the server's detail page (edit the **Certificate Configuration** card); changes apply at the server's next automatic certificate renewal, or immediately if you restart it.- 3. (Optional) Open the new server's detail page and click the edit icon next to **Authentication** to switch the auth method. Two methods are supported:- - **Token** (default): a one-time enrollment token (1h expiry) bootstraps the server.- - **AWS**: the server authenticates by signing an `sts:GetCallerIdentity` request with whatever AWS credentials it can resolve on the host (instance role, env vars, shared profile). Configure the allowed principal ARNs and/or account IDs that match your hosts.- 4. Click **Show deploy command** in the **Deployment** card and copy the generated CLI command.- </Step>-- <Step title="Install the Infisical CLI">- Make sure the Infisical CLI is installed on the target machine where you want to run the KMIP server. See the [CLI Installation Guide](/cli/install) for instructions.-- You can run the KMIP server on any infrastructure that can reach the Infisical platform, such as a VM or container.- </Step>-- <Step title="Configure Network & Firewall">- Ensure your network and firewall settings allow the required traffic.-- | Protocol | Direction | Port | Purpose |- | -------- | --------- | ---- | ------------------------------------------------ |- | TCP | Inbound | 5696 | KMIP client connections to the KMIP server |- | TCP | Outbound | 443 | API communication and certificate requests |-- Only the KMIP client port (default `5696`) needs to be reachable by your clients. All traffic from the server to Infisical is outbound.- </Step>-- <Step title="Run the CLI Command">- Run the command you copied from the UI on the target machine. This single command enrolls the KMIP server and starts it immediately.-- <AccordionGroup>- <Accordion title="Token Auth">- A one-time enrollment token (1h expiry) bootstraps the KMIP server.-- <Tabs>- <Tab title="Linux (Production)">- ```bash- sudo infisical kmip systemd install <server-name> \- --enroll-method=token \- --token=<enrollment-token> \- --listen-address="0.0.0.0:5696" \- --domain=<your-infisical-domain>- sudo systemctl start infisical-kmip- ```- </Tab>- <Tab title="Foreground">- ```bash- infisical kmip start <server-name> \- --enroll-method=token \- --token=<enrollment-token> \- --listen-address="0.0.0.0:5696" \- --domain=<your-infisical-domain>- ```- </Tab>- </Tabs>- </Accordion>- <Accordion title="AWS Auth">- The host must have AWS credentials whose principal matches your allowlist. The server re-authenticates via STS on every start.-- <Tabs>- <Tab title="Linux (Production)">- ```bash- sudo infisical kmip systemd install <server-name> \- --enroll-method=aws \- --kmip-server-id=<kmip-server-id> \- --listen-address="0.0.0.0:5696" \- --domain=<your-infisical-domain>- sudo systemctl start infisical-kmip- ```- </Tab>- <Tab title="Foreground">- ```bash- infisical kmip start <server-name> \- --enroll-method=aws \- --kmip-server-id=<kmip-server-id> \- --listen-address="0.0.0.0:5696" \- --domain=<your-infisical-domain>- ```- </Tab>- </Tabs>- </Accordion>- </AccordionGroup>-- <Warning>- The systemd install command requires Linux with root/sudo privileges.- </Warning>-- <Note>- The server's certificate configuration (hostnames/IPs, key algorithm) is read from the server entity you configured in the UI, so the deploy command does not include it. To change the certificate, edit the **Certificate Configuration** card on the server's detail page. Changes apply at the next automatic certificate renewal, or restart the server to apply them immediately.- </Note>-- <Note>- By default the server listens on `localhost:5696`, which only accepts connections from the same host. To accept connections from your KMIP clients, set `--listen-address="0.0.0.0:5696"` (or bind to a specific interface).- </Note>-- <Info>- Token-method enrollment tokens are single-use and expire after 1 hour. If the token expires before deployment, click **Show deploy command** again on the detail page to generate a new one.- </Info>-- <Info>- You can safely re-run the same command to restart the server. For token auth the CLI reuses the locally stored access token and skips enrollment; for AWS auth it re-authenticates via STS on each start.- </Info>- </Step>-- <Step title="Verify the KMIP Server">- After deployment, verify the server is running:- 1. **Check logs** for a "Listening on ..." message, confirmation that the certificates loaded successfully, and a "Next certificate renewal scheduled in ..." line showing auto-renewal is active.- 2. For systemd installations, check the service status:- ```bash- sudo systemctl status infisical-kmip- sudo journalctl -u infisical-kmip -f- ```-- Once started, your KMIP server is running and ready to accept client connections. It proxies all KMIP operations to Infisical KMS.- </Step>-</Steps>--## Managing a KMIP server--From the KMIP server's detail page (under **Infisical KMS > KMIP Servers**):--- **Show deploy command** — Generates a fresh enrollment token (token method) or re-displays the AWS start command. For token-method servers this doesn't disconnect a running server; the next enrollment with the new token supersedes the old one.-- **Edit certificate configuration**: Update the hostnames/IPs or key algorithm used for the server's TLS certificate. Changes take effect at the next automatic certificate renewal; restart the server to apply them immediately.-- **Edit authentication** — Switch between Token and AWS, or update the AWS allowlists.-- **Options → Revoke Access** — Invalidates the server's outstanding access tokens and enrollment tokens. The server must re-enroll to reconnect.-- **Options → Delete** — Permanently removes the KMIP server entity.--### Renewal failures--The server's TLS certificate renews automatically in the background; no action is needed and existing client connections are never interrupted. You only need to step in if renewal fails, which the server reports with `Certificate renewal failed` warnings and errors in its logs.--If the failure is transient (for example, the Infisical platform is temporarily unreachable), the server keeps serving its current certificate and retries with increasing frequency as expiry approaches. Once the platform is reachable again, the next retry succeeds and normal operation resumes on its own.--If the failure is an authentication error (for example, after revoking the server's access), recovery depends on the auth method. AWS-enrolled servers recover automatically by re-authenticating via STS. Token-enrolled servers can't, since enrollment tokens are single-use; the server logs an error asking you to re-enroll. Generate a new enrollment token via **Show deploy command** and restart the server with it to recover.--## Register a KMIP client--Once the KMIP server is running, register the KMIP clients that will connect to it. Clients are managed per-project from a KMS project's KMIP settings and authenticate via mTLS certificates.--<Steps>- <Step title="Navigate to Your KMS Project">- Navigate to the desired KMS project if you already have one or create a new project of type KMS, then select **KMIP** once inside the project, and select **Add KMIP Client**.-- - </Step>-- <Step title="Configure the KMIP Client">- Define the client and its permissions.-- In the modal, provide the details of your client. The selected permissions determine what KMIP operations (Create, Get, Revoke, etc.) can be performed in your KMS project.-- -- This creates a KMIP client entity in Infisical that will be authenticated via mTLS certificates.- </Step>-- <Step title="Generate Client Certificate">- Each KMIP client needs its own certificate for mTLS authentication.-- Click **Generate Certificate** for your newly created client. Select the request method:- - **Managed**: Infisical generates the key pair and certificate for you. Provide the TTL and key algorithm.- - **CSR**: Provide your own Certificate Signing Request if your device generates keys internally (e.g., Dell iDRAC). See the [Dell PowerEdge SEKM](/documentation/platform/kms/kmip-dell-poweredge) guide for details.-- Download the generated certificate and certificate chain (and private key if using Managed mode). Configure your KMIP-compatible applications or tools to use these credentials when connecting to the KMIP server.- </Step>-</Steps>--## Connecting your KMIP client to Infisical--After completing the setup, configure your KMIP compatible application to connect to the KMIP server.--While exact configuration steps vary by application, you'll generally need to provide:--1. **KMIP Server Address**: The hostname or IP and port where your KMIP server is listening (e.g., `my-kmip-server.com:5696`)--2. **Client Certificates**: The certificate credentials generated from your Infisical KMS project:- - **Client Certificate** (`client-cert.pem`) - Identifies your KMIP client- - **Client Private Key** (`client-key.pem`) - Used for mTLS authentication- - **Certificate Chain** (`cert-chain.pem`) - Verifies the KMIP server--### General configuration steps-<Steps>- <Step title="Identify Your KMIP Server Endpoint">- Determine the address where your KMIP server is accessible. This should match one of the hostnames or IPs configured on the server entity in the UI.-- **Example endpoints:**- - `my-kmip-server.com:5696`- - `10.0.1.50:5696`- - `kmip.example.com:5696`-- The default port is `5696`, but this can be changed using the `--listen-address` flag when starting the server.- </Step>-- <Step title="Prepare Certificate Files">- Organize the certificate materials you downloaded when generating the client certificate from the Infisical KMS project. You should have three files:-- - **client-cert.pem** - The client certificate- - **cert-chain.pem** - The certificate chain (includes intermediate and root CA certificates)- - **client-key.pem** - The private key-- Most KMIP clients require these files in PEM format, which is what Infisical provides by default.- </Step>-- <Step title="Configure Your KMIP Client Application">- The exact configuration steps vary depending on your KMIP client application. Generally, you'll need to specify:-- **Common configuration parameters:**- - **Server hostname/IP**: Your KMIP server address (e.g., `my-kmip-server.com`)- - **Server port**: Default is `5696`- - **Client certificate**: Path to `client-cert.pem`- - **Client private key**: Path to `client-key.pem`- - **CA certificate**: Path to `cert-chain.pem` (used to verify the server)- - **Protocol version**: KMIP 1.0 through 1.4 are supported-- **Example configuration for PyKMIP:**- ```ini- [client]- host=my-kmip-server.com- port=5696- certfile=/path/to/client-cert.pem- keyfile=/path/to/client-key.pem- ca_certs=/path/to/cert-chain.pem- ```-- </Step>-- <Step title="Test the Connection">- Once configured, test the connection by performing a simple KMIP operation, such as:- - Querying server capabilities- - Creating a test key- - Listing available keys-- If the connection is successful, your KMIP client is now integrated with Infisical KMS and can perform key management operations according to the permissions you assigned.-- **Troubleshooting connection issues:**- - Verify network connectivity between your KMIP client and the KMIP server- - Check that certificate files are readable and in the correct format- - Ensure the KMIP server is running and accessible- - Review KMIP server logs for authentication errors- - Confirm the client certificate has not expired-- If you require further verification of your certificate details and connectivity to the KMIP server from your KMIP client, you can use the following command from your client machine:-- ```bash- openssl s_client -connect kmip-server-ip-here:5696 --cert /path/to/client-cert.pem --key /path/to/client-cert.pem --CAfile /path/to/cert-chain.pem --tls1_2 --showcerts --state --debug- ```-- This command attempts to establish a TLS connection to the KMIP server using your client certificate and key, displaying detailed information about the handshake process.- If the connection is successful, you'll see the server's certificate chain and a message indicating that the handshake was completed.-- </Step>-</Steps>+The Key Management Interoperability Protocol (KMIP) is a standard protocol that storage arrays, databases, servers, and backup tools use to get their encryption keys from a key manager. With KMIP, these clients can create and fetch keys in Infisical KMS.++<Info>+ KMIP is available under Infisical's [Enterprise](https://infisical.com/pricing) plan. If you're self-hosting Infisical, contact [email protected] to purchase an enterprise license.+</Info>++<Accordion title="How it works">+ KMIP clients don't connect to Infisical directly. They connect to a KMIP server that you run on your own network with the Infisical CLI, and the KMIP server passes each request on to Infisical:++ ```mermaid+ flowchart LR+ subgraph network["Your network"]+ client["KMIP client"]+ server["KMIP server"]+ end+ client -- "KMIP request, port 5696" --> server+ server -- "HTTPS, port 443" --> infisical["Infisical KMS"]+ style network fill:#ffffde,stroke:#aaaa33,color:#000+ style client fill:#ececff,stroke:#9370db,color:#000+ style server fill:#e1f5fe,stroke:#01579b,color:#000+ style infisical fill:#ffffff,stroke:#757575,color:#000+ ```++ 1. A KMIP client connects to the KMIP server on port 5696, and authenticates with a client certificate that Infisical issued+ 2. The KMIP server sends the request to Infisical over HTTPS+ 3. Infisical runs the request against the keys in the client's KMS project++ You create a KMIP server once for your organization, and any KMS project can use it. You register each client in the KMS project whose keys the client uses.++ Unlike the Infisical API, KMIP gives the client the key material, and the client encrypts data itself. This means you shouldn't [rotate](/documentation/platform/kms/key-rotation) a key that a KMIP client uses.+</Accordion>++## Set up KMIP++<CardGroup cols={2}>+ <Card title="Deploy a KMIP server" icon="server" href="/documentation/platform/kms/kmip-server">+ Run the KMIP server that your KMIP clients connect to.+ </Card>+ <Card title="Connect KMIP clients" icon="plug" href="/documentation/platform/kms/kmip-clients">+ Connect a KMIP client to the keys in a KMS project.+ </Card>+</CardGroup>++To set up a specific client, see [Dell PowerEdge SEKM](/documentation/platform/kms/kmip-dell-poweredge).++## Supported KMIP versions and operations++The KMIP server supports KMIP versions 1.0 to 1.4, and the following operations on symmetric keys:++| Operation | What it does |+| --- | --- |+| Create | Creates a symmetric key |+| Register | Adds a key that was created outside Infisical |+| Locate | Finds keys by their attributes |+| Get | Returns a key |+| Activate | Makes a key available for use |+| Revoke | Revokes a key |+| Destroy | Deletes a key |+| Get Attributes | Returns a key's attributes |+| Query | Returns the operations and objects that the server supports |++When you register a client, you choose which of these operations the client can run.diff --git a/docs/documentation/platform/kms/kubernetes-encryption.mdx b/docs/documentation/platform/kms/kubernetes-encryption.mdxindex 95dbc6f022..6980cf0bec 100644--- a/docs/documentation/platform/kms/kubernetes-encryption.mdx+++ b/docs/documentation/platform/kms/kubernetes-encryption.mdx@@ -1,6 +1,6 @@---title: "Kubernetes encryption with KMS"sidebarTitle: "Kubernetes encryption"-description: "Encrypt Kubernetes secrets at rest with Infisical KMS using the Kubernetes KMS plugin."+description: "Encrypt Kubernetes secrets at rest with a key in Infisical KMS."url: "https://github.com/Infisical/k8-kms-plugin"---diff --git a/docs/documentation/platform/kms/mac.mdx b/docs/documentation/platform/kms/mac.mdxnew file mode 100644index 0000000000..08764210ca--- /dev/null+++ b/docs/documentation/platform/kms/mac.mdx@@ -0,0 +1,104 @@+---+title: "Generate and verify MACs"+description: "Use message authentication codes to check that data hasn't changed."+---++A message authentication code (MAC) shows that data hasn't changed since the MAC was generated, and that whoever generated it had access to the key. To generate a MAC, send your data to Infisical with a Generate/Verify MAC key. To check the data later, send the data and the MAC back with the same key.++The key's algorithm, such as HMAC-SHA-256, decides the MAC algorithm, so you don't pick one for each request.++## Prerequisites++- A [Generate/Verify MAC key](/documentation/platform/kms/keys#create-a-key)+- The **Member** role to follow the UI steps, or the **Cryptographic Operator** role to follow the API steps (see [Who can use a key](/documentation/platform/kms/keys#who-can-use-a-key))++## Generate a MAC++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the key's row, then select **Generate MAC**.+ </Step>+ <Step>+ Enter your data in **Data to Authenticate**. If your data is already Base64 encoded, turn on **Data is Base64 encoded**.+ </Step>+ <Step>+ Select **Generate MAC**, then copy the MAC from **Message Authentication Code**.+ </Step>+ </Steps>+ </Tab>+ <Tab title="API">+ Base64 encode your data, then call [the generate MAC endpoint](/api-reference/endpoints/kms/mac/generate-mac) with the key's ID:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/generate-mac \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "data": "SGVsbG8sIFdvcmxkIQ=="+ }'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>++ The response contains the Base64-encoded MAC:++ ```json+ {+ "mac": "<base64-encoded-mac>",+ "keyId": "<key-id>",+ "macAlgorithm": "HMAC_SHA_256"+ }+ ```+ </Tab>+</Tabs>++## Verify a MAC++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the row of the key that generated the MAC, then select **Verify MAC**.+ </Step>+ <Step>+ Enter the data in **Data to Verify** and the MAC in **Message Authentication Code**. If your data is already Base64 encoded, turn on **Data is Base64 encoded**.+ </Step>+ <Step>+ Select **Verify MAC**. **MAC Status** shows **Valid** if the MAC matches the data, and **Invalid** if it doesn't.+ </Step>+ </Steps>+ </Tab>+ <Tab title="API">+ Call [the verify MAC endpoint](/api-reference/endpoints/kms/mac/verify-mac) with the ID of the key that generated the MAC:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/verify-mac \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "data": "SGVsbG8sIFdvcmxkIQ==",+ "mac": "<base64-encoded-mac>"+ }'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>++ In the response, `macValid` is `true` if the MAC matches the data:++ ```json+ {+ "macValid": true,+ "keyId": "<key-id>",+ "macAlgorithm": "HMAC_SHA_256"+ }+ ```+ </Tab>+</Tabs>diff --git a/docs/documentation/platform/kms/overview.mdx b/docs/documentation/platform/kms/overview.mdxindex 45b7895ffd..3ab419d23b 100644--- a/docs/documentation/platform/kms/overview.mdx+++ b/docs/documentation/platform/kms/overview.mdx@@ -1,693 +1,71 @@---title: "Key management service (KMS)"-description: "Learn how to manage and use cryptographic keys with Infisical."+description: "Keep cryptographic keys in Infisical instead of in your applications."sidebarTitle: "KMS"icon: "lock"----## Concept--Infisical can be used as a Key Management System (KMS), referred to as Infisical KMS, to centralize management of keys to be used for cryptographic operations like encryption/decryption.--By default your Infisical data such as projects and the data within them are encrypted at rest using Infisical's own KMS. This ensures that your data is secure and protected from unauthorized access.--If you're on-premise, your KMS root key will be created at random with the `ROOT_ENCRYPTION_KEY` environment variable. You can also use a Hardware Security Module (HSM), to create the root key. Read more about [HSM](/self-hosting/guides/hsm-integration).--<Note>- Keys managed in KMS aren't extractable from the platform. Additionally, data- is never stored when performing cryptographic operations.-</Note>--## Workflow--The typical workflow for using Infisical KMS consists of the following steps:--1. Creating a KMS key. As part of this step, you specify a name for the key and the encryption algorithm meant to be used for it (e.g. `AES-GCM-128`, `AES-GCM-256`).-2. Encryption: To encrypt data, you would make a request to the Infisical KMS API endpoint, specifying the base64-encoded plaintext and the intended key to use for encryption; the API would return the base64-encoded ciphertext.-3. Decryption: To decrypt data, you would make a request to the Infisical KMS API endpoint, specifying the base64-encoded ciphertext and the intended key to use for decryption; the API would return the base64-encoded plaintext.--<Note>- Note that this workflow can be executed via the Infisical UI or manually such- as via API.-</Note>--## Encryption--### Guide to encrypting data--In the following steps, we explore how to generate a key and use it to encrypt data.--<Tabs>- <Tab title="Infisical UI">- <Steps>- <Step title="Creating a KMS key">- Navigate to Project > Key Management and select the **Add Key** button.- -- Specify your key details. Here's some guidance on each field:-- - Name: A slug-friendly name for the key.- - Key Usage: The type of key to create (e.g `Encrypt/Decrypt` for encryption, `Sign/Verify` for signing, and `Generate/Verify MAC` for message authentication codes).- - Algorithm: The encryption algorithm associated with the key (e.g. `AES-GCM-256`).- - Description: An optional description of what the intended usage is for the key.- - Allow Export: Whether the raw key material can be exported later. When disabled, the key material can never leave Infisical, regardless of permissions. This cannot be changed after the key is created.- - Delete Protection: Whether the key is protected from deletion. While enabled, the key cannot be deleted on its own. You can turn this off at any time by editing the key. Deleting the whole project still removes its keys.-- - </Step>- <Step title="Encrypting data with the KMS key">- Once your key is generated, open the options menu for the newly created key and select encrypt data.- -- Populate the text area with your data and tap on the Encrypt button.- -- <Note>- If your data is already Base64 encoded make sure to toggle the respective switch on to avoid- redundant encoding.- </Note>-- Copy and store the encrypted data.- - </Step>- </Steps>- </Tab>- <Tab title="API">- <Steps>- <Step title="Creating a KMS key">- To create a cryptographic key, make an API request to the [Create KMS- Key](/api-reference/endpoints/kms/keys/create) API endpoint.-- ### Sample request-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys \- --header 'Content-Type: application/json' \- --data '{- "projectId": "<project-id>",- "name": "my-secret-key",- "description": "...",- "algorithm": "aes-256-gcm"- }'- ```-- ### Sample response-- ```bash Response- {- "key": {- "id": "<key-id>",- "description": "...",- "isDisabled": false,- "isReserved": false,- "orgId": "<org-id>",- "name": "my-secret-key",- "createdAt": "2023-11-07T05:31:56Z",- "updatedAt": "2023-11-07T05:31:56Z",- "projectId": "<project-id>"- }- }- ```- </Step>- <Step title="Encrypting data with the KMS key">- To encrypt data, make an API request to the [Encrypt- Data](/api-reference/endpoints/kms/encryption/encrypt) API endpoint,- specifying the key to use.-- <Note>- Make sure your data is Base64 encoded- </Note>-- ### Sample request-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/encrypt \- --header 'Content-Type: application/json' \- --data '{- "plaintext": "lUFHM5Ggwo6TOfpuN1S==" // base64 encoded plaintext- }'- ```-- ### Sample response-- ```bash Response- {- "ciphertext": "HwFHwSFHwlMF6TOfp==" // base64 encoded ciphertext- }- ```- </Step>- </Steps>- </Tab>--</Tabs>--### Guide to decrypting data--In the following steps, we explore how to use decrypt data using an existing key in Infisical KMS.--<Tabs>- <Tab title="Infisical UI">- <Steps>- <Step title="Accessing your key">- Navigate to Project > Key Management and open the options menu for the key used to encrypt the data- you want to decrypt.- -- </Step>- <Step title="Decrypting your data">- Paste your encrypted data into the text area and tap on the Decrypt button. Optionally, if your data was- originally plain text, enable the decode Base64 switch.- -- Your decrypted data will be displayed and can be copied for use.- -- </Step>- </Steps>- </Tab>- <Tab title="API">- <Steps>- <Step title="Decrypting data">- To decrypt data, make an API request to the [Decrypt- Data](/api-reference/endpoints/kms/encryption/decrypt) API endpoint,- specifying the key to use.-- ### Sample request-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/decrypt \- --header 'Content-Type: application/json' \- --data '{- "ciphertext": "HwFHwSFHwlMF6TOfp==" // base64 encoded ciphertext- }'- ```-- ### Sample response-- ```bash Response- {- "plaintext": "lUFHM5Ggwo6TOfpuN1S==" // base64 encoded plaintext- }- ```- </Step>- </Steps>-- </Tab>--</Tabs>--## Signing--### Guide to signing data--In the following steps, we explore how to generate a key and use it to sign data.--<Tabs>- <Tab title="Infisical UI">- <Steps>- <Step title="Creating a KMS key">- Navigate to Project > Key Management and select the **Add Key** button.- -- Specify your key details. Here's some guidance on each field:-- - Name: A slug-friendly name for the key.- - Key Usage: The type of key to create (e.g `Encrypt/Decrypt` for encryption, `Sign/Verify` for signing, and `Generate/Verify MAC` for message authentication codes).- - Algorithm: The signing algorithm associated with the key (e.g. `RSA_4096`).- - Description: An optional description of what the intended usage is for the key.-- - </Step>-- <Step title="Signing data with the KMS key">- Once your key is generated, open the options menu for the newly created key and select sign data.- -- Populate the text area with your data and tap on the Sign button.- -- Make sure to select the appropriate signing algorithm that will be used to sign the data.- Supported signing algorithms are:-- **For RSA keys:**- - `RSASSA PSS SHA 512`: Not deterministic, and includes random salt.- - `RSASSA PSS SHA 384`: Not deterministic, and includes random salt.- - `RSASSA PSS SHA 256`: Not deterministic, and includes random salt.- - `RSASSA PKCS1 V1.5 SHA 512`: Deterministic, and does not include randomness.- - `RSASSA PKCS1 V1.5 SHA 384`: Deterministic, and does not include randomness.- - `RSASSA PKCS1 V1.5 SHA 256`: Deterministic, and does not include randomness.-- **For ECC keys:**- - `ECDSA SHA 512`: Not deterministic, and includes randomness.- - `ECDSA SHA 384`: Not deterministic, and includes randomness.- - `ECDSA SHA 256`: Not deterministic, and includes randomness.-- **For Ed25519 keys:**- - `ED25519`: Deterministic. The signing algorithm is the same as the key algorithm.-- Ed25519 hashes the message as part of the signature scheme, so there is no separate hash algorithm to choose and digest input is not supported.-- **For ML-DSA keys (post-quantum):**- - `ML_DSA_44`: The signing algorithm is the same as the key algorithm.- - `ML_DSA_65`: The signing algorithm is the same as the key algorithm.- - `ML_DSA_87`: The signing algorithm is the same as the key algorithm.-- ML-DSA is a NIST-standardized post-quantum digital signature algorithm. Unlike RSA and ECC, each ML-DSA key variant has exactly one signing algorithm (itself), and does not use a separate hash algorithm.-- <Info>- ML-DSA algorithms are an enterprise feature. Self-hosted users can contact [[email protected]](mailto:[email protected]) to purchase an enterprise license.- </Info>-- In this example, we'll use the `RSASSA PSS SHA 512` signing algorithm.-- <Note>- If your data is already Base64 encoded make sure to toggle the respective switch on to avoid- redundant encoding.- </Note>-- Copy and store the signature of your data.- - </Step>- </Steps>- </Tab>- <Tab title="API">- <Steps>- <Step title="Signing data">- To sign data, make an API request to the [Sign- Data](/api-reference/endpoints/kms/signing/sign) API endpoint,- specifying the key to use.-- ### Sample request-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/sign \- --header 'Content-Type: application/json' \- --data '{- "data": "SGVsbG8sIFdvcmxkIQ==", // base64 encoded data- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512",- }'- ```-- ### Sample response-- ```bash Response- {- "signature": "JYuiBt1Ta9pbqFIW9Ou6qzBsFhjYbMJp9k4dP87ILrO+F2MPnp85g3nOlXK1ttZmRoGWsWnLNDRn9W3rf5VtkeaixPqUW/KvY/fM3CxdMyIV3BuxlGgDksjL8X34Eqkrz4CCPo9hjB5uT+rBCOxCgZqRbOdATPipAneUapI9npseNquEeh3jPklwviBix83PJHV9PW2t03AGGUXuMY55ZaFEIMv+IrI1WYdnPVIXDyIitYsS3y+/6KRfhVeTcPNJ5Rw+FE9y1eZzDEZtTNpxOfUT3QIoXmpZlYL4HbhRuJBZ+Yx54C7uPiUIN9U69XbyXt+Kkynykw2HPaagwuCZxiqCU5sFfLnrVbc3dmZxQcX2yRrs2gmFamzBx+uVbi648H4mb7WuE5UPTBjjA11jRsBjCY0YS2T4Vgfe1RlzlPQkZgjP/bnCCGDqXa3/VZAlZX1nTI51X995bPHBQI0rq2sNDlIXenwiAy1wJSITbSI8DbUx09Cr83xCEaYAE6R6PUfog/tbIUXi0VbrYsCVkAGCK446Wb1vW6q7HR8jrjXNwmXlqN9eLbSVWqdWj7N7fieeTYSrECtUaAjxtUYTIVsH2bfT6FOEM9gMWKffOpFowVzzr3B9bNQLIhnEEwebxBw947i4OcxyVIcEUuumWxoKvcbSPxzJ8v1M3SoBBh4=", // base64 encoded signature- "keyId": "62b2c14e-58af-4199-9842-02995c63edf9",- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512",- }- ```-- <Note>- To sign predigested data, you can pass `"isDigest": true` in the request body. This requires the data to be a base64 encoded digest of the data you wish to sign.- It's important that the digest is created using the same hashing algorithm as the signing algorithm. As an example, you would create the digest with `SHA512` if you are using the `RSASSA_PKCS1_V1_5_SHA_512` signing algorithm.- </Note>- </Step>- </Steps>- </Tab>-</Tabs>--### Guide to verifying data--In the following steps, we explore how to verify data using an existing key in Infisical KMS.--<Tabs>- <Tab title="Infisical UI">- <Steps>- <Step title="Accessing your key">- Navigate to Project > Key Management and open the options menu for the key used to sign the data- you want to verify.- - </Step>-- <Step title="Verifying data with the KMS key">- Paste your signature and data into the text areas and tap on the Verify button.- -- Your verification result will be displayed and can be copied for use.- -- If the signature is invalid, you'll see an error message indicating that the signature is invalid, and the "Signature Status" field will be `Invalid`.- </Step>- </Steps>- </Tab>- <Tab title="API">- <Steps>- <Step title="Verifying data">- To verify data, make an API request to the [Verify- Data](/api-reference/endpoints/kms/signing/verify) API endpoint,- specifying the key to use.-- ### Sample request-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/verify \- --header 'Content-Type: application/json' \- --data '{- "data": "SGVsbG8sIFdvcmxkIQ==", // base64 encoded data- "signature": "JYuiBt1Ta9pbqFIW9Ou6qzBsFhjYbMJp9k4dP87ILrO+F2MPnp85g3nOlXK1ttZmRoGWsWnLNDRn9W3rf5VtkeaixPqUW/KvY/fM3CxdMyIV3BuxlGgDksjL8X34Eqkrz4CCPo9hjB5uT+rBCOxCgZqRbOdATPipAneUapI9npseNquEeh3jPklwviBix83PJHV9PW2t03AGGUXuMY55ZaFEIMv+IrI1WYdnPVIXDyIitYsS3y+/6KRfhVeTcPNJ5Rw+FE9y1eZzDEZtTNpxOfUT3QIoXmpZlYL4HbhRuJBZ+Yx54C7uPiUIN9U69XbyXt+Kkynykw2HPaagwuCZxiqCU5sFfLnrVbc3dmZxQcX2yRrs2gmFamzBx+uVbi648H4mb7WuE5UPTBjjA11jRsBjCY0YS2T4Vgfe1RlzlPQkZgjP/bnCCGDqXa3/VZAlZX1nTI51X995bPHBQI0rq2sNDlIXenwiAy1wJSITbSI8DbUx09Cr83xCEaYAE6R6PUfog/tbIUXi0VbrYsCVkAGCK446Wb1vW6q7HR8jrjXNwmXlqN9eLbSVWqdWj7N7fieeTYSrECtUaAjxtUYTIVsH2bfT6FOEM9gMWKffOpFowVzzr3B9bNQLIhnEEwebxBw947i4OcxyVIcEUuumWxoKvcbSPxzJ8v1M3SoBBh4=", // base64 encoded signature- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"- }'- ```-- ### Sample response-- ```bash Response- {- "signatureValid": true,- "keyId": "62b2c14e-58af-4199-9842-02995c63edf9",- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"- }- ```- <Note>- To verify predigested data, you can pass `"isDigest": true` in the request body. This requires the data to be a base64 encoded digest of the data you wish to verify.- It's important that the digest is created using the same hashing algorithm as the signing algorithm. As an example, you would create the digest with `SHA512` if you are using the `RSASSA_PKCS1_V1_5_SHA_512` signing algorithm.- </Note>- </Step>- </Steps>- </Tab>-</Tabs>--## Message authentication (MAC)--HMAC keys generate and verify hash-based message authentication codes, which confirm the integrity and authenticity of data using a shared secret key. The algorithm you choose at key creation determines both the key length and the hash function, so every generate and verify operation on that key uses the same MAC algorithm.--### Guide to generating a MAC--In the following steps, we explore how to generate a key and use it to produce a MAC.--<Tabs>- <Tab title="Infisical UI">- <Steps>- <Step title="Creating a KMS key">- Navigate to Project > Key Management and select the **Add Key** button.- -- Specify your key details. Here's some guidance on each field:-- - Name: A slug-friendly name for the key.- - Key Usage: Select `Generate/Verify MAC`.- - Algorithm: The HMAC algorithm associated with the key (e.g. `HMAC_SHA_256`). Supported algorithms are `HMAC_SHA_1`, `HMAC_SHA_224`, `HMAC_SHA_256`, `HMAC_SHA_384`, and `HMAC_SHA_512`.- - Description: An optional description of what the intended usage is for the key.- - Allow Export: Whether the raw key material can be exported later. When disabled, the key material can never leave Infisical, regardless of permissions. This cannot be changed after the key is created.- - Delete Protection: Whether the key is protected from deletion. While enabled, the key cannot be deleted on its own. You can turn this off at any time by editing the key. Deleting the whole project still removes its keys.- </Step>- <Step title="Generating a MAC with the KMS key">- Once your key is generated, open the options menu for the newly created key and select generate MAC.-- Populate the text area with your data and tap on the Generate MAC button. The MAC algorithm is determined by the key.-- <Note>- If your data is already Base64 encoded make sure to toggle the respective switch on to avoid- redundant encoding.- </Note>-- Copy and store the MAC of your data.- </Step>- </Steps>- </Tab>- <Tab title="API">- <Steps>- <Step title="Generating a MAC">- To generate a MAC, make an API request to the [Generate- MAC](/api-reference/endpoints/kms/mac/generate-mac) API endpoint,- specifying the key to use.-- ### Sample request-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/generate-mac \- --header 'Content-Type: application/json' \- --data '{- "data": "SGVsbG8sIFdvcmxkIQ==" // base64 encoded data- }'- ```-- ### Sample response-- ```bash Response- {- "mac": "5Vki892/TV/exl2K+mgAJyRblgCdLQpL//rr/rmT5rY=", // base64 encoded MAC- "keyId": "62b2c14e-58af-4199-9842-02995c63edf9",- "macAlgorithm": "HMAC_SHA_256"- }- ```- </Step>- </Steps>- </Tab>-</Tabs>--### Guide to verifying a MAC--In the following steps, we explore how to verify a MAC using an existing key in Infisical KMS.--<Tabs>- <Tab title="Infisical UI">- <Steps>- <Step title="Accessing your key">- Navigate to Project > Key Management and open the options menu for the key used to generate the MAC- you want to verify.- </Step>- <Step title="Verifying a MAC with the KMS key">- Select verify MAC, paste your MAC and data into the text areas, and select the Verify MAC button.-- Your verification result will be displayed. If the MAC is invalid, the "MAC Status" field will be `Invalid`.- </Step>- </Steps>- </Tab>- <Tab title="API">- <Steps>- <Step title="Verifying a MAC">- To verify a MAC, make an API request to the [Verify- MAC](/api-reference/endpoints/kms/mac/verify-mac) API endpoint,- specifying the key to use.-- ### Sample request-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/verify-mac \- --header 'Content-Type: application/json' \- --data '{- "data": "SGVsbG8sIFdvcmxkIQ==", // base64 encoded data- "mac": "5Vki892/TV/exl2K+mgAJyRblgCdLQpL//rr/rmT5rY=" // base64 encoded MAC- }'- ```-- ### Sample response-- ```bash Response- {- "macValid": true,- "keyId": "62b2c14e-58af-4199-9842-02995c63edf9",- "macAlgorithm": "HMAC_SHA_256"- }- ```- </Step>- </Steps>- </Tab>-</Tabs>--## Key rotation--Every KMS key tracks a version, starting at 1. Rotating a key generates new cryptographic key material for it and increments the version. The key keeps the same ID and name, so applications referencing the key don't need any changes.--How rotation behaves:--- New encrypt operations use the latest key material.-- All previous key material versions are retained inside Infisical, and decrypt operations automatically use the version that encrypted the ciphertext. Existing ciphertexts remain decryptable through Infisical without re-encryption.-- Rotation doesn't re-encrypt data that was already encrypted with the key. If you need ciphertexts to use the new material, decrypt and re-encrypt them.--To rotate a key:--1. Navigate to **Project > Key Management**.-2. Open the options menu for the key and select **Rotate Key**.-3. Confirm the rotation. The key version increments immediately.--Keys can also be rotated programmatically via the [rotate key API endpoint](/api-reference/endpoints/kms/keys/rotate).--<Note>- Rotation is supported for encrypt-decrypt keys with Infisical-managed key material. Sign-verify and- generate-verify-MAC keys should be rotated manually by creating a new key and updating your applications- to use it.-</Note>--<Warning>- Previous key material versions are retained only inside the Infisical instance where the key lives, and decrypt operations that resolve old versions automatically work only through Infisical's encrypt/decrypt API. Two workflows take key material outside of Infisical and only ever receive the current version, so rotation affects them:-- - **Exported or imported key material.** [Bulk export](#bulk-export) and the private-key export endpoints return only the current key material, and [bulk import](#bulk-import) creates a key at version 1. A key exported before rotation, or imported into another instance, won't carry its earlier versions, so ciphertexts encrypted under those earlier versions can't be decrypted from the exported material alone. If you rely on exported material for escrow or disaster recovery, re-export after each rotation and keep every exported version.-- - **KMIP-managed keys.** A KMIP client retrieves raw key material and encrypts data itself. If you rotate a key that is used over KMIP, the client will retrieve different material on its next fetch and will no longer be able to decrypt data it encrypted with the previous material. Don't rotate a key that is in use by a KMIP client; provision a new key instead.-</Warning>--## Bulk export & import--Infisical KMS supports bulk export and bulk import of key material, allowing you to export multiple keys at once or import keys in bulk from an external file.--### Bulk export--1. Navigate to **Project > Key Management**.-2. Use the checkboxes to select the keys you want to export (up to 100 at a time).-3. Select the **Export** button that appears in the action bar above the table.--4. A `.json` file is downloaded containing the key metadata and key material.--The exported file is a JSON array where each entry is one of the following shapes:--```json-// Encrypt/Decrypt key-{- "name": "my-aes-key",- "keyType": "encrypt-decrypt",- "algorithm": "aes-256-gcm",- "keyMaterial": "<base64-encoded key material>"-}--// Sign/Verify key-{- "name": "my-rsa-key",- "keyType": "sign-verify",- "algorithm": "RSA_4096",- "privateKey": "<base64-encoded private key>",- "publicKey": "<base64-encoded public key>"-}--// Generate/Verify MAC key-{- "name": "my-hmac-key",- "keyType": "generate-verify-mac",- "algorithm": "HMAC_SHA_256",- "keyMaterial": "<base64-encoded key material>"-}-```--<Warning>- The exported file contains sensitive cryptographic key material. Store it securely and don't share it.-</Warning>--<Note>- Keys created with **Allow Export** disabled are non-exportable. They can't be selected for export,- and any export request for them (including over KMIP) is rejected, regardless of the caller's permissions.-</Note>--### Bulk import--1. Navigate to **Project > Key Management**.-2. In the top-right of the keys table, select the dropdown arrow next to **Add Key** and select **Import Keys**.-3. Upload a `.json` file matching the export format described above (drag and drop, or select to browse).- Each entry may also include an optional `"isExportable": false` field to import the key as non-exportable.--4. A preview of the keys to be imported is shown, along with any validation errors.--5. Select **Import** to create the keys in the project.--<Note>- Importing creates new key entries. It doesn't overwrite existing keys with the same name.-</Note>--## FAQ--<AccordionGroup>- <Accordion title="Is my data stored in Infisical KMS?">- No. Infisical's KMS only provides cryptographic services and doesn't store- any encrypted or decrypted data.- </Accordion>- <Accordion title="Can key material be accessed outside of Infisical KMS?">- No. Infisical's KMS will never expose your keys, encrypted or decrypted, to- external sources.- </Accordion>- <Accordion title="What algorithms does Infisical KMS support?">- Infisical supports the following key algorithms:-- **Signing and verification:**- - `RSA_4096`- - `ECC_NIST_P256`- - `ED25519`- - `ML_DSA_44` (post-quantum)- - `ML_DSA_65` (post-quantum)- - `ML_DSA_87` (post-quantum)-- **Encryption and decryption:**- - `AES-256-GCM`- - `AES-128-GCM`-- **Message authentication (MAC):**- - `HMAC_SHA_1`- - `HMAC_SHA_224`- - `HMAC_SHA_256`- - `HMAC_SHA_384`- - `HMAC_SHA_512`-- <Info>- ML-DSA algorithms are an enterprise feature. Self-hosted users can contact [[email protected]](mailto:[email protected]) to purchase an enterprise license.- </Info>- </Accordion>- <Accordion title="How do I sign and verify a digest using the Infisical KMS?">- To sign and verify a digest using the Infisical KMS, you can use the `Sign` and `Verify` endpoints respectively.- You'll need to pass `"isDigest": true` in the request body to indicate that you're signing or verifying a digest.- The data you're signing or verifying will need to be a base64 encoded digest of the data you wish to sign or verify.- It's important that the digest is created using the same hashing algorithm as the signing algorithm. As an example, you would create the digest with `SHA512` if you're using the `RSASSA_PKCS1_V1_5_SHA_512` signing algorithm.-- To create a SHA512 digest of your data, you can use the following command with OpenSSL:- ```bash- echo -n "Hello, World" | openssl dgst -sha512 -binary | openssl base64- ```-- ### Sample request for signing a digest-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/sign \- --header 'Content-Type: application/json' \- --data '{- "data": <digest-output-of-openssl-command>,- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512",- "isDigest": true- }'- ```-- ### Sample response for signing a digest-- ```bash Response- {- "signature": <base64-encoded-signature>,- "keyId": <key-id>,- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"- }- ```-- ### Sample request for verifying a digest-- ```bash Request- curl --request POST \- --url https://app.infisical.com/api/v1/kms/keys/<key-id>/verify \- --header 'Content-Type: application/json' \- --data '{- "data": <digest-output-of-openssl-command>,- "signature": <base64-encoded-signature>,- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512",- "isDigest": true- }'- ```-- ### Sample response for verifying a digest-- ```bash Response- {- "signatureValid": true,- "keyId": <key-id>,- "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"- }- ```-- <Note>- Please note that `RSA PSS` signing algorithms are not supported for digest signing and verification. Please use `RSA PKCS1 V1.5` signing algorithms for digest signing and verification, or `ECDSA` if you're using an ECC key. Ed25519 and ML-DSA keys also do not support digest signing and verification, as both handle hashing internally.- </Note>- </Accordion>-</AccordionGroup>+Infisical Key Management System (KMS) stores cryptographic keys and runs operations with them, such as encryption and signing, so your applications never have access to the keys themselves.++You can use your keys from the Infisical UI, the [API](/api-reference/endpoints/kms/keys/list), KMIP clients, Kubernetes, and Sigstore Cosign.++<Tip>+To learn how Infisical KMS protects your keys, check out the [Concepts](/documentation/platform/kms/concepts) page.+</Tip>++## Keys++Create keys in a KMS project, then use them to process your data:++<CardGroup cols={2}>+ <Card title="Create and manage keys" icon="key-round" href="/documentation/platform/kms/keys">+ Create the keys that your applications use.+ </Card>+ <Card title="Encrypt and decrypt" icon="lock" href="/documentation/platform/kms/encrypt-decrypt">+ Encrypt and decrypt data with a key in Infisical KMS.+ </Card>+ <Card title="Sign and verify" icon="pen-tool" href="/documentation/platform/kms/sign-verify">+ Sign data and verify signatures with a key in Infisical KMS.+ </Card>+ <Card title="Generate and verify MACs" icon="fingerprint" href="/documentation/platform/kms/mac">+ Use message authentication codes to check that data hasn't changed.+ </Card>+ <Card title="Rotate keys" icon="rotate-cw" href="/documentation/platform/kms/key-rotation">+ Replace a key's key material without changing your applications.+ </Card>+ <Card title="Export and import keys" icon="arrow-left-right" href="/documentation/platform/kms/export-import">+ Move key material in and out of Infisical KMS.+ </Card>+</CardGroup>++## KMIP++Let storage arrays, databases, and other KMIP clients manage their keys in Infisical:++<CardGroup cols={2}>+ <Card title="Overview" icon="network" href="/documentation/platform/kms/kmip">+ Let devices and software that support KMIP manage their keys.+ </Card>+ <Card title="Deploy a KMIP server" icon="server" href="/documentation/platform/kms/kmip-server">+ Run the KMIP server that your KMIP clients connect to.+ </Card>+ <Card title="Connect KMIP clients" icon="plug" href="/documentation/platform/kms/kmip-clients">+ Connect a KMIP client to the keys in a KMS project.+ </Card>+ <Card title="Dell PowerEdge SEKM" icon="hard-drive" href="/documentation/platform/kms/kmip-dell-poweredge">+ Encrypt the drives in Dell PowerEdge servers with keys from Infisical KMS.+ </Card>+</CardGroup>++## Integrations++Use your keys from tools that support Infisical KMS:++<CardGroup cols={2}>+ <Card title="Kubernetes encryption" icon="container" href="/documentation/platform/kms/kubernetes-encryption">+ Encrypt Kubernetes secrets at rest with a key in Infisical KMS.+ </Card>+ <Card title="Sigstore Cosign" icon="badge-check" href="/documentation/platform/kms/sigstore-cosign">+ Sign container images with a key in Infisical KMS.+ </Card>+</CardGroup>diff --git a/docs/documentation/platform/kms/sign-verify.mdx b/docs/documentation/platform/kms/sign-verify.mdxnew file mode 100644index 0000000000..7802e76563--- /dev/null+++ b/docs/documentation/platform/kms/sign-verify.mdx@@ -0,0 +1,153 @@+---+title: "Sign and verify data"+sidebarTitle: "Sign and verify"+description: "Sign data and verify signatures with a key in Infisical KMS."+---++To sign data, send it to Infisical with a Sign/Verify key, and Infisical signs it with the key's private key. To verify the signature, send it back to Infisical, or give the key's public key to whoever needs to verify it.++## Prerequisites++- A [Sign/Verify key](/documentation/platform/kms/keys#create-a-key)+- The **Member** role to follow the UI steps, or the **Cryptographic Operator** role to follow the API steps (see [Who can use a key](/documentation/platform/kms/keys#who-can-use-a-key))++## Signing algorithms++When you sign or verify data, you choose a signing algorithm that matches the key's algorithm:++| Key algorithm | Signing algorithms |+| --- | --- |+| RSA-4096 | `RSASSA_PSS_SHA_256`, `RSASSA_PSS_SHA_384`, `RSASSA_PSS_SHA_512`, `RSASSA_PKCS1_V1_5_SHA_256`, `RSASSA_PKCS1_V1_5_SHA_384`, `RSASSA_PKCS1_V1_5_SHA_512` |+| ECC-NIST-P256, P384, and P521 | `ECDSA_SHA_256`, `ECDSA_SHA_384`, `ECDSA_SHA_512` |+| ED25519 | `ED25519` |+| ML-DSA-44, ML-DSA-65, and ML-DSA-87 | The same name as the key algorithm, such as `ML_DSA_65` |++RSASSA-PSS and ECDSA produce a different signature each time you sign the same data. RSASSA-PKCS1-v1.5 and Ed25519 always produce the same signature for the same data.++To list the signing algorithms for a key, call [the signing algorithms endpoint](/api-reference/endpoints/kms/signing/signing-algorithms).++## Sign data++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the key's row, then select **Sign Data**.+ </Step>+ <Step>+ Enter your data in **Data to Sign**, and pick a **Signing Algorithm**. If your data is already Base64 encoded, turn on **Data is Base64 encoded**.+ </Step>+ <Step>+ Select **Sign**, then copy the signature from **Data Signature**.+ </Step>+ </Steps>+ </Tab>+ <Tab title="API">+ Base64 encode your data, then call [the sign endpoint](/api-reference/endpoints/kms/signing/sign) with the key's ID and a signing algorithm:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/sign \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "data": "SGVsbG8sIFdvcmxkIQ==",+ "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"+ }'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>++ The response contains the Base64-encoded signature:++ ```json+ {+ "signature": "<base64-encoded-signature>",+ "keyId": "<key-id>",+ "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"+ }+ ```+ </Tab>+</Tabs>++## Verify a signature++<Tabs>+ <Tab title="Infisical UI">+ <Steps>+ <Step>+ In your KMS project, go to **Overview**, select the options menu on the row of the key that signed the data, then select **Verify Data**.+ </Step>+ <Step>+ Enter the data in **Data to Verify** and the signature in **Signature of Data**, then pick the **Signing Algorithm** that the data was signed with. If your data is already Base64 encoded, turn on **Data is Base64 encoded**.+ </Step>+ <Step>+ Select **Verify**. **Signature Status** shows **Valid** if the signature matches the data, and **Invalid** if it doesn't.+ </Step>+ </Steps>+ </Tab>+ <Tab title="API">+ Call [the verify endpoint](/api-reference/endpoints/kms/signing/verify) with the ID of the key that signed the data:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/verify \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "data": "SGVsbG8sIFdvcmxkIQ==",+ "signature": "<base64-encoded-signature>",+ "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"+ }'+ ```++ <Note>+ If you use EU Cloud or self-host Infisical, replace `https://app.infisical.com` with `https://eu.infisical.com` or the address of your instance.+ </Note>++ In the response, `signatureValid` is `true` if the signature matches the data:++ ```json+ {+ "signatureValid": true,+ "keyId": "<key-id>",+ "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512"+ }+ ```++ To verify signatures without calling Infisical, get the key's public key from [the public key endpoint](/api-reference/endpoints/kms/keys/public-key).+ </Tab>+</Tabs>++## Sign a digest++If your data is large, or you don't want to send it to Infisical, you can hash the data yourself and sign the hash (the digest) instead. Digests work only with the `RSASSA_PKCS1_V1_5_*` and `ECDSA_*` signing algorithms.++<Steps>+ <Step>+ Hash your data with the hash function in the signing algorithm's name, and Base64 encode the result. For example, for `RSASSA_PKCS1_V1_5_SHA_512`, create a SHA-512 digest:++ ```bash+ echo -n "Hello, World" | openssl dgst -sha512 -binary | openssl base64 -A+ ```+ </Step>+ <Step>+ Call [the sign endpoint](/api-reference/endpoints/kms/signing/sign) with the digest as `data`, and add `"isDigest": true`:++ ```bash+ curl --request POST \+ --url https://app.infisical.com/api/v1/kms/keys/<key-id>/sign \+ --header 'Authorization: Bearer <access-token>' \+ --header 'Content-Type: application/json' \+ --data '{+ "data": "<base64-encoded-digest>",+ "signingAlgorithm": "RSASSA_PKCS1_V1_5_SHA_512",+ "isDigest": true+ }'+ ```+ </Step>+</Steps>++To verify a signature over a digest, send the digest and `"isDigest": true` to [the verify endpoint](/api-reference/endpoints/kms/signing/verify) in the same way.diff --git a/docs/documentation/platform/kms/sigstore-cosign.mdx b/docs/documentation/platform/kms/sigstore-cosign.mdxindex aa252f00e6..383d6cd278 100644--- a/docs/documentation/platform/kms/sigstore-cosign.mdx+++ b/docs/documentation/platform/kms/sigstore-cosign.mdx@@ -1,71 +1,75 @@----title: "Sigstore Cosign integration"-description: "Sign and verify container images and artifacts using Infisical KMS with Sigstore Cosign."+title: "Sign container images with Sigstore Cosign"+sidebarTitle: "Sigstore Cosign"+description: "Sign container images with a key in Infisical KMS."----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.+[Sigstore Cosign](https://github.com/sigstore/cosign) signs container images and other artifacts. With the [sigstore-kms-infisical](https://github.com/Infisical/sigstore-kms-infisical) plugin, Cosign signs with a [Sign/Verify key](/documentation/platform/kms/sign-verify) in Infisical KMS, so the private key never leaves Infisical.-### KMS plugin capabilities+The plugin supports RSA-4096 keys (the default) and ECC-NIST-P256 keys.-| Capability | Supported |-| ---------- | --------- |-| DefaultAlgorithm | RSA_4096 |-| SupportedAlgorithms | RSA_4096, ECC_NIST_P256 |-| CreateKey | ✅ |-| PublicKey | ✅ |-| SignMessage | ✅ |-| VerifyMessage | ✅ |+## Prerequisites-## Setup+- [Cosign](https://docs.sigstore.dev/cosign/system_config/installation/) and [Go](https://go.dev/doc/install) installed+- A [machine identity](/documentation/platform/identities/machine-identities) with [Universal Auth](/documentation/platform/identities/universal-auth), and the **Member** role in your KMS project-<Steps>- <Step title="Install the Plugin">- For the Sigstore library to invoke the plugin, the binary must be in your system's `PATH`.+## Step 1: Install the plugin- ```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- ```- </Step>+Build the plugin, and put it in a directory on your `PATH` so Cosign can find it:- <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.+```bash+git clone https://github.com/Infisical/sigstore-kms-infisical.git+cd sigstore-kms-infisical+go build -o sigstore-kms-infisical+sudo cp sigstore-kms-infisical /usr/local/bin+```++## Step 2: Set the plugin's credentials- Set the following environment variables:+Set the following environment variables with your machine identity's credentials and the ID of your KMS project:++```bash+export INFISICAL_UNIVERSAL_AUTH_CLIENT_ID="<machine-identity-client-id>"+export INFISICAL_UNIVERSAL_AUTH_CLIENT_SECRET="<machine-identity-client-secret>"+export INFISICAL_PROJECT_ID="<kms-project-id>"+```- ```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>"- ```+The plugin reads the following environment variables:- <Note>- For self-hosted Infisical instances, set `INFISICAL_SITE_URL` to your instance's URL.- </Note>- </Step>-</Steps>+<ResponseField name="INFISICAL_UNIVERSAL_AUTH_CLIENT_ID" type="string" required>+The client ID of your machine identity's Universal Auth.+</ResponseField>-## Usage+<ResponseField name="INFISICAL_UNIVERSAL_AUTH_CLIENT_SECRET" type="string" required>+A client secret for your machine identity's Universal Auth.+</ResponseField>-### Signing a container image+<ResponseField name="INFISICAL_PROJECT_ID" type="string" required>+The ID of the KMS project that your keys are in.+</ResponseField>++<ResponseField name="INFISICAL_SITE_URL" type="string" default="https://app.infisical.com">+The address of Infisical. If you use EU Cloud, set it to `https://eu.infisical.com`. If you self-host Infisical, set it to the address of your instance.+</ResponseField>++## Step 3: Sign and verify images++In each command, `<key-name>` is the name of a Sign/Verify key in your KMS project.++To sign an image:```bash-cosign sign --key "infisical://{KMS_KEY_NAME}" --tlog-upload=false my-repo/image:v1+cosign sign --key "infisical://<key-name>" --tlog-upload=false my-repo/image:v1```-### Verifying a container image+To verify an image:```bash-cosign verify --key "infisical://{KMS_KEY_NAME}" --insecure-ignore-tlog=true my-repo/image:v1+cosign verify --key "infisical://<key-name>" --insecure-ignore-tlog=true my-repo/image:v1```-### Creating a new key pair+If you don't have a key yet, Cosign can create an RSA-4096 key in your KMS project:```bash-cosign generate-key-pair --kms infisical://{NEW_KEY_NAME}+cosign generate-key-pair --kms "infisical://<key-name>"```--This creates an RSA 4096 KMS key with the specified name, which you can then use for signing and verification.diff --git a/docs/images/kmip-diagram.png b/docs/images/kmip-diagram.pngdeleted file mode 100644index cc56607a22..0000000000Binary files a/docs/images/kmip-diagram.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-add-key-modal.png b/docs/images/platform/kms/infisical-kms/kms-add-key-modal.pngdeleted file mode 100644index 9d27f80aa4..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-add-key-modal.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-add-key.png b/docs/images/platform/kms/infisical-kms/kms-add-key.pngdeleted file mode 100644index cbad968d52..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-add-key.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-bulk-export.png b/docs/images/platform/kms/infisical-kms/kms-bulk-export.pngdeleted file mode 100644index 22302ac383..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-bulk-export.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-decrypt-data.png b/docs/images/platform/kms/infisical-kms/kms-decrypt-data.pngdeleted file mode 100644index a71f984f7c..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-decrypt-data.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-decrypt-options.png b/docs/images/platform/kms/infisical-kms/kms-decrypt-options.pngdeleted file mode 100644index ea20e72129..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-decrypt-options.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-decrypted-data.png b/docs/images/platform/kms/infisical-kms/kms-decrypted-data.pngdeleted file mode 100644index ec0ad6d50d..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-decrypted-data.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-encrypt-data.png b/docs/images/platform/kms/infisical-kms/kms-encrypt-data.pngdeleted file mode 100644index 665c08452e..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-encrypt-data.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-encrypted-data.png b/docs/images/platform/kms/infisical-kms/kms-encrypted-data.pngdeleted file mode 100644index fa3cb5f550..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-encrypted-data.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-import-modal.png b/docs/images/platform/kms/infisical-kms/kms-import-modal.pngdeleted file mode 100644index 49077fcf53..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-import-modal.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-import-preview.png b/docs/images/platform/kms/infisical-kms/kms-import-preview.pngdeleted file mode 100644index 6408ee6338..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-import-preview.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/kms-key-options.png b/docs/images/platform/kms/infisical-kms/kms-key-options.pngdeleted file mode 100644index 81df27c79b..0000000000Binary files a/docs/images/platform/kms/infisical-kms/kms-key-options.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/signing/add-new-rsa-key.png b/docs/images/platform/kms/infisical-kms/signing/add-new-rsa-key.pngdeleted file mode 100644index 5dca98fa88..0000000000Binary files a/docs/images/platform/kms/infisical-kms/signing/add-new-rsa-key.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/signing/copy-signature.png b/docs/images/platform/kms/infisical-kms/signing/copy-signature.pngdeleted file mode 100644index 658d113084..0000000000Binary files a/docs/images/platform/kms/infisical-kms/signing/copy-signature.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/signing/sign-data-modal.png b/docs/images/platform/kms/infisical-kms/signing/sign-data-modal.pngdeleted file mode 100644index 09465da941..0000000000Binary files a/docs/images/platform/kms/infisical-kms/signing/sign-data-modal.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/signing/sign-options.png b/docs/images/platform/kms/infisical-kms/signing/sign-options.pngdeleted file mode 100644index 0ffa2030ec..0000000000Binary files a/docs/images/platform/kms/infisical-kms/signing/sign-options.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/signing/signature-verified.png b/docs/images/platform/kms/infisical-kms/signing/signature-verified.pngdeleted file mode 100644index ef2a79cef7..0000000000Binary files a/docs/images/platform/kms/infisical-kms/signing/signature-verified.png and /dev/null differdiff --git a/docs/images/platform/kms/infisical-kms/signing/verify-data-modal.png b/docs/images/platform/kms/infisical-kms/signing/verify-data-modal.pngdeleted file mode 100644index 69f90d0563..0000000000Binary files a/docs/images/platform/kms/infisical-kms/signing/verify-data-modal.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-assign-custom-role-proxy.png b/docs/images/platform/kms/kmip/kmip-assign-custom-role-proxy.pngdeleted file mode 100644index 498fc20128..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-assign-custom-role-proxy.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-assign-mi-to-role.png b/docs/images/platform/kms/kmip/kmip-assign-mi-to-role.pngdeleted file mode 100644index 93d4c7f84f..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-assign-mi-to-role.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-client-modal.png b/docs/images/platform/kms/kmip/kmip-client-modal.pngdeleted file mode 100644index 5038c2a877..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-client-modal.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-client-overview.png b/docs/images/platform/kms/kmip/kmip-client-overview.pngdeleted file mode 100644index 794a91d429..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-client-overview.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-create-custom-role.png b/docs/images/platform/kms/kmip/kmip-create-custom-role.pngdeleted file mode 100644index 5e6a5145dd..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-create-custom-role.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-create-mi.png b/docs/images/platform/kms/kmip/kmip-create-mi.pngdeleted file mode 100644index ed8a0988c9..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-create-mi.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-org-setup-modal.png b/docs/images/platform/kms/kmip/kmip-org-setup-modal.pngdeleted file mode 100644index 6fc6dd7ce8..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-org-setup-modal.png and /dev/null differdiff --git a/docs/images/platform/kms/kmip/kmip-org-setup-navigation.png b/docs/images/platform/kms/kmip/kmip-org-setup-navigation.pngdeleted file mode 100644index 5a77878e5a..0000000000Binary files a/docs/images/platform/kms/kmip/kmip-org-setup-navigation.png and /dev/null differdiff --git a/frontend/src/pages/kms/KmipPage/components/KmipClientTable.tsx b/frontend/src/pages/kms/KmipPage/components/KmipClientTable.tsxindex dc474e35f6..b2c4ae5c9d 100644--- a/frontend/src/pages/kms/KmipPage/components/KmipClientTable.tsx+++ b/frontend/src/pages/kms/KmipPage/components/KmipClientTable.tsx@@ -140,7 +140,7 @@ export const KmipClientTable = () => {<CardHeader><CardTitle>KMIP Clients- <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms" />+ <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms/kmip-clients" /></CardTitle><CardDescription>Manage clients that connect to this project's KMIP server.diff --git a/frontend/src/pages/kms/OverviewPage/components/CmekTable.tsx b/frontend/src/pages/kms/OverviewPage/components/CmekTable.tsxindex 2bb3b38af6..27cba7f956 100644--- a/frontend/src/pages/kms/OverviewPage/components/CmekTable.tsx+++ b/frontend/src/pages/kms/OverviewPage/components/CmekTable.tsx@@ -350,7 +350,7 @@ export const CmekTable = () => {<CardHeader><CardTitle>Keys- <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms" />+ <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms/keys" /></CardTitle><CardDescription>Manage keys and perform cryptographic operations.</CardDescription><CardAction>diff --git a/frontend/src/pages/organization/KmipServersPage/KmipServerDetailsByIDPage/components/KmipServerClientsSection/KmipServerClientsSection.tsx b/frontend/src/pages/organization/KmipServersPage/KmipServerDetailsByIDPage/components/KmipServerClientsSection/KmipServerClientsSection.tsxindex 89bbd6dd10..dae90f76e7 100644--- a/frontend/src/pages/organization/KmipServersPage/KmipServerDetailsByIDPage/components/KmipServerClientsSection/KmipServerClientsSection.tsx+++ b/frontend/src/pages/organization/KmipServersPage/KmipServerDetailsByIDPage/components/KmipServerClientsSection/KmipServerClientsSection.tsx@@ -20,7 +20,7 @@ export const KmipServerClientsSection = () => {<CardHeader><CardTitle><h2 id="kmip-server-clients-title">Connecting KMIP Clients</h2>- <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms/kmip" />+ <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms/kmip-clients" /></CardTitle><CardDescription>KMIP clients authenticate to this server with a client certificate to run key operations.diff --git a/frontend/src/pages/organization/KmipServersPage/components/KmipServerTab.tsx b/frontend/src/pages/organization/KmipServersPage/components/KmipServerTab.tsxindex 06927fb89a..aefe2596bf 100644--- a/frontend/src/pages/organization/KmipServersPage/components/KmipServerTab.tsx+++ b/frontend/src/pages/organization/KmipServersPage/components/KmipServerTab.tsx@@ -101,7 +101,7 @@ export const KmipServerTab = withPermission(<CardHeader><CardTitle>KMIP Servers- <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms/kmip" />+ <DocumentationLinkBadge href="https://infisical.com/docs/documentation/platform/kms/kmip-server" /></CardTitle><CardDescription>Create and configure KMIP servers that proxy KMIP requests to Infisical KMS