Emergency access

Gives TrueMark break-glass administrator access for responding to incidents.

remote-emergency-access/template.yaml

CloudFormation template · 32 lines

AWSTemplateFormatVersion: "2010-09-09"
Description: "Provides TrueMark emergency access"
Resources:
  RemoteEmergencyAccessRole:
    Type: AWS::IAM::Role
    Properties:
      RoleName: "TrueMarkEmergencyAccess"
      Description: "Provides TrueMark emergency access. Delete stack to remove access."
      AssumeRolePolicyDocument:
        Version: "2012-10-17"
        Statement:
          - Effect: Allow
            Action:
              - sts:AssumeRole
            Principal:
              AWS:
                - 617383789573
            Condition:
              'ForAnyValue:StringLike':
                'aws:PrincipalArn':
                  - >-
                    arn:aws:iam::*:role/aws-reserved/sso.amazonaws.com/*/AWSReservedSSO_EmergencyAccess_*
      Path: "/"
      ManagedPolicyArns:
        - arn:aws:iam::aws:policy/AdministratorAccess
Outputs:
  RemoteEmergencyAccessRoleARN:
    Value: !GetAtt RemoteEmergencyAccessRole.Arn
    Export:
      Name: RemoteEmergencyAccessRoleARN
Metadata:
  Version: "0"

Launch stack opens the AWS CloudFormation console in us-east-2 with this template and the stack name truemark-remote-emergency-access filled in. Deleting the stack removes the access.