Skip to content

Commit

Permalink
Dashboard support for AWS Foundational Security benchmark type (#2210)
Browse files Browse the repository at this point in the history
* add dashboard support for aws foundational security benchmark

* use short category hierarchy for display
  • Loading branch information
manV authored Jun 20, 2024
1 parent f4d09b6 commit fad5622
Show file tree
Hide file tree
Showing 16 changed files with 626 additions and 21 deletions.
201 changes: 193 additions & 8 deletions deepfence_frontend/apps/dashboard/api-spec.json
Original file line number Diff line number Diff line change
Expand Up @@ -6864,6 +6864,118 @@
"security": [{ "bearer_token": [] }]
}
},
"/deepfence/scan/results/count/group/cloud-compliance": {
"post": {
"tags": ["Compliance"],
"summary": "Count Cloud Compliance Results by Control ID",
"description": "Count Cloud Compliance Results grouped by Control ID",
"operationId": "groupResultsCloudCompliance",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ModelComplinaceScanResultsGroupReq"
}
}
}
},
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ModelComplinaceScanResultsGroupResp"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/json": {
"schema": { "$ref": "#/components/schemas/ApiDocsBadRequestResponse" }
}
}
},
"401": { "description": "Unauthorized" },
"403": { "description": "Forbidden" },
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": { "$ref": "#/components/schemas/ApiDocsFailureResponse" }
}
}
},
"500": {
"description": "Internal Server Error",
"content": {
"application/json": {
"schema": { "$ref": "#/components/schemas/ApiDocsFailureResponse" }
}
}
}
},
"security": [{ "bearer_token": [] }]
}
},
"/deepfence/scan/results/count/group/compliance": {
"post": {
"tags": ["Compliance"],
"summary": "Count Compliance Results by Control ID",
"description": "Count Compliance Results grouped by Control ID",
"operationId": "groupResultsCompliance",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ModelComplinaceScanResultsGroupReq"
}
}
}
},
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ModelComplinaceScanResultsGroupResp"
}
}
}
},
"400": {
"description": "Bad Request",
"content": {
"application/json": {
"schema": { "$ref": "#/components/schemas/ApiDocsBadRequestResponse" }
}
}
},
"401": { "description": "Unauthorized" },
"403": { "description": "Forbidden" },
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": { "$ref": "#/components/schemas/ApiDocsFailureResponse" }
}
}
},
"500": {
"description": "Internal Server Error",
"content": {
"application/json": {
"schema": { "$ref": "#/components/schemas/ApiDocsFailureResponse" }
}
}
}
},
"security": [{ "bearer_token": [] }]
}
},
"/deepfence/scan/results/count/group/malware": {
"get": {
"tags": ["Malware Scan"],
Expand Down Expand Up @@ -13263,7 +13375,16 @@
}
},
"ModelBenchmarkType": {
"enum": ["hipaa", "gdpr", "pci", "nist", "cis", "soc_2", "nsa-cisa"],
"enum": [
"hipaa",
"gdpr",
"pci",
"nist",
"cis",
"soc_2",
"nsa-cisa",
"aws_foundational_security"
],
"type": "string"
},
"ModelBulkDeleteReportReq": {
Expand Down Expand Up @@ -13335,7 +13456,16 @@
"account_id": { "type": "string" },
"cloud_provider": { "type": "string" },
"compliance_check_type": {
"enum": ["hipaa", "gdpr", "pci", "nist", "cis", "soc_2", "nsa-cisa"],
"enum": [
"hipaa",
"gdpr",
"pci",
"nist",
"cis",
"soc_2",
"nsa-cisa",
"aws_foundational_security"
],
"type": "string"
},
"control_id": { "type": "string" },
Expand Down Expand Up @@ -13416,6 +13546,7 @@
"ModelCloudNodeAccountInfo": {
"type": "object",
"properties": {
"account_name": { "type": "string" },
"active": { "type": "boolean" },
"cloud_provider": { "type": "string" },
"compliance_percentage": { "type": "number" },
Expand All @@ -13435,6 +13566,7 @@
"ModelCloudNodeAccountRegisterReq": {
"required": [
"node_id",
"account_name",
"host_node_id",
"account_id",
"cloud_provider",
Expand All @@ -13443,12 +13575,13 @@
"type": "object",
"properties": {
"account_id": { "type": "string" },
"account_name": { "type": "string" },
"cloud_provider": { "enum": ["aws", "gcp", "azure"], "type": "string" },
"host_node_id": { "type": "string" },
"is_organization_deployment": { "type": "boolean" },
"monitored_account_ids": {
"type": "object",
"additionalProperties": { "type": "string" },
"monitored_accounts": {
"type": "array",
"items": { "$ref": "#/components/schemas/ModelCloudNodeMonitoredAccount" },
"nullable": true
},
"node_id": { "type": "string" },
Expand All @@ -13461,7 +13594,16 @@
"type": "object",
"properties": {
"cloud_provider": {
"enum": ["aws", "gcp", "azure", "linux", "kubernetes", "aws_org", "gcp_org"],
"enum": [
"aws",
"gcp",
"azure",
"linux",
"kubernetes",
"aws_org",
"gcp_org",
"azure_org"
],
"type": "string"
},
"window": { "$ref": "#/components/schemas/ModelFetchWindow" }
Expand All @@ -13487,9 +13629,12 @@
"items": { "type": "string" },
"nullable": true
},
"category_hierarchy_short": { "type": "string" },
"compliance_type": { "type": "string" },
"control_id": { "type": "string" },
"description": { "type": "string" },
"enabled": { "type": "boolean" },
"node_id": { "type": "string" },
"service": { "type": "string" },
"title": { "type": "string" }
}
Expand All @@ -13503,7 +13648,16 @@
"type": "string"
},
"compliance_type": {
"enum": ["hipaa", "gdpr", "pci", "nist", "cis", "soc_2", "nsa-cisa"],
"enum": [
"hipaa",
"gdpr",
"pci",
"nist",
"cis",
"soc_2",
"nsa-cisa",
"aws_foundational_security"
],
"type": "string"
},
"node_id": { "type": "string" }
Expand All @@ -13530,6 +13684,15 @@
"node_id": { "type": "string" }
}
},
"ModelCloudNodeMonitoredAccount": {
"required": ["node_id", "account_name", "account_id"],
"type": "object",
"properties": {
"account_id": { "type": "string" },
"account_name": { "type": "string" },
"node_id": { "type": "string" }
}
},
"ModelCloudNodeProvidersListResp": {
"required": ["providers"],
"type": "object",
Expand Down Expand Up @@ -13768,6 +13931,27 @@
}
}
},
"ModelComplinaceScanResultsGroupReq": {
"required": ["scan_id", "fields_filter"],
"type": "object",
"properties": {
"fields_filter": { "$ref": "#/components/schemas/ReportersFieldsFilters" },
"scan_id": { "type": "string" }
}
},
"ModelComplinaceScanResultsGroupResp": {
"type": "object",
"properties": {
"groups": {
"type": "object",
"additionalProperties": {
"type": "object",
"additionalProperties": { "type": "integer" }
},
"nullable": true
}
}
},
"ModelConnection": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -16031,7 +16215,8 @@
"nist",
"hipaa",
"pci",
"soc_2"
"soc_2",
"aws_foundational_security"
],
"type": "array",
"items": { "type": "string" },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ models/ModelCloudNodeComplianceControl.ts
models/ModelCloudNodeControlReq.ts
models/ModelCloudNodeControlResp.ts
models/ModelCloudNodeEnableDisableReq.ts
models/ModelCloudNodeMonitoredAccount.ts
models/ModelCloudNodeProvidersListResp.ts
models/ModelCloudResource.ts
models/ModelCompliance.ts
Expand All @@ -102,6 +103,8 @@ models/ModelComplianceScanInfo.ts
models/ModelComplianceScanResult.ts
models/ModelComplianceScanStatusResp.ts
models/ModelComplianceScanTriggerReq.ts
models/ModelComplinaceScanResultsGroupReq.ts
models/ModelComplinaceScanResultsGroupResp.ts
models/ModelConnection.ts
models/ModelContainer.ts
models/ModelContainerImage.ts
Expand Down
Loading

0 comments on commit fad5622

Please sign in to comment.