-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtestCmd.js
51 lines (47 loc) · 1.29 KB
/
testCmd.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
import {listBuckets, listObjects, getBucketAcl,
getSecurityGroups,
getUsers,
getRoles,
getGroups,
getInstances,
getUserGroups,
getAccountAuthorizationDetails} from './src/cmds'
import {tooOpenList, limitPortList, ec2Report, securityGroupReport, iamReport} from "./src/utils"
let cb = (data) => {console.log(JSON.stringify(data))}
//listObjects("bucket4test", (data) => cb(data));
//getBucketAcl("bucket4test", (data) => cb(data));
//getSecurityGroups( (data) => cb(data));
//let filter = ["User", "Role", "Group", "LocalManagedPolicy", "AWSManagedPolicy"]
//getAccountAuthorizationDetails(filter, data => cb(data));
//getUsers(data => cb(data));
//getRoles(data => cb(data))
//getGroups(data => cb(data))
/*
getSecurityGroups( (data) => {
let test = tooOpenList(data.SecurityGroups);
console.log(test)
});
getSecurityGroups( (data) => {
let test = limitPortList(data.SecurityGroups);
console.log(test)
});
*/
/*
getSecurityGroups( (data) => {
let result = securityGroupReport(data.SecurityGroups);
console.log(result)
});
getInstances( (data) => {
let result = ec2Report(data);
console.log(result)
}); */
/*
getUsers(data => cb(data));
//getRoles(data => cb(data))
getGroups(data => cb(data))
*/
/*
getUserGroups(data => {
let result = iamReport(data);
console.log(result)
}) */