Follow-up to #938 / PR #951.
What
After PR #951 lands and the MDR API redeploys, the future startup logs no longer leak DATABASE_URL. But the previous credential is still in CloudWatch retention history — every prior MDR API task start emitted a log line containing it. Anyone with logs:FilterLogEvents on the shared dev / demo log groups can recover the password by searching old streams.
The leak is only fully closed once we rotate.
Scope
- Rotate
MDRDatabasePassword (or whatever the SSM key is for the Aurora cluster's master password) for both dev and demo.
- Confirm MDR API picks up the new password on its next task start (ECS reads from SSM at task launch).
- Optional: tighten log-group permissions so the next leak is less recoverable (broader cleanup, separate issue).
Steps (rough)
- Identify the current SSM param name(s):
aws ssm describe-parameters --filters Key=Name,Values=mdr-db,Option=Contains.
- Generate a new password (Aurora has constraints — 8–128 chars, ASCII printable except
/, @, ", space).
- Update the password on the Aurora cluster:
aws rds modify-db-cluster --master-user-password <new>.
- Update the SSM param to the new value.
- Force the MDR API service to redeploy so it picks up the new value on next task start:
./aws-deploy.sh -s dev --only-stack dev-lif-mdr-api --update-ecs.
- Verify MDR API health after the rolling deploy completes.
Don't forget
- The flyway/SAM Lambda also pulls the master password from SSM; check it still works on next deploy.
- Other services (GraphQL, translator, etc.) connect to their own DBs, not the MDR DB — they're not in scope here.
Related
Follow-up to #938 / PR #951.
What
After PR #951 lands and the MDR API redeploys, the future startup logs no longer leak
DATABASE_URL. But the previous credential is still in CloudWatch retention history — every prior MDR API task start emitted a log line containing it. Anyone withlogs:FilterLogEventson the shareddev/demolog groups can recover the password by searching old streams.The leak is only fully closed once we rotate.
Scope
MDRDatabasePassword(or whatever the SSM key is for the Aurora cluster's master password) for both dev and demo.Steps (rough)
aws ssm describe-parameters --filters Key=Name,Values=mdr-db,Option=Contains./,@,", space).aws rds modify-db-cluster --master-user-password <new>../aws-deploy.sh -s dev --only-stack dev-lif-mdr-api --update-ecs.Don't forget
Related