Removing AWS CloudFront access restriction from a country

Removing AWS CloudFront access restriction from a country

We are developing a small web application on AWS, but we also restricted geographic access through WAF and CloudFront. However, we later wanted to give one of our offshore developers the ability to test the application, but he got an HTTP 403 error through CloudFront.

The error on the browser was a CloudFront one:

The Amazon CloudFront distribution is configured to block access from your country. We can't connect to the server for this app or website at this time. There might be too much traffic or a configuration error. Try again later, or contact the app or website owner.
If you provide content to customers through CloudFront, you can find steps to troubleshoot and help prevent this error by reviewing the CloudFront documentation.

The logs were however showing that 3 requests came through from India:

Still, the resource in India was getting the HTTP 403.

Turns out under the CloudFront Distribution, there was a geographic restriction set to only the United States. After adding India to it, the change was propagated within a few seconds and all was good.