EDR Threat Response 用 API

Kaspersky Endpoint Security 12.9 for Windows では、Kaspersky Security Center OpenAPI を使用する EDR Threat Response 処理(EDR responses)のサポートが導入されています。つまり、Python を使用して、OpenAPI メソッドを呼び出して、EDR Threat Response を自動化できます。SIEM ソリューションと統合すると、これらのメソッドを呼び出すことができます。カスペルスキーの SIEM ソリューションである Kaspersky Unified Monitoring and Analysis Platform は、バージョン 3.4.1 以降で EDR Threat Response OpenAPI をサポートしています。サンプルスクリプトについては、KUMA のドキュメントを参照してください。

EDR Threat Response 処理を実行するには、KSC Open APIAddIncident)を使用してリクエストを作成して送信する必要があります。リクエストが処理されると、Kaspersky Security Center コンソールに特別なタスクが作成されます。

EDR の脅威に対応する場合にタスクを作成するには、管理サーバーと Kaspersky Security Center Web コンソールの間にバックグラウンド接続を確立する必要があります。バックグラウンド接続サービスは、Kaspersky Security Center Windows 14.2 以降および Kaspersky Security Center Linux 15.2 で使用できます。Kaspersky Detection and Response ソリューションのコンソールを含むその他のコンソールはサポートされていません。

EDR Threat Response に対して、基本的なリクエストパラメータを JSON などの形式で指定する必要があります:

EDR Threat Response を設定するには、JSON 形式の "KLINCDT_BODY": json.dumps(data) パラメータでタスク設定を指定する必要があります。これにより、Kaspersky Security Center コンソールに [Response][KUMA] <task type> - <Date> <Time> - <ID> が作成されます。

Kaspersky Security Center OpenAPI への接続

本製品は、EDR Threat Response の一環として、Kaspersky Security Center コンソールに特別なタスクを作成します。これらのタスクを作成するには、コンピューターと Kaspersky Security Center の間に接続を確立する必要があります。これを行うには、リクエストで Kaspersky Security Center の接続パラメータを指定する必要があります。

Kaspersky Security Center の接続パラメータ

パラメータ

種別

説明

kscHost

string

Kaspersky Security Center 管理サーバーのアドレス。必須パラメータ。

kscPort

int

管理サーバーの接続のポート。必須パラメータ。

kscCert

string

Kaspersky Security Center 管理サーバーに接続するための証明書ファイルへのパス。既定では、パラメータは False に設定されています。

kscUser

string

ユーザーアカウント名。必須パラメータ。

kscPassword

string

ユーザーアカウントのパスワード。必須パラメータ。

# KSC connection info

# reads Environment variables by default, change with corresponding values

# KSC host, string, required

kscHost = "kscHost"

# KSC port, required, default is "13299"

kscPort = "13299"

# KSC certificate file path, default is False

kscCert = False

# KSC user, string, required

kscUser = "kscUser"

# KSC password, string, required

kscPassword = "kscPassword"

server_url = 'https://' + kscHost + ':' + str(kscPort)

    server = KlAkAdmServer.Create(

        server_url, kscUser, kscPassword, verify=kscCert)

    params = validate(args)

    data = {"targetHost": <MyHost>,

            "task": task,

            "params": params,

            "responseEventIncident": True,

            "responseEventIncidentArea":"Kuma"}

    oHostGroup = KlAkHostGroup(server)

    incdnt = oHostGroup.AddIncident({"KLINCDT_SEVERITY": 2,

                                     "KLINCDT_ADDED": paramDateTime(datetime.datetime.now()),

                                     "KLINCDT_BODY": json.dumps(data),

                                     "KLHST_WKS_HOSTNAME":  args.targetHost}).RetVal()

    oHostGroup.UpdateIncident(incdnt, {"KLINCDT_IS_HANDLED": False,

                                       "KLHST_WKS_HOSTNAME":  args.targetHost})

ユーザーアカウントデータは保護されないため、別のユーザーを専用のユーザーにして、これらの処理を実行するためだけにそのユーザーを使用する必要があります。

getFileファイルの取得

ファイルの取得]タスクの設定

パラメータ

種別

説明

md5hash

string

取得するファイルの MD5 ハッシュ。

sha256hash

string

取得するファイルの SHA256 ハッシュ。

path

string

取得するファイルへのパス。

type getFile = {

task: 'getFile';

targetHost: string;

params: {

// an empty string or a valid md5 hash of the file

md5hash: string;

// an empty string or a valid sha256 hash of the file

sha256hash: string;

// the path to the file

path: string;

};

responseEventIncidentArea: string;

};

deleteFileファイルの削除

ファイルの削除]タスクの設定

パラメータ

種別

説明

md5hash

string

削除するファイルの MD5 ハッシュ。

sha256hash

string

削除するファイルの SHA256 ハッシュ。

path

string

削除するファイルへのパス。

searchInSubfolders?

boolean

削除するファイルをサブフォルダー内で検索します。

type deleteFile = {

task: 'deleteFile';

targetHost: string;

params: {

// an empty string or a valid md5 hash of the file

md5hash: string;

// an empty string or a valid sha256 hash of the file

sha256hash: string;

// the path to the file

path: string;

// recursive search for a file (subfolder), optional

searchInSubfolders?: boolean;

};

responseEventIncidentArea: string;

};

quarantineFileファイルの隔離

ファイルの隔離]タスクの設定

パラメータ

種別

説明

md5hash

string

隔離するファイルの MD5 ハッシュ。

sha256hash

string

隔離するファイルの SHA256 ハッシュ。

path

string

隔離するファイルへのパス。

type quarantineFile = {

task: 'quarantineFile';

targetHost: string;

params: {

// an empty string or a valid md5 hash of the file

md5hash: string;

// an empty string or a valid sha256 hash of the file

sha256hash: string;

// the path to the file

path: string;

};

responseEventIncidentArea: string;

};

iocScanIOC スキャン

IOC スキャン]タスクの設定

パラメータ

種別

説明

ioc

string

スキャンに使用する IOC ファイルを含む ZIP アーカイブのパス。

isolateHost

boolean

侵害インジケーターの検知時に脅威の拡散を防ぐためにコンピューターをネットワークから分離します。

scanCriticalAreas

boolean

侵害インジケーターの検知時に簡易スキャンタスクを実行します。

quarantineObject

boolean

侵害インジケーターの検知時に悪意のあるオブジェクトを削除します。オブジェクトを削除する前に、後で復元する必要があった場合に備えて Kaspersky Endpoint Security はオブジェクトのバックアップコピーを作成します。バックアップコピーは隔離に移動されます。

type iocScan = {

task: 'iocScan';

targetHost: string;

params: {

// the path to the zip archive with ioc files in base64 encoding

ioc: string;

// isolation of the computer from the network

isolateHost: boolean;

// critical areas scan

scanCriticalAreas: boolean;

// quarantine the file

quarantineObject: boolean;

};

responseEventIncidentArea: string;

};

startProcessプロセスの開始

プロセスの開始]タスクの設定

パラメータ

種別

説明

executablePath

string

プロセスを開始するために使用される実行ファイルへのパス。

arguments?

string

プロセスを開始するための追加のコマンドライン引数。

workingFolder?

string

プロセスの作業フォルダーのパス。

type startProcess = {

task: 'startProcess';

targetHost: string;

params: {

// the path to the file

executablePath: string;

// command line arguments, optional

arguments?: string;

// a working folder, optional

workingFolder?: string;

};

responseEventIncidentArea: string;

};

terminateProcessプロセスの終了

プロセスの終了]タスクの設定

パラメータ

種別

説明

md5hash

string

プロセスを終了するファイルの MD5 ハッシュ。

sha256hash

string

プロセスを終了するファイルの SHA256 ハッシュ。

path

string

削除するファイルへのパス。

caseSensitive

boolean

ファイルを検索する際の大文字小文字の区別。

type terminateProcess = {

task: 'terminateProcess';

targetHost: string;

params: {

// an empty string or a valid md5 hash of the file

md5hash: string;

// an empty string or a valid sha256 hash of the file

sha256hash: string;

// the path to the file

path: string;

// case sensitive of the file name

caseSensitive: boolean;

};

responseEventIncidentArea: string;

};

isolateHost:コンピューターのネットワーク分離

コンピューターのネットワーク分離の設定

パラメータ

種別

説明

action

string

ネットワーク分離の動作モード。

type isolateHost = {

task: 'isolateHost';

targetHost: string;

params: {

// 0 - turning off network isolation, 1 - turning on network isolation

action: number;

};

responseEventIncidentArea: string;

};

preventExecution:実行防止

実行防止の設定

パラメータ

種別

説明

hash

string

実行を禁止するファイルの MD5 ハッシュ。

path

string

実行を禁止するファイルへのパス。

caseSensitive

boolean

ファイルを検索する際の大文字小文字の区別。

type preventExecution = {

task: 'preventExecution';

targetHost: string;

params: {

// a valid md5 hash of the file

hash: string;

// the path to the file

path: string;

// case sensitive of the file name

caseSensitive: boolean;

};

responseEventIncidentArea: string;

};

onDemandScanマルウェアのスキャン

マルウェアのスキャン]タスクの設定

パラメータ

種別

説明

path

string

オブジェクトスキャンのファイルとフォルダーのスペース区切りリスト。

recursive

boolean

再帰的スキャンモード。

type

number

スキャン範囲。

ScanObjectType = Enum("ScanObjectType",

[

("SystemMemory", 14),

("StartupObjectsAndRunningProcesses", 15),

("DiskBootSectors", 16),

("SystemBackupStorage", 17),

("Email", 18),

("Folder", 22),

("AllRemovableDrives", 23),

("AllNetworkDrives", 24),

("AllFixedDrives", 25)])

type onDemandScan = {

task: 'onDemandScan';

targetHost: string;

// please note, this is an array

// array of scan object

params: [{

// enabling the scan object

enabled: boolean;

// an empty string or the path to the folder to scan

path: string;

// recursive scan mode

recursive: boolean;

// ID scan object

type: number;

}];

responseEventIncidentArea: string;

};

ページのトップに戻る