Get CNNS Container Audit Events
GET/api/v33.01/audits/firewall/network/container
x-prisma-cloud-target-env: {"permission":"monitorCNNF"}
Retrieves all Cloud Native Network Segmentation (CNNS) container audit events.
For more information, see the Cloud Native Network Segmentation (CNNS)
For containers, rules are defined between:
- Image to image.
- Image to an external network not protected by Prisma Cloud.
- Image to DNS domain.
cURL Request
Refer to the following example cURL command:
$ curl -k \
-u <USER> \
-H 'Content-Type: application/json' \
-X GET \
"https://<CONSOLE>/api/v<VERSION>/audits/firewall/network/container"
cURL Response
{
"_id": "localhost",
"time": "2022-11-14T11:02:43.151Z",
"total": 1,
"resource": {
"images": [
""
]
},
"collections": [
"All",
"user123"
],
"audits": {
"unexpectedConnection": {
"count": 1,
"audits": [
{
"ruleID": 4,
"time": "2022-11-14T11:02:43.151Z",
"type": "unexpectedConnection",
"srcProfileID": "sha256:8d5df41c547bd107c14368ad302efc46760940ae188df451cabc23e10f7f161b_user_tkgi-users",
"dstProfileID": "20",
"srcProfileHash": 228,
"srcContainerName": "users-ubuntu",
"dstContainerName": "",
"dstSubnet": "localhost",
"srcImageName": "docker.io/library/ubuntu:18.04",
"dstImageName": "",
"dstPort": 8000,
"block": false,
"count": 1,
"msg": "Unexpected connection to ip 127.0.0.1"
}
]
}
}
}
Request
Query Parameters
Offsets the result to a specific report count. Offset starts from 0.
Limit is the amount to fix.
Sorts the result using a key.
Sorts the result in reverse order.
From is an optional minimum time constraints for the audits.
To is an optional maximum time constraints for the audits.
SrcImages are the source images filter.
DstImages are the destination images filter.
Block is the block/audit filter.
Responses
- 200
- default
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- Array [
- ]
- ]
ProfileID is the runtime profile ID.
audits object
Audits is a map from the audit sub-type to the audit events list.
property name* shared.ContainerNetworkFirewallSubtypeAudits
ContainerNetworkFirewallSubtypeAudits represents the container network firewall sub type audits per profile
audits object[]
Audits are the container network firewall audits associated with the sub-type, limited to the determined capacity.
Block indicates whether the connection was blocked.
Count is the event occurrences count.
DstContainerName is the destination container name.
DstDomain is the destination domain that was queried.
DstImage is the destination image name.
DstPort is the connection destination port.
ProfileHash represents the profile hash It is allowed to contain up to uint32 numbers, and represented by int64 since mongodb does not support unsigned data types
DstProfileID is the destination profile ID.
DstSubnet is the destination subnet.
labels object
Labels are the custom labels associated with the target container.
Message is the event message.
RuleID represents the ID of each container network firewall policy rule
SrcContainerName is the source container name.
SrcImage is the source image name.
ProfileHash represents the profile hash It is allowed to contain up to uint32 numbers, and represented by int64 since mongodb does not support unsigned data types
SrcProfileID is the source profile ID.
Time is the UTC time of the audit event.
Possible values: [unexpectedConnection
]
NetworkFirewallAttackType is the network firewall type of attack
Count is the total count of the sub-type audits.
Cluster is the cluster from which the audit originated.
Collections are collections to which this audit applies.
ImageName is the container image name.
Label represents the container deployment label.
OS is the operating system distribution.
resource object
RuntimeResource represents on which resource in the system a rule applies (e.g., specific host or image) Empty resource or wildcard (*) represents all resources of a given type
List of account IDs.
List of application IDs.
List of Kubernetes cluster names.
List of containers.
List of functions.
List of hosts.
List of images.
List of labels.
List of Kubernetes namespaces.
Time is the UTC time of the last audit event.
Total is the total count of audits per runtime profile.
[
{
"_id": "string",
"audits": {},
"cluster": "string",
"collections": [
"string"
],
"imageName": "string",
"label": "string",
"os": "string",
"resource": {
"accountIDs": [
"string"
],
"appIDs": [
"string"
],
"clusters": [
"string"
],
"containers": [
"string"
],
"functions": [
"string"
],
"hosts": [
"string"
],
"images": [
"string"
],
"labels": [
"string"
],
"namespaces": [
"string"
]
},
"time": "2024-07-29T15:51:28.071Z",
"total": 0
}
]