aaronlippold / inspec-aws

InSpec for AWS (Incubation)
https://www.inspec.io/
Other
1 stars 1 forks source link

Enhancement for aws_iam_role #29

Open rx294 opened 6 years ago

rx294 commented 6 years ago

Ref #174 from https://github.com/chef/inspec-aws Please consider the following features to support cis-aws-foundations-1.18 Enhancements:

  describe aws_iam_role(IAM_MASTER_ROLE_NAME) do
    it { should exist }
    its('inline-policies') { should include IAM_MASTER_INLINE_POLICY }
    its('attached-policies') { should include IAM_MASTER_ATTACHED_POLICY }
  end

1) List inline policies aws iam list-role-policies --role-name <role_name> 2) List attached policlies aws iam list-attached-role-policies --role-name <rolename>