Closed roamingthings closed 4 months ago
The token used in the header does not need to be a session token. We accept AWS_SESSION_TOKEN
as a environment variable to source the token value in order to provide intercompatibility between this agent and the AWS Parameters and Secrets Lambda Extension.
Prefer the use of environment variable AWS_TOKEN
so set the agent SSRF token in your case.
The Secrets Manager Agent requires a session token in the
X-Aws-Parameters-Secrets-Token
header. When a Lambda Function is using SnapStart this token is not available. Instead container credentials are used.For this reason, it's currently not possible to use the AWS Secrets Manager Agent with Lambda Functions that have SnapStart enabled.
Here is a code snipped that demonstrates the issue:
In case the header is omitted the agent will reject the request as documented.