AWS Secrets Manager Integration
AWS Secrets Manager is a managed service from Amazon Web Services (AWS) that helps securely store, manage, and retrieve secrets. Secret manager supports remote access to their vaults, which we use for this integration.
Creating a Credential Secret
Step One: In AWS, Create a User and Access Keys
- Go To IAM Dashboard.
- Click Users in the left menu under Access management. The Users page appears.
- Click the Create User button. The Specify User Details page of the Create User wizard appears.
- Type the user name in the User Name text box.
- Click the Next button. The Set Permissions page appears.
- Next, you create a new group for the user or add the user to an existing one. Click the desired existing group or click the Create Group button to create one. To create a new group, see Creating an AWS Group in IAM Dashboard.
- Returning to the Set Permissions page, click to select the check box next to the group you want to add the user to.
- Click the Next button. The Review and Create page appears.
- Ensure the user details are correct.
- Click the Create User button. The new user appears in the table.
- Click on the new user name in the table. That user's details page appears.
- In the Summary section, on the right, click the Create Access Key link. The Create Access Key page appears.
- Click to select the Use Case Third-Party Service selection button.
- Click the Next button. The Set Description Tag - Optional page appears.
- Type
Secret Server External Vault Integration
in the Description Tag Value text box. - Click the Create Access Key button. The new key is created, and the Retrieve Access Keys page appears. You will see an access key and secret access key. These, along with the username will be needed in Secret Server. Record the values.
Step Two: In Secret Server, Create a Secret
- Go to the All Secrets page.
- Click the Create Secret button. The Create New Secret page appears.
- Click the Choose a Secret Template list and select Amazon IAM Key.
- Click the Create Secret button. The Create New Secrets (details) page appears.
- Fill in the text boxes with asterisks for the username, access key, and secret access key using the recorded values from the last step.
- Type any name you wish in the Secret Name text box.
- Once again, click the Create Secret button. The new secret appears in the All Secrets list.
Step Three: Create an AWS Secrets Manager Link
- Return to the secrets menu and click External Secrets. A page of the same name appears.
- Click to select the Enabled check box if you want to push changes to the vault. Leave it unchecked if you do not want to push changes to it.
- Click the Create button. The Create External Vault Link page appears.
- Select AWS Secret Manager in the Type dropdown list.
- Click the link for the secret you created.
- If you are using the automatic list feature for external vaults:
- You are automatically presented all available vaults for your AWS subscriptions, and Input type is set to Automatic List. Once the AWS key vault account connects, a green Connected indicator appears at the top of the page.
- Click to select the check boxes for the desired vaults.
- If you are not using the automatic list feature:
- Set Input Type to Manual Entry.
- Type the name of the AWS key vault you want to connect with in the Name text box. The name must exactly match the name of the key vault.
- Type your name for the external vault in the Display Name text box.
- Once you have the correct region, click the Save button.
Creating an AWS Group in IAM Dashboard
- Return to IAM Dashboard.
- Click User Groups in the Access Management group in the menu on the left. The User Groups page appears.
- Click the Create Group button. The Name the Group page appears.
- Type a name in the User Group Name text box.
- Add the credential secret if needed.
- Add needed permission policies. The included, default SecretsManagerReadWrite policy in the Attach Permissions Policies table should suffice. If not, add other policies via the search text box in the same section. See Creating Custom AWS Policies for details.
- Click the Create User Group Button.
Creating Custom AWS Policies
-
Go To IAM Dashboard.
-
Click Policies in the left menu under Access management. The Policies page appears.
-
Click Create Policy. Specify Permissions appears.
-
Click the Filter by Type dropdown list and select Secrets Manager. The Secrets Manager section appears.
-
Select Actions Allowed to view that section. The Access Levels appear.
-
In the List section, click to select the List Secrets checkbox.
-
In the Read section, click to select:
- DescribeSecret
- GetSecretValue
- ListSecretVersionIds
-
In the Write section, click to select:
- CreateSecret
- PutSecretValue
- UpdateSecretVersionStage
-
Click the expand the Resources section.
-
Click to select the All selection button. This allows you to manage all secrets in AWS. For a smaller subset, select Specific and scope it to what secrets you want to access.
-
Click the Next button at the bottom. The Review and Create page appears.
-
Complete the remaining policy details.
-
Click the Create Policy button.