Skip to content

Instantly share code, notes, and snippets.

@michaelwittig
Created August 7, 2015 21:09
Show Gist options
  • Save michaelwittig/06fbbb6566664bfc4fd0 to your computer and use it in GitHub Desktop.
Save michaelwittig/06fbbb6566664bfc4fd0 to your computer and use it in GitHub Desktop.
IAM policy to allow role delegation only with MFA
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "1",
"Effect": "Allow",
"Action": [
"sts:AssumeRole"
],
"Resource": "*",
"Condition": {"Bool": {"aws:MultiFactorAuthPresent": "true"}}
},
{
"Sid": "2",
"Effect": "Allow",
"Action": [
"sts:GetSessionToken"
],
"Resource": "*"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment