VPC Peering Security Groups

black android smartphone on top of white book
Photo by Pixabay on Pexels.com

A security group serves as a protective barrier, functioning like a firewall to manage the flow of network traffic to and from the resources within your Virtual Private Cloud (VPC). With security groups, you have the flexibility to select the specific ports and communication protocols that are permitted for both incoming (inbound) and outgoing (outbound) network traffic.

You have the capability to modify the inbound or outbound rules within your VPC’s security groups to make reference to security groups in a peered VPC. This adjustment enables the smooth exchange of network traffic between instances associated with the specified security groups in the peered VPC.

Testing

Testing topology:

SG:

Result:

Changing from cross referenced SG to CIDR:

Results:

No pings were lost.

References

https://docs.aws.amazon.com/vpc/latest/userguide/security-groups.html

https://docs.aws.amazon.com/vpc/latest/peering/vpc-peering-security-groups.html

Leave a Reply