CloudFront Geo Restrictions Not Working

1

On several of our CloudFront distributions we have restricted Singapore under Security / CloudFront geographic restrictions. When we first did so the traffic dropped off from almost 20 million requests a day to 10s of thousands a day. It did not go to zero. There was still a trickle coming from Singapore. Over the 8 weeks since, that trickle has been slowly creeping back up. It's now over 2 million a day. I don't understand why if we have a geo restriction set for that country why traffic is still geting through (and we are being charged for it based on Cost Explorer filtered on region Singapore). How do we completely stop the traffic?

已提问 2 个月前149 查看次数
1 回答
1

The geo-restriction feature in Amazon CloudFront is designed to block requests from specific geographic locations based on the IP address of the client making the request. However, it's important to understand that IP addresses can be shared or dynamically assigned, and some IP addresses can be associated with multiple geographic locations, including proxy servers or VPN services. This can lead to situations where some traffic from a restricted location can still slip through.

To effectively block unwanted traffic from restricted geographic locations with CloudFront, you should consider a multi-layered approach.

  1. First, implement IP blacklisting and rate limiting rules to block known offending IP addresses and limit the impact of unwanted traffic.
  2. Additionally, deploy a Web Application Firewall (WAF) solution like AWS WAF to inspect and filter traffic based on granular rules beyond just IP addresses.
  3. Continuously monitor your traffic patterns and adapt your blocking and filtering rules as needed to keep up with changes in IP assignments and traffic sources.

Combining these measures with CloudFront's geo-restriction feature can provide a more comprehensive solution to mitigate unwanted traffic from restricted locations.

Some useful resources:

profile picture
专家
已回答 2 个月前
profile picture
专家
已审核 2 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则