What is our primary use case?
In my recent company, we use AWS Secrets Manager for all the applications where we store app-based, app-level secrets. We store all our secrets there. Currently, I'm working with AWS Secrets Manager and all encryption resources. In my company, we are using these secrets for the backend GoLang application. With the help of secrets stored in AWS Secrets Manager, the application fetches the secrets and works accordingly.
AWS Secrets Manager is similar to a vault in our homes where we store important things. We encrypt those items and store them in AWS Secrets Manager so we don't have to carry them around or keep them somewhere unsafe. All the secrets are encrypted and stored in AWS Secrets Manager. The functionality involves taking the secrets and decrypting them, or if not encrypted, using them as they are.
For all applications and resources such as database, MongoDB, Postgres, and everything which needs a username and password, it will be in AWS Secrets Manager. The code is structured to fetch from AWS Secrets Manager so it should not look anywhere else. It's the only place where we keep those important items.
What is most valuable?
The encryption capabilities of AWS Secrets Manager, where we use KMS (Key Management Store), which is an encryption key for AWS resources, are impressive. With KMS, we can encrypt our AWS Secrets Manager. Without access to KMS or AWS Secrets Manager, a person cannot access those items. KMS serves as a key to the vault. The integration between KMS and AWS Secrets Manager is quite astonishing.
We can specify permissions for AWS Secrets Manager through IAM roles and permissions. We can specify independent IAM permissions in AWS Secrets Manager, which is a significant advantage.
AWS Secrets Manager has a retention policy where we can specify how long a secret should exist. There is also version control, so if the secret is updated or values are changed, the secret receives its version. Similar to GitHub and Version Control Systems, we have versions in the secret to track changes and enable rollbacks.
AWS Secrets Manager plays a significant role in optimizing IT infrastructure security and efficiency. It serves an essential purpose because every application, website, or online activity requires authentication credentials. For API usage, an API key is needed. If values don't need to change frequently (static values), they become eligible for AWS Secrets Manager. By keeping everything in one place, the safekeeping of secrets remains under admin control. Without specific IAM permissions or access, nobody can access these secrets. This solves approximately 99% of the problems companies face with secret management.
What needs improvement?
When creating AWS Secrets Manager, it should be automated using tools such as Terraform, Puppet, or Ansible. With Terraform code, you specify the encryption key, secret name, rotation policy, and secret replication. Human error occurs when feeding secret values manually, especially with large amounts of secrets to input.
Secrets should never be protected only by IAM. They should be protected by multiple layers, such as IAM and one or two KMS keys. Additional security measures could be beneficial if necessary. The rotation policy is crucial because some secrets may become obsolete, require updates, or get compromised. With a weekly rotation policy, if unauthorized access occurs, the exposure is limited to seven days. The rotation policy can be customized according to needs.
For how long have I used the solution?
I have been working with AWS Secrets Manager for approximately two years.
What was my experience with deployment of the solution?
AWS Secrets Manager was easy to use because it comes integrated with the AWS infrastructure setup. We didn't need to look for alternatives.
What do I think about the stability of the solution?
AWS Secrets Manager is quite stable as we haven't faced any service-related issues. The issues we encountered were related to developer or configuration problems. The service performs well overall. Any updates or improvements to the resource would be beneficial.
What do I think about the scalability of the solution?
I haven't encountered limit exceeded errors yet, though I'm uncertain about the secret key and value limits. We maintain a substantial number of secrets. When limit exceeded errors occur, it could become problematic since we don't have control over the secrets. As applications and companies grow, the number of secrets increases accordingly.
We can directly edit and feed values in plain text, mentioning the secret key and value in JSON format. This eliminates the need for manual UI input. We can code all secret keys and values and paste them, though this code must remain restricted.
How are customer service and support?
We experienced minimal issues with secrets, but once in production, we encountered a problem where values weren't being fetched from a key. We contacted AWS support and waited approximately an hour for assistance. The issue turned out to be a coding error with incorrect value input. While an hour might not seem significant, in production environments where applications cannot experience downtime, it can impact company operations. I would rate technical support as eight out of ten.
Regarding customer support, we implemented blue-green deployment for zero downtime. When constructing zero-downtime solutions, infrastructure-related downtime becomes problematic. We experienced some challenges before getting back on track.
How would you rate customer service and support?
Which solution did I use previously and why did I switch?
Before AWS Secrets Manager, we used Terraform Vault for our Terraform infrastructure. Terraform Vault serves a similar purpose for secret keeping but is specifically used for Terraform purposes rather than application level management.
How was the initial setup?
The initial stages of AWS Secrets Manager were implemented using Terraform. All configurations visible in the AWS Secrets Manager UI were applied through Terraform. We focused on automating the entire infrastructure to minimize human errors.
To establish the basic structure, I needed to set up the Terraform infrastructure. We weren't authorized to feed values directly into the secret key-value pairs. While direct input would have been simpler, we had to manually add values to prevent secret leakage, as Terraform code resides in repositories with potential access risks.
What other advice do I have?
AWS Secrets Manager, being an AWS resource, operates simply using access keys and secret keys. For third-party applications in our organization, we utilize access keys and secret keys from a user or create dedicated users. When creating an IAM user for secrets, we obtain the access key and secret key, providing necessary permissions following the least privileges principle.
A basic security audit involves controlling access to specific secrets for particular users. When writing policies, we specify AWS Secrets Manager and the exact secret using the resource ARN in the IAM permission JSON code. This ensures users can only access designated resources.
CloudTrail enables tracking user actions, including deletions and updates. It provides various filters for dates, time, users, and user groups, making it feasible to monitor AWS console activities. CloudTrail serves as an effective audit tool for administrators.
This review rates AWS Secrets Manager as 9 out of 10.
Which deployment model are you using for this solution?
Public Cloud
If public cloud, private cloud, or hybrid cloud, which cloud provider do you use?
Amazon Web Services (AWS)