Suppose I have the following secret in a Cloud Formation (or SAM) template which I deploy to my AWS IAM account as part of a stack (with of course the sensitive value of the SecretString dynamically assigned by the script that runs the cloud formation deployment):
Resources:
MySecret:
Type: AWS::SecretsManager::Secret
Properties:
Name: MySecret
Description: Embarssing fact I want to keep secret
SecretString: "I_think_Twighlight_Sparkle_is_cool"
When I examine the stack page on the aws console I notice the "template" tab displays the whole template including this secret in plain text.
This seems very undesirable to me, and I am wondering if there is someway of mitigating it that I am missing. While only people with access to the IAM account can go to the aws console, it seems undesirable to have secrets pop up in plain text unless one is specifically requesting to see them.
Anybody know of a good way to mitigate this?