How to enforce IPAM pool CIDR allocation for VPCs across AWS accounts?
Short answer
B Create a new SCP in Organizations. Add a condition that denies the CreateVpc and AssociateVpcCidrBlock Amazon EC2 actions if the Ipv4IpamPoolId context key value is not the ID of an IPAM pool.
Question
Key Takeaways
This question tests the distinction between preventive (SCP) and detective/remediative (Config/Lambda/EventBridge) controls for enforcing governance on AWS Organizations, with the common trap being the appeal of an 'automated deletion' solution that doesn't prevent the violation and can cause data loss.
To enforce that VPC creation and CIDR association must use an account-specific IPAM pool, the recommended solution is an AWS Organizations Service Control Policy (SCP) that denies ec2:CreateVpc and ec2:AssociateVpcCidrBlock when the ec2:Ipv4IpamPoolId condition key is missing or does not match the allowed pool. The community overwhelmingly selected this SCP-based option (91% of votes) because it is a proactive, centralized control, while the Lambda/Config/EventBridge alternatives are reactive and involve destructive VPC deletion.
Common mistake: The most common wrong answers involve using AWS Config or a scheduled Lambda to detect and delete non-compliant VPCs. Candidates choose these because they seem automated and directly remove offending resources, but they fail to prevent the initial unauthorized creation/association and delete VPCs that may contain production workloads.
Expert Analysis
Why the SCP (Option B) is Correct
Service control policies (SCPs) are the only option that proactively denies the specific EC2 API actions before any resource is created or modified. An SCP attached to the organization, organizational unit (OU), or specific accounts can include a policy statement that denies ec2:CreateVpc and ec2:AssociateVpcCidrBlock unless the request contains an IPAM pool ID that matches the account's designated pool. The ec2:Ipv4IpamPoolId condition key allows this check. Because SCPs affect all IAM principals in the account, they provide a centralized, unbypassable control (except by the management account, which is the intended trust boundary).
Why the Lambda/Config/EventBridge Options Are Wrong
Option A relies on AWS Config to detect non-compliant VPCs and then invokes a Lambda function to delete them. This is a detective/reactive control – the VPC has already been created before remediation occurs. Deleting VPCs can bring down running workloads and is not an acceptable way to enforce policy. Option C is similar, requiring a scheduled Lambda scan that is inefficient and also deletes VPCs. Option D uses EventBridge to watch CloudTrail events and then invoke Lambda to delete the VPC. It too is reactive and fragile; if CloudTrail delivery is delayed or the Lambda fails, non-compliant resources may persist.
Community Perspective
Community comments overwhelmingly support B. One user noted: “Option B meets all of the requirements with least operational overhead” (AzureDP900). Another user highlighted that the presence of AWS Organizations means “we have to use scp rule for central management” ([Removed]). A commenter who considered Option A pointed out that its “issue is the deletion of VPCs” and that it “doesn't mention removing or reclaiming existing IP's” (Spaurito). This reinforces the principle that preventive organization-level policies are superior to reactionary deletion-based approaches.
Additional Considerations
Remember to attach the SCP to the appropriate OUs/accounts. You can also combine the SCP with AWS Config rules if you need ongoing visibility, but the SCP alone satisfies the requirement to prevent unauthorized CIDR allocation. Also note that the condition key is ec2:Ipv4IpamPoolId, which is available for both CreateVpc and AssociateVpcCidrBlock.
Official Reference
- https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_policies_scps.html
- https://docs.aws.amazon.com/vpc/latest/ipam/what-it-is-ipam.html
- https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonec2.html
These links open the official vendor documentation in a new tab.
Exam Strategy
When a question involves enforcing compliance across all accounts in AWS Organizations, look for a Service Control Policy (SCP) as a preventive, centralized control. Be suspicious of options that use AWS Config, Lambda, or EventBridge to 'delete' resources, as they are reactive and destructive, not preventive.
Community Votes
100% of anonymous learners picked answer B. Votes are pick records left by other test-takers — they are not the verified answer.
Discussion 7 contributions
Compiled from public community threads and reader submissions, lightly edited for clarity. Handles and vote tallies are shown as recorded, and comments reflect the views of individual contributors.
From public community threads 7
-
strike3test 👍 4 Answered BThe most suitable option for enforcing the policy at the point of action (creating or associating CIDR blocks) across all AWS accounts in the organization is option B. Therefore, the correct answer is: B. Create a new SCP in Organizations. Add a condition that denies the CreateVpc and AssociateVpcCidrBlock Amazon EC2 actions if the Ipv4IpamPoolId context key value is not the ID of an IPAM pool.
-
AzureDP900 👍 3 Answered BOption B meets all of the requirements with least operational overhead: It creates a new SCP in Organizations that denies the CreateVpc and AssociateVpcCidrBlock Amazon EC2 actions if the Ipv4IpamPoolId context key value is not the ID of an IPAM pool. The SCP will prevent users from creating VPCs without the correct CIDR block. It prevents users from associating a CIDR block with existing VPCs unless the CIDR block is from the IPAM pool for that account.
-
Akshay0403 👍 1 Answered BOption B is the most effective and efficient solution because it proactively prevents non-compliant actions at the organization level, enforcing a strict policy that ensures VPC creation and CIDR block associations are limited to IPAM pools. By leveraging SCPs, you can maintain control over your network architecture, ensuring all resources comply with predefined security and operational guidelines.
-
woorkim 👍 1 Answered BAWS Organization Service control policy (SCP) to enforce CIDR allocation through IPAM while creating VPCs • Enforce using specific IPAM pools • Enforce specific IPAM pools to specific OUs
-
Spaurito 👍 1B - This meets the requirements, although option A would as well. Only issue with option A, is the deletion of VPC's. Doesn't mention removing or reclaiming existing IP's.
Show 2 more comments
-
[Removed] 👍 1 Answered BQuestion mentions organization so we have to use scp rule for central management
-
rdiaz 👍 1 Answered Aaws config
Reader comments & corrections
No reader corrections yet — spotted an error or have a note? Share it below.
Related Analysis
Practice All ANS-C01 Questions
Access 137 questions with complete answers and detailed explanations.
View Full ANS-C01 Practice Test →