Aws:RequestedRegion

From wikieduonline
Jump to navigation Jump to search

AWS: Denies access to AWS based on the requested Region[edit]

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "DenyAllOutsideRequestedRegions",
            "Effect": "Deny",
            "Action": "*",
            "Resource": "*",
            "Condition": {
                "StringNotEquals": {
                    "aws:RequestedRegion": [
                        "us-east-1",
                    ]
                }
            }
        }
    ]
}


Restrict to a region:

{
  "Version": "2012-10-17",
  "Statement": [{
    "Effect": "Deny",
    "Action": "*",
    "Resource": "*",
    "Condition": {
      "StringNotEquals": {
        "aws:RequestedRegion": [
          "eu-central-1",
          "eu-west-1"
        ]
      }
    }
  }]
}


Related terms[edit]

See also[edit]

  • https://aws.amazon.com/es/blogs/security/easier-way-to-control-access-to-aws-regions-using-iam-policies/
  • Advertising: