A company is migrating a legacy HR application to Amazon EC2 instances. The application requires access to a database password that must be rotated every 60 days to comply with internal security policies. The database is hosted on Amazon RDS. The security team mandates that the password must be encrypted at rest using a customer managed key, and that the rotation process must be automated with minimal operational effort.
Which solution should a solutions architect recommend to meet these requirements?
- AStore the database password as a String parameter in AWS Systems Manager Parameter Store. Write a custom script on the EC2 instances that runs every 60 days via a cron job to retrieve the plaintext password, generate a new password, and update the database.
- BStore the database password as a SecureString parameter in AWS Systems Manager Parameter Store and encrypt it using a customer managed KMS key. Enable automatic rotation on the customer managed KMS key with a rotation period of 60 days to automatically update the password value.
- Store the database password in AWS Secrets Manager and encrypt it using an AWS Key Management Service (AWS KMS) customer managed key. Configure Secrets Manager to automatically rotate the password every 60 days using a configured AWS Lambda function.Cevap
- DStore the database password in AWS Secrets Manager and encrypt it using an AWS KMS customer managed key. Enable automatic annual rotation on the customer managed KMS key, which will automatically trigger the rotation of the database password and re-encrypt historical database records under the new key version.
Cevap
Store the database password in AWS Secrets Manager, encrypt it using an AWS KMS customer managed key, and configure automatic rotation every 60 days using an AWS Lambda function.
AWS Secrets Manager is designed for storing secrets such as database credentials and supports automated rotation through AWS Lambda. It allows encryption using customer managed AWS KMS keys, which satisfies all the compliance and operational requirements with minimal overhead.
Adım Adım Çözüm
Anahtar Kavram
AWS Secrets Manager supports automatic secrets rotation using AWS Lambda, whereas KMS key rotation only rotates encryption key material and not the stored secret values.
Tahmini Süre:1m 30s