Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

docs: added docs for ssh-password rotation

=907948f44540
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/create.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/create.mdx
new file mode 100644
index 0000000000..0818c66eb2
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/create.mdx
@@ -0,0 +1,9 @@
+---
+title: "Create"
+openapi: "POST /api/v2/secret-rotations/ssh-password"
+---
+
+<Note>
+ Check out the configuration docs for [SSH Password Rotations](/documentation/platform/secret-rotation/ssh-password) to learn how to obtain the
+ required parameters.
+</Note>
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/delete.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/delete.mdx
new file mode 100644
index 0000000000..ac294e060b
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/delete.mdx
@@ -0,0 +1,4 @@
+---
+title: "Delete"
+openapi: "DELETE /api/v2/secret-rotations/ssh-password/{rotationId}"
+---
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/get-by-id.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/get-by-id.mdx
new file mode 100644
index 0000000000..c731484df4
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/get-by-id.mdx
@@ -0,0 +1,4 @@
+---
+title: "Get by ID"
+openapi: "GET /api/v2/secret-rotations/ssh-password/{rotationId}"
+---
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/get-by-name.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/get-by-name.mdx
new file mode 100644
index 0000000000..ea9907bfab
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/get-by-name.mdx
@@ -0,0 +1,4 @@
+---
+title: "Get by Name"
+openapi: "GET /api/v2/secret-rotations/ssh-password/rotation-name/{rotationName}"
+---
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/get-generated-credentials-by-id.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/get-generated-credentials-by-id.mdx
new file mode 100644
index 0000000000..75815b4c0d
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/get-generated-credentials-by-id.mdx
@@ -0,0 +1,4 @@
+---
+title: "Get Credentials by ID"
+openapi: "GET /api/v2/secret-rotations/ssh-password/{rotationId}/generated-credentials"
+---
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/list.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/list.mdx
new file mode 100644
index 0000000000..959dc500ec
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/list.mdx
@@ -0,0 +1,4 @@
+---
+title: "List"
+openapi: "GET /api/v2/secret-rotations/ssh-password"
+---
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/reconcile.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/reconcile.mdx
new file mode 100644
index 0000000000..9c6b21d2df
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/reconcile.mdx
@@ -0,0 +1,4 @@
+---
+title: "Reconcile"
+openapi: "POST /api/v2/secret-rotations/ssh-password/{rotationId}/reconcile"
+---
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/rotate-secrets.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/rotate-secrets.mdx
new file mode 100644
index 0000000000..7c62cb8a7d
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/rotate-secrets.mdx
@@ -0,0 +1,4 @@
+---
+title: "Rotate Secrets"
+openapi: "POST /api/v2/secret-rotations/ssh-password/{rotationId}/rotate-secrets"
+---
diff --git a/docs/api-reference/endpoints/secret-rotations/ssh-password/update.mdx b/docs/api-reference/endpoints/secret-rotations/ssh-password/update.mdx
new file mode 100644
index 0000000000..59f4bc47a2
--- /dev/null
+++ b/docs/api-reference/endpoints/secret-rotations/ssh-password/update.mdx
@@ -0,0 +1,9 @@
+---
+title: "Update"
+openapi: "PATCH /api/v2/secret-rotations/ssh-password/{rotationId}"
+---
+
+<Note>
+ Check out the configuration docs for [SSH Password Rotations](/documentation/platform/secret-rotation/ssh-password) to learn how to obtain the
+ required parameters.
+</Note>
diff --git a/docs/docs.json b/docs/docs.json
index c7c47f10a6..8559b5d4a0 100644
--- a/docs/docs.json
+++ b/docs/docs.json
@@ -132,6 +132,7 @@
"integrations/app-connections/humanitec",
"integrations/app-connections/laravel-forge",
"integrations/app-connections/ldap",
+ "integrations/app-connections/ssh",
"integrations/app-connections/mssql",
"integrations/app-connections/mongodb",
"integrations/app-connections/mysql",
@@ -450,6 +451,7 @@
"documentation/platform/secret-rotation/azure-client-secret",
"documentation/platform/secret-rotation/databricks-service-principal-secret",
"documentation/platform/secret-rotation/ldap-password",
+ "documentation/platform/secret-rotation/ssh-password",
"documentation/platform/secret-rotation/mongodb-credentials",
"documentation/platform/secret-rotation/mssql-credentials",
"documentation/platform/secret-rotation/mysql-credentials",
@@ -2011,6 +2013,20 @@
"api-reference/endpoints/secret-rotations/ldap-password/update"
]
},
+ {
+ "group": "SSH Password",
+ "pages": [
+ "api-reference/endpoints/secret-rotations/ssh-password/create",
+ "api-reference/endpoints/secret-rotations/ssh-password/delete",
+ "api-reference/endpoints/secret-rotations/ssh-password/get-by-id",
+ "api-reference/endpoints/secret-rotations/ssh-password/get-by-name",
+ "api-reference/endpoints/secret-rotations/ssh-password/get-generated-credentials-by-id",
+ "api-reference/endpoints/secret-rotations/ssh-password/list",
+ "api-reference/endpoints/secret-rotations/ssh-password/rotate-secrets",
+ "api-reference/endpoints/secret-rotations/ssh-password/update",
+ "api-reference/endpoints/secret-rotations/ssh-password/reconcile"
+ ]
+ },
{
"group": "Microsoft SQL Server Credentials",
"pages": [
diff --git a/docs/documentation/platform/secret-rotation/ssh-password.mdx b/docs/documentation/platform/secret-rotation/ssh-password.mdx
new file mode 100644
index 0000000000..38e93a2e50
--- /dev/null
+++ b/docs/documentation/platform/secret-rotation/ssh-password.mdx
@@ -0,0 +1,187 @@
+---
+title: "SSH Password Rotation"
+description: "Learn how to automatically rotate SSH passwords."
+---
+
+<Note>
+ Due to how SSH passwords are rotated, retired credentials will not be able to
+ authenticate with the SSH provider during their [inactive period](./overview#how-rotation-works).
+
+ This is a limitation of the SSH provider and cannot be
+ rectified by Infisical.
+</Note>
+
+## Prerequisites
+
+- Create an [SSH Connection](/integrations/app-connections/ssh) with the **Secret Rotation** requirements
+- Ensure your network security policies allow incoming requests from Infisical to this rotation provider, if network restrictions apply.
+
+## Create an SSH Password Rotation in Infisical
+
+<Tabs>
+ <Tab title="Infisical UI">
+ 1. Navigate to your Secret Manager Project's Dashboard and select **Add Secret Rotation** from the actions dropdown.
+ ![Secret Manager Dashboard](/images/secret-rotations-v2/generic/add-secret-rotation.png)
+
+ 2. Select the **SSH Password** option.
+ ![Select SSH Password](/images/secret-rotations-v2/ssh-password/select-ssh-password-option.png)
+
+ 3. Select the **SSH Connection** to use and configure the rotation behavior. Then click **Next**.
+ ![Rotation Configuration](/images/secret-rotations-v2/ssh-password/ssh-password-configuration.png)
+
+ - **SSH Connection** - the connection that will perform the rotation of the configured user's password.
+ - **Rotation Interval** - the interval, in days, that once elapsed will trigger a rotation.
+ - **Rotate At** - the local time of day when rotation should occur once the interval has elapsed.
+ - **Auto-Rotation Enabled** - whether secrets should automatically be rotated once the rotation interval has elapsed. Disable this option to manually rotate secrets or pause secret rotation.
+ <Note>
+ Due to SSH Password Rotations rotating a single credential set, auto-rotation may result in service interruptions. If you need to ensure service continuity, we recommend disabling this option.
+ </Note>
+
+
+ 4. Configure the required Parameters for your rotation. Then click **Next**.
+ ![Rotation Parameters](/images/secret-rotations-v2/ssh-password/ssh-password-parameters.png)
+
+ - **Rotation Method** - The method to use when rotating the target user's password.
+ - **Login as Target** - Infisical will use the provided SSH username and password to log in and rotate its own password.
+ - **Login as Root** - Infisical will use the SSH Connection's credentials to log in and rotate the provided user's password.
+ - **Username** - The target SSH username whose password will be rotated.
+ - **Current Password** - The current password of the target user (required when **Rotation Method** is set to **Login as Target**).
+ - **Password Requirements** - The constraints to apply when generating new passwords.
+
+ 5. Specify the secret names that the SSH credentials should be mapped to. Then click **Next**.
+ ![Rotation Secrets Mapping](/images/secret-rotations-v2/ssh-password/ssh-password-secrets-mapping.png)
+
+ - **Username** - the name of the secret that the SSH username will be stored in.
+ - **Password** - the name of the secret that the rotated password will be stored in.
+
+ 6. Give your rotation a name and description (optional). Then click **Next**.
+ ![Rotation Details](/images/secret-rotations-v2/ssh-password/ssh-password-details.png)
+
+ - **Name** - the name of the secret rotation configuration. Must be slug-friendly.
+ - **Description** (optional) - a description of this rotation configuration.
+
+ 7. Review your configuration, then click **Create Secret Rotation**.
+ ![Rotation Review](/images/secret-rotations-v2/ssh-password/ssh-password-confirm.png)
+
+ 8. Your **SSH Password** credentials are now available for use via the mapped secrets.
+ ![Rotation Created](/images/secret-rotations-v2/ssh-password/ssh-password-created.png)
+
+ ### Reconcile SSH Password
+
+ If you suspect the credentials are out of sync (for example, after a manual password change on the server), you can regain access by using **Reconcile SSH**. This will use the configured SSH App Connection's root account to reset the target user's password and sync it with Infisical.
+
+ ![Reconcile Option](/images/secret-rotations-v2/ssh-password/ssh-password-reconcile.png)
+ ![Reconcile Confirmation](/images/secret-rotations-v2/ssh-password/ssh-password-reconcile-confirm.png)
+ </Tab>
+ <Tab title="API">
+ To create an SSH Password Rotation, make an API request to the [Create SSH
+ Password Rotation](/api-reference/endpoints/secret-rotations/ssh-password/create) API endpoint.
+
+ ### Sample request
+
+ ```bash Request
+ curl --request POST \
+ --url https://us.infisical.com/api/v2/secret-rotations/ssh-password \
+ --header 'Content-Type: application/json' \
+ --data '{
+ "name": "my-ssh-rotation",
+ "projectId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "description": "my ssh password rotation",
+ "connectionId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "environment": "dev",
+ "secretPath": "/",
+ "isAutoRotationEnabled": false,
+ "rotationInterval": 30,
+ "rotateAtUtc": {
+ "hours": 0,
+ "minutes": 0
+ },
+ "parameters": {
+ "rotationMethod": "login-as-root",
+ "username": "appuser",
+ "passwordRequirements": {
+ "length": 48,
+ "required": {
+ "digits": 2,
+ "lowercase": 2,
+ "uppercase": 2,
+ "symbols": 2
+ },
+ "allowedSymbols": "-_.~!*"
+ }
+ },
+ "secretsMapping": {
+ "username": "SSH_USERNAME",
+ "password": "SSH_PASSWORD"
+ }
+ }'
+ ```
+
+ <Note>
+ Due to SSH Password Rotations rotating a single credential set, auto-rotation may result in service interruptions. If you need to ensure service continuity, we recommend disabling this option.
+ </Note>
+
+ ### Sample response
+
+ ```bash Response
+ {
+ "secretRotation": {
+ "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "name": "my-ssh-rotation",
+ "description": "my ssh password rotation",
+ "secretsMapping": {
+ "username": "SSH_USERNAME",
+ "password": "SSH_PASSWORD"
+ },
+ "isAutoRotationEnabled": false,
+ "activeIndex": 0,
+ "folderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "connectionId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "createdAt": "2023-11-07T05:31:56Z",
+ "updatedAt": "2023-11-07T05:31:56Z",
+ "rotationInterval": 30,
+ "rotationStatus": "success",
+ "lastRotationAttemptedAt": "2023-11-07T05:31:56Z",
+ "lastRotatedAt": "2023-11-07T05:31:56Z",
+ "lastRotationJobId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "nextRotationAt": "2023-11-07T05:31:56Z",
+ "connection": {
+ "app": "ssh",
+ "name": "my-ssh-connection",
+ "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
+ },
+ "environment": {
+ "slug": "dev",
+ "name": "Development",
+ "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
+ },
+ "projectId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "folder": {
+ "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
+ "path": "/"
+ },
+ "rotateAtUtc": {
+ "hours": 0,
+ "minutes": 0
+ },
+ "lastRotationMessage": null,
+ "type": "ssh-password",
+ "parameters": {
+ "rotationMethod": "login-as-root",
+ "username": "appuser",
+ "passwordRequirements": {
+ "length": 48,
+ "required": {
+ "digits": 2,
+ "lowercase": 2,
+ "uppercase": 2,
+ "symbols": 2
+ },
+ "allowedSymbols": "-_.~!*"
+ }
+ }
+ }
+ }
+ ```
+ </Tab>
+</Tabs>
diff --git a/docs/images/secret-rotations-v2/ssh-password/select-ssh-password-option.png b/docs/images/secret-rotations-v2/ssh-password/select-ssh-password-option.png
new file mode 100644
index 0000000000..13e9fbb9d4
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/select-ssh-password-option.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-configuration.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-configuration.png
new file mode 100644
index 0000000000..e5b5a62e50
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-configuration.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-confirm.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-confirm.png
new file mode 100644
index 0000000000..dbd0901ecb
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-confirm.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-created.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-created.png
new file mode 100644
index 0000000000..098cbc3e1a
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-created.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-details.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-details.png
new file mode 100644
index 0000000000..2651e5d931
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-details.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-parameters.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-parameters.png
new file mode 100644
index 0000000000..2b9ac4b2ab
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-parameters.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-reconcile-confirm.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-reconcile-confirm.png
new file mode 100644
index 0000000000..5922f05bce
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-reconcile-confirm.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-reconcile.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-reconcile.png
new file mode 100644
index 0000000000..96e512a8f1
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-reconcile.png differ
diff --git a/docs/images/secret-rotations-v2/ssh-password/ssh-password-secrets-mapping.png b/docs/images/secret-rotations-v2/ssh-password/ssh-password-secrets-mapping.png
new file mode 100644
index 0000000000..d6b710881f
Binary files /dev/null and b/docs/images/secret-rotations-v2/ssh-password/ssh-password-secrets-mapping.png differ
diff --git a/docs/snippets/RotationsBrowser.jsx b/docs/snippets/RotationsBrowser.jsx
index 524aafd5c9..5bb813f350 100644
--- a/docs/snippets/RotationsBrowser.jsx
+++ b/docs/snippets/RotationsBrowser.jsx
@@ -4,7 +4,7 @@ export const RotationsBrowser = () => {
const [searchTerm, setSearchTerm] = useState("");
const [selectedCategory, setSelectedCategory] = useState("All");
- const categories = ["All", "Databases", "Identity & Auth", "Cloud Providers"];
+ const categories = ["All", "Databases", "Identity & Auth", "Cloud Providers", "Networking & DNS"];
const rotations = [
{
@@ -51,6 +51,13 @@ export const RotationsBrowser = () => {
description: "Learn how to automatically rotate LDAP user passwords.",
category: "Identity & Auth",
},
+ {
+ name: "SSH Password",
+ slug: "ssh-password",
+ path: "/documentation/platform/secret-rotation/ssh-password",
+ description: "Learn how to automatically rotate SSH password of a user.",
+ category: "Networking & DNS",
+ },
{
name: "MySQL",
slug: "mysql-credentials",