Update Image Vulnerability Policy
PUT/api/v32.07/policies/vulnerability/images
x-prisma-cloud-target-env: {"permission":"policyContainers"}
Updates the vulnerability policy for deployed container images. All rules in the policy are updated in a single shot.
This endpoint maps to the policy table in Defend > Vulnerabilities > Images > Deployed in the Console UI.
cURL Request
Refer to the following example cURL command that overwrites all rules in your current policy with a new policy that has a single rule:
$ curl -k \
-u <USER> \
-X PUT 'https://<CONSOLE>/api/v<VERSION>/policies/vulnerability/images' \
--data '{
"rules":[
{
"name":"<RULE_NAME>",
"collections":[
{
"name":"<COLLECTION_NAME>",
}
],
"alertThreshold":{
"disabled":false,
"value":4
},
"blockThreshold":{
"enabled":false,
"value":0
},
...
}
],
"policyType": "containerVulnerability"
...
}'
Note: No response will be returned upon successful execution.
Request
Responses
- 200
- default
OK