|
| 1 | +rules: |
| 2 | + - path: /oauth/token |
| 3 | + methods: ['POST'] |
| 4 | + responses: |
| 5 | + - status_code: 200 |
| 6 | + headers: |
| 7 | + Content-Type: |
| 8 | + - 'application/json' |
| 9 | + body: | |
| 10 | + {"access_token":"xxxx","expires_in":3600,"token_type":"Bearer","refresh_token":"yyyy"} |
| 11 | + - path: /graphql |
| 12 | + methods: ['POST'] |
| 13 | + request_headers: |
| 14 | + Authorization: |
| 15 | + - 'Bearer xxxx' |
| 16 | + request_body: /.*"after":null.*/ |
| 17 | + responses: |
| 18 | + - status_code: 200 |
| 19 | + headers: |
| 20 | + Content-Type: |
| 21 | + - application/json |
| 22 | + body: |- |
| 23 | + {{ minify_json ` |
| 24 | + { |
| 25 | + "data": { |
| 26 | + "configurationFindings": { |
| 27 | + "nodes": [ |
| 28 | + { |
| 29 | + "analyzedAt": "2024-08-07T12:55:52.012378Z", |
| 30 | + "id": "1243196d-a365-589a-a8aa-13817c9877b2", |
| 31 | + "remediation": null, |
| 32 | + "resource": { |
| 33 | + "id": "f0f4163d-cbd7-517c-ba9e-f96bb90ab5ea", |
| 34 | + "name": "Root user", |
| 35 | + "nativeType": "rootUser", |
| 36 | + "providerId": "arn:aws:iam::998231069301:root", |
| 37 | + "region": null, |
| 38 | + "cloudPlatform": "EKS", |
| 39 | + "subscription": { |
| 40 | + "cloudProvider": "AWS", |
| 41 | + "externalId": "998231069301", |
| 42 | + "id": "94e76baa-85fd-5928-b829-1669a2ca9660", |
| 43 | + "name": "wiz-integrations" |
| 44 | + }, |
| 45 | + "tags": [], |
| 46 | + "type": "USER_ACCOUNT" |
| 47 | + }, |
| 48 | + "result": "PASS", |
| 49 | + "rule": { |
| 50 | + "description": "description", |
| 51 | + "id": "563ed717-4fb6-47fd-929e-9c794e201d0a", |
| 52 | + "name": "Root account access keys should not exist", |
| 53 | + "remediationInstructions": "instructions", |
| 54 | + "shortId": "IAM-006" |
| 55 | + }, |
| 56 | + "severity": "MEDIUM" |
| 57 | + } |
| 58 | + ], |
| 59 | + "pageInfo": { |
| 60 | + "hasNextPage": true, |
| 61 | + "endCursor": "eyJmaWVsZHMiOlt7IkZpZWxkIjoiVGltZXN0YW1wIiwiVmFsdWUiOiIyMDIzLTA5LTA0VDExOjE5OjM3LjgwMTU0MVoifV19" |
| 62 | + } |
| 63 | + } |
| 64 | + } |
| 65 | + } |
| 66 | + `}} |
| 67 | + - path: /graphql |
| 68 | + methods: ['POST'] |
| 69 | + request_headers: |
| 70 | + Authorization: |
| 71 | + - 'Bearer xxxx' |
| 72 | + request_body: /.*"after":"eyJmaWVsZHMiOlt7IkZpZWxkIjoiVGltZXN0YW1wIiwiVmFsdWUiOiIyMDIzLTA5LTA0VDExOjE5OjM3LjgwMTU0MVoifV19".*/ |
| 73 | + responses: |
| 74 | + - status_code: 200 |
| 75 | + headers: |
| 76 | + Content-Type: |
| 77 | + - application/json |
| 78 | + body: |- |
| 79 | + {{ minify_json ` |
| 80 | + { |
| 81 | + "data": { |
| 82 | + "configurationFindings": { |
| 83 | + "nodes": [ |
| 84 | + { |
| 85 | + "analyzedAt": "2024-08-15T11:41:17.517926Z", |
| 86 | + "id": "6fe49e83-2f3a-5b62-99de-beae16c7bfae", |
| 87 | + "remediation": null, |
| 88 | + "resource": { |
| 89 | + "id": "8a53b2d9-f6c6-59e4-bce0-736a45e9aa3f", |
| 90 | + "name": "annam-vm", |
| 91 | + "nativeType": "Microsoft.Compute/virtualMachines", |
| 92 | + "providerId": "80045425-a0a9-4457-82c2-2c5f47419d83", |
| 93 | + "region": "eastus", |
| 94 | + "subscription": { |
| 95 | + "cloudProvider": "Azure", |
| 96 | + "externalId": "434f3cbb-30f2-4bc0-8bba-cb080280652b", |
| 97 | + "id": "064ecbb5-19ee-540d-b9f5-99c3a4e2d0db", |
| 98 | + "name": "partner integrations" |
| 99 | + }, |
| 100 | + "tags": [], |
| 101 | + "type": "VIRTUAL_MACHINE" |
| 102 | + }, |
| 103 | + "result": "PASS", |
| 104 | + "rule": { |
| 105 | + "description": "description", |
| 106 | + "id": "56c8890d-ad68-4659-9414-fb0ed7258c31", |
| 107 | + "name": "Virtual Machine should not be stopped (allocated) for more than a week", |
| 108 | + "remediationInstructions": "remediation", |
| 109 | + "shortId": "VirtualMachines-021" |
| 110 | + }, |
| 111 | + "severity": "LOW", |
| 112 | + "evidence": { |
| 113 | + "cloudConfigurationLink": "https://learn.microsoft.com/en-us/azure/virtual-machines/states-billing", |
| 114 | + "configurationPath": null, |
| 115 | + "currentValue": "The VM is stopped(allocated) since 2024-08-15", |
| 116 | + "expectedValue": "The VM should be used or deallocated" |
| 117 | + } |
| 118 | + } |
| 119 | + ], |
| 120 | + "pageInfo": { |
| 121 | + "hasNextPage": false, |
| 122 | + "endCursor": "eMJmaWVsZIkZpZWxkIjoiVGltZXN0YW1wIiwiVmFsdWUiOiIyMDIzLTA5LTA0VDExOjE5OjM3LjgwMTU0MVoifV19" |
| 123 | + } |
| 124 | + } |
| 125 | + } |
| 126 | + } |
| 127 | + `}} |
0 commit comments