S3 Lockout check improvements based on PR feedback 2/2
@@ -27,11 +27,7 @@ class S3ProtectAgainstPolicyLockout(BaseResourceCheck):
if 'NotAction' in statement.keys():
continue
- if 'Effect' not in statement.keys():
- # Defaults to allow if doesn't exist.
- continue
-
- if statement['Effect'] == 'Allow':
+ if statement.get('Effect') != 'Deny':
continue
principal = statement['Principal']
