How to configure RDS for MySQL access without long-term credentials?
A company has an ecommerce web application that uses an on-premises MySQL database as a data store. The company migrates the on-premises MySQL database to Amazon RDS for MySQL. A developer needs to configure the application's access to the RDS for MySQL database. The developer's solution must not use long term credentials. Which solution will meet these requirements?
Community Votes
64% of anonymous learners picked answer A. Votes are pick records left by other test-takers — they are not the verified answer.
Community Insight
The question specifically requires avoiding long-term credentials, which points directly to IAM database authentication using short-lived 15-minute authentication tokens instead of static passwords.
This question tests the use of IAM database authentication for Amazon RDS for MySQL to eliminate long-term credentials like passwords. The community consensus strongly supports IAM database authentication as the correct approach for short-lived, token-based access.
Many candidates choose option B (AWS Secrets Manager) because it supports credential rotation, but fail to recognize that rotated credentials are still considered long-term credentials that exist for extended periods.
Community Discussion (8 comments)
Comments & Corrections
No comments yet — spotted an error or have a note? Share it below.
Expert Analysis
Understanding the Core Requirement
The critical phrase in this question is "must not use long term credentials." This requirement immediately eliminates traditional username/password authentication methods, even when those credentials are stored securely or rotated automatically.
Why Option A is Correct
IAM database authentication for Amazon RDS for MySQL allows applications to connect to the database using authentication tokens instead of static passwords. These tokens are:
- Generated on-demand using AWS Signature Version 4
- Valid for only 15 minutes
- Completely eliminate the need for stored database passwords
- Managed through IAM roles and policies
rds-db:connect permissions
3. Assigning the role to the application (EC2 instance profile, ECS task role, or Lambda execution role)Why Other Options Fail
Option B (Secrets Manager): While Secrets Manager can automatically rotate credentials, the rotated credentials are still long-term credentials that exist for days, weeks, or months. The question explicitly requires avoiding long-term credentials entirely.
Option C (Environment Variables): This approach uses static credentials that are long-term and presents additional security risks by exposing credentials in configuration.
Option D (Parameter Store): Similar to Secrets Manager, this stores long-term credentials, just in a different AWS service. The credentials remain valid until manually changed.
Community Insights
As noted by community members, the key distinction is that IAM database authentication uses ephemeral tokens (15-minute validity) rather than persistent credentials. This is the only solution that truly eliminates long-term credential storage and management.
Official Reference
Exam Strategy
When you see 'no long-term credentials' or 'short-lived credentials' in AWS exam questions, immediately think of IAM-based authentication methods that use temporary tokens or credentials. Distinguish between credential rotation (still long-term) and credential elimination (truly short-lived).
Related Analysis
Practice All DVA-C02 Questions
Access 100 questions with complete answers and detailed explanations.
View Full DVA-C02 Practice Test →