Is STS part of EC2 ip-ranges CIDR?

0

My customer, need to allow egress from VPC to STS service for VPC lambda to call STSClient.AssumeRoleAsync API call. Am I correct, assuming that they need to allow outgoing traffic to EC2 ip-ranges CIDR in their SG?

已提問 7 年前檢視次數 1010 次
1 個回答
0
已接受的答案

When dealing with AWS services it's generally a bad idea / almost impossible to get an authoritative set of IP addresses for a particular service unless it is explicitly called out in the ip-ranges.json file that we publish.

In the case of sts (sts.us-east-1.amazonaws.com, sts.us-east-2.amazonaws.com, etc etc etc) these are not called out explicitly and aren't part of EC2.

Instead I'd recommend configuring a proxy host that looks at the requested domain, and allowlists the sts endpoint(s) they'd like to access.

So add a squid proxy to the VPC in a public subnet configured to allowlist the sts endpoint(s) they want to communicate with. Configure the Lambda function to launch in the VPC, and use the IP address(s) / ELB of the Squid Proxy to proxy your STS calls.

AWS
已回答 7 年前
profile picture
專家
已審閱 1 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南