Closed kljunowsky closed 3 months ago
Hi there,
Thanks for reporting! I was not able to reproduce with:
export AWS_REGION=eu-west-1
stratus detonate aws.credential-access.secretsmanager-batch-retrieve-secrets
stratus cleanup aws.credential-access.secretsmanager-batch-retrieve-secrets
stratus detonate aws.credential-access.secretsmanager-batch-retrieve-secrets
The Terraform warmup code does set recovery_window_in_days
to 0
, so the cleanup should nuke the secrets right away: https://github.com/DataDog/stratus-red-team/blob/main/v2/internal/attacktechniques/aws/credential-access/secretsmanager-batch-retrieve-secrets/main.tf#L35
Is it possible that your second detonation happens very quickly after the cleanup? (e.g. less than 10 seconds)
I remember. I used to manually clean up secrets on AWS since I faced issues with stratus cleanup (Expired keys). Triggering and cleaning with stratus works fine. Closing the issue.
What is not working? Re-triggering scenario after celanup. I can not re-run aws.credential-access.secretsmanager-batch-retrieve-secrets because of the same secret naming convention.
Potential solution Change the way secret names are generated, use random strings instead of numbers if possible. If not, if for example
secret-10
exists, try creating secrets fromsecret-11
...What OS are you using? Mac OS X
What is your Stratus Red Team version? 2.15.0
Full output?
Files in $HOME/.stratus-red-team?