More Info:

Check if custom role policies are present

Risk Level

Medium

Address

Security

Compliance Standards

CBP,SEBI

Triage and Remediation

How to Prevent

To prevent IAM Custom Role Policies from being present in IAM using the AWS Management Console, follow these steps:

  1. Review Existing IAM Roles:

    • Navigate to the IAM Dashboard in the AWS Management Console.
    • Click on “Roles” in the left-hand menu.
    • Review the list of existing roles and identify any custom roles that have policies attached.
  2. Restrict Creation of Custom Roles:

    • Go to the “Policies” section in the IAM Dashboard.
    • Create or update a policy that restricts the creation of custom roles.
    • Attach this policy to IAM users or groups that should not have the ability to create custom roles.
  3. Enable AWS Config Rules:

    • Navigate to the AWS Config service in the AWS Management Console.
    • Set up AWS Config rules to monitor IAM role configurations.
    • Enable rules such as “iam-role-managed-policy-check” to ensure that only managed policies are attached to roles.
  4. Set Up CloudWatch Alarms:

    • Go to the CloudWatch service in the AWS Management Console.
    • Create a new alarm that triggers on specific IAM events, such as the creation of a custom role.
    • Configure the alarm to send notifications to administrators for immediate review and action.

By following these steps, you can effectively monitor and control the presence of IAM Custom Role Policies in your AWS environment.