My AWS account has Multi Factor Authentication activated it would be nice to add support in your credentials file for the Session token and ephemeral accesskey and secretkey required for MFA enabled API access
With the AWS SDK CLI it works like this:
aws sts get-session-token --serial-number "arn:aws:iam::[ACCOUNT_NUMBER]:mfa/[IAM_USERNAME]" --token-code [COE_FROM_MFA_DEVICE]
I put in my code from Google Authenticator tied to my AWS account and it spits out some JSON:
{
"Credentials": {
"SecretAccessKey": "[Secret Key]",
"SessionToken": "[Session Token]",
"Expiration": "2017-02-25T09:15:03Z",
"AccessKeyId": "[Access key ID]"
}
}
Then I put these keys in my credential file
Otherwise to use your glacieruploader program I have to add another IAM user without the MFA enabled to use a static accesskey and secretkey