Update Blocked Commands

Update Blocked Commands is a configuration-based API that helps you update the blocked commands.

The API can be executed only by the Manager user role.

POST sm/v1/block-commands/update

Input ParametersInput Parameters

Parameter Mandatory/Optional Data Type Description
languageId Mandatory Long Provide the language ID, which is the unique id that is the combination of platform and language.
commands Mandatory String Provide the commands that are comma separated strings which the user wants to block from script creation.
user Optional Object Provide the user details like name and ID of user.
Authorization Mandatory String Authorization token to authenticate to the Qualys Enterprise TruRisk™ Platform. Prepend the token with 'Bearer', followed by a space. For example: Bearer .

SampleSample

API Request

 curl -X POST 'https://<qualys_base_url>/sm/v1/block-commands/update' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer {{authToken}}' \
--data '{
 "languageId": 4,
 "commands":"date,ls,mkdir,put",
 "user": {
 "id": "<USER ID>",
 "name": "<USER NAME>"
 
 }
}'

Response

 {
 "body": "Commands Updated Successfully"
}