A developer is designing a serverless backend using AWS Lambda that connects to an Amazon RDS for PostgreSQL database. The application security policy requires that database passwords be rotated automatically every 30 days. Additionally, the Lambda function needs to retrieve non-sensitive configuration parameters, such as logging levels and external API endpoints. Which combination of actions should the developer take to implement these requirements securely and cost-effectively? (Select TWO.)
- Store the database credentials in AWS Secrets Manager and configure the built-in automatic rotation for Amazon RDS.Answer
- Store the non-sensitive configuration parameters in AWS Systems Manager Parameter Store as Standard parameters.Answer
- CStore the database credentials in AWS Systems Manager Parameter Store as SecureString parameters and configure built-in automatic rotation.
- DHardcode the database credentials directly within the Lambda function's handler initialization code to avoid API latency.
- EStore the non-sensitive configuration parameters in AWS Secrets Manager to centralize all secrets and configurations.
Answer
Storing the database credentials in AWS Secrets Manager with built-in automatic rotation enabled, and storing the non-sensitive configurations in AWS Systems Manager Parameter Store as Standard parameters.
AWS Secrets Manager is designed for managing secrets such as database credentials and supports automated rotation out of the box, specifically with integrations for Amazon RDS. AWS Systems Manager Parameter Store is ideal for general, non-sensitive configuration parameters because Standard parameters are free, making it the most cost-effective choice for configurations that do not require rotation or encryption.
Step-by-Step Solution
Key Concept
Distinguishing between AWS Secrets Manager and AWS Systems Manager Parameter Store features and cost profiles.