Add a Rotated Secret to a Role

Access roles provide clients with permission to work with secrets. When you add a secret to a role, you can specify exactly which CRUD operations clients can perform with that secret.

👍

Note

The role to which a Rotated Secret is added must have read, list, and update permissions.

Let’s add a Rotated Secret to a role using the Akeyless CLI. If you’d prefer, see how to do this from the Add a Rotated Secret to a Role instead.

Add a Rotated Secret to a Role from the CLI

The CLI command to add a secret to a role is:

akeyless set-role-rule \
 		--role-name <role name> \
		--path <secret name with path> \
		--capability <read|create|update|delete|list|deny> \
		--rule-type item-rule

The output is:

The requested rule was successfully set to the role <role name>

Add a Rotated Secret to a Role from the Akeyless Console

  1. From the menu on the left, select Access Roles, then select the role to which you want to add the Rotated Secret.

  2. In the role details, select the Items tab, and select Add.

  3. Type the name and path to the Rotated Secret, and select the read, list, and update permissions.

  4. Click Add to save your changes.