Last active
December 17, 2018 22:29
-
-
Save adrianhall/10df39800af0e8fe2a231d29af4c4410 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#======================================================================================= | |
AuthRole: | |
Type : AWS::IAM::Role | |
Description : "Role that the an authenticated user assumes" | |
Properties: | |
RoleName : ${self:provider.apiname}-auth | |
AssumeRolePolicyDocument: | |
Version : "2012-10-17" | |
Statement: | |
- Effect : Allow | |
Principal: | |
Federated : cognito-identity.amazonaws.com | |
Action : sts:AssumeRoleWithWebIdentity | |
Condition: | |
ForAnyValue:StringLike: | |
"cognito-identity.amazonaws.com:amr": "authenticated" | |
#======================================================================================= | |
UnAuthRole: | |
Type : AWS::IAM::Role | |
Description : "Role that the an authenticated user assumes" | |
Properties: | |
RoleName : ${self:provider.apiname}-unauth | |
AssumeRolePolicyDocument: | |
Version : "2012-10-17" | |
Statement: | |
- Effect : Allow | |
Principal: | |
Federated : cognito-identity.amazonaws.com | |
Action : sts:AssumeRoleWithWebIdentity | |
Condition: | |
ForAnyValue:StringLike: | |
"cognito-identity.amazonaws.com:amr": "unauthenticated" | |
#======================================================================================= |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment