Ensures that only principals with the appropriate environment tag can access resources, enforcing environment segregation.
What this SCP does
This Service Control Policy (SCP) ensures that only principals with the appropriate environment tag can access resources. This helps enforce environment segregation between production and non-production resources.
By restricting access based on principal tags, this policy creates a clear boundary between production and development environments, ensuring that only properly tagged identities can interact with production resources, which is essential for maintaining security and compliance requirements.
How to test this SCP works
To validate this SCP, you need to test with IAM roles that have different environment tags.
For thorough testing, you should create EC2 instance profiles for different roles, launch instances with these profiles, and test various AWS operations from each instance to verify the SCP's effectiveness.