AWS Certified Solutions Architect – Associate (SAA-C03) — Question 729
A solutions architect must provide an automated solution for a company's compliance policy that states security groups cannot include a rule that allows SSH from 0.0.0.0/0. The company needs to be notified if there is any breach in the policy. A solution is needed as soon as possible.
What should the solutions architect do to meet these requirements with the LEAST operational overhead?
Answer options
- A. Write an AWS Lambda script that monitors security groups for SSH being open to 0.0.0.0/0 addresses and creates a notification every time it finds one.
- B. Enable the restricted-ssh AWS Config managed rule and generate an Amazon Simple Notification Service (Amazon SNS) notification when a noncompliant rule is created.
- C. Create an IAM role with permissions to globally open security groups and network ACLs. Create an Amazon Simple Notification Service (Amazon SNS) topic to generate a notification every time the role is assumed by a user.
- D. Configure a service control policy (SCP) that prevents non-administrative users from creating or editing security groups. Create a notification in the ticketing system when a user requests a rule that needs administrator permissions.
Correct answer: B
Explanation
Using the AWS Config managed rule 'restricted-ssh' is the most efficient approach because it is a pre-built solution that requires zero code development, unlike writing a custom AWS Lambda script. Combining this managed rule with Amazon SNS provides immediate, automated alerts for policy violations with the least operational overhead. Other options, like using SCPs to block security group modifications entirely or monitoring IAM role assumptions, do not directly audit the specific compliance state of the security groups themselves.