Kaspersky Anti Targeted Attack (KATA) Platform

请求创建任务

2024年6月26日

ID 227591

HTTP POST 方法用于请求运行 Kaspersky Anti Targeted Attack Platform 应用程序。命令设置以 JSON 格式在请求正文中传递。

命令语法

curl -k --<TLS证书文件路径> --key <私钥文件路径> -X POST "<中央节点服务器的 URL>:<端口,默认443>/kata/response_api/v1/< external_system_id>/tasks/<task_id>?sensor_id=<sensor_id>&task_type=run_process" -H 'Content-Type:application/json' -d '

{

"task": {

"schedule": {"startNow": <true 或 false>},

"execCommand": "<要运行的应用程序的名称>",

"cmdLineParameters": "<运行文件或命令的其他选项>",

"workingDirectory": "<工作目录>"

}

}

'

如果成功处理请求,则会创建运行应用程序任务。

设置

参数

类型

描述

external_system_id

UUID

用于 Kaspersky Anti Targeted Attack Platform 授权的外部系统的唯一 ID。

sensor_id

UUID

具有端点代理组件的主机的唯一 ID。

task_id

UUID

任务的唯一 ID。

使用开关输入命令的示例

curl -k --example.cert --example.key -X POST "https://10.10.0.22:443/kata/response_api/v1/15301050-0490-4A41-81EA-B0391CF21EF3/tasks/2EEB4CBC-10C6-4DC4-BE0A-72A75CDB0BE8?sensor_id=DF64838B-B518-414B-B769-2B8BE341A2F0&task_type=run_process" -H 'Content-Type: application/json' -d '

{

"task": {

"schedule": {"startNow": true},

"execCommand": "Example.exe",

"cmdLineParameters": "C:\Windows\System32\",

"workingDirectory": "/all"

}

}

'

Response

HTTP 代码:200

格式:JSON

type Response struct {

State `json:"state"`

LastStartDateTime `json:"latestStartDateTime"`

type Task struct {

type Schedule struct {

StartNow boolean `json:"startNow"`

ExecCommand string `json:"execCommand"`

}

}

}

 

返回值

返回码

描述

400

参数不正确。

401

需要授权。

404

未找到具有指定 ID 的任务。

500, 502, 503, 504

内部服务器错误。稍后重复该请求。

如果要编辑已创建任务的设置,则必须创建新请求以添加具有新设置的任务。

Did you find this article helpful?
What can we do better?
Thank you for your feedback! You're helping us improve.
Thank you for your feedback! You're helping us improve.