aws-account-can-remove-from-org

explicit aws emits HasPermission

match (effective permission)

{ "action": "organizations:RemoveAccountFromOrganization", "resource_type": "AWS::Organizations::Account" }

emit

source typeIdentity
target type*
source<principal (management-account)>
target<member Account node>
permissionsorganizations:RemoveAccountFromOrganization

Narrative

{principal.name} can remove {account.name} from the organization (organizations:RemoveAccountFromOrganization).

Raw rule rules/explicit/aws-account.yaml

id: aws-account-can-remove-from-org
emits: HasPermission
applies_to:
- aws
match_effective_permission:
  action: organizations:RemoveAccountFromOrganization
  resource_type: AWS::Organizations::Account
emit:
  source_type: Identity
  target_type: '*'
  source: <principal (management-account)>
  target: <member Account node>
  api_source: iam:SimulatePrincipalPolicy | policy evaluation
  permissions:
  - organizations:RemoveAccountFromOrganization
  narrative: '{principal.name} can remove {account.name} from the organization (organizations:RemoveAccountFromOrganization).'
move · open · esc close