File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change 1+ id : aws_iam_access_keys_policy 
2+ title : AWS IAM Access Key Policy 
3+ description : Specifies the maximum age for IAM Access Keys 
4+ language : sql 
5+ integration_type :
6+   - aws_cloud_account 
7+ primary_resource : aws_iam_access_key 
8+ definition : | 
9+   SELECT 
10+     access_key_id AS resource, 
11+     platform_integration_id AS platform_integration_id, 
12+     platform_resource_id AS platform_resource_id, 
13+     CASE 
14+       WHEN status <> 'Active' THEN 'skip' 
15+       WHEN create_date + ('{{.awsIamAccessKeyAge}}' || ' days')::interval < NOW() THEN 'alarm' 
16+       ELSE 'ok' 
17+     END AS status, 
18+     CASE 
19+       WHEN status <> 'Active' THEN 'key is not activated' 
20+       WHEN create_date + ('{{.awsIamAccessKeyAge}}' || ' days')::interval < NOW() THEN 'key is too old' 
21+       ELSE 'key is not old yet' 
22+     END AS reason, 
23+     region, 
24+     account_id 
25+   FROM 
26+     aws_iam_access_key v 
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments