IOC API
This API enables you to manage the indicators of compromise (IOCs) obtained from external sources on the Cytomic Orion platform.
Import and Search for IOCs in the Telemetry Generated by a Client’s Computers
Loads one or more IOCs of the same type onto the platform. You can configure those IOCs for two types of searches:
-
Retrospective searches (optional): These searches examine, only once, the flow of events generated by the client’s computers over the last year since an IOC is imported. A single indicator is generated in the console for each computer/IOC pair found.
-
Real-time searches: These searches examine, in real time, the information generated by processes running on the client’s computers. A single indicator is generated in the console for each computer/IOC pair every hour. The search ends when the time indicated in the TTL field expires.
Request
Command |
POST |
URL |
/api/v1/applications/iocs/{iocType} |
Required parameters in the URL |
|
Optional querystring parameters in the URL |
|
Required parameters in the HTTP message body |
List of JSON objecs with descriptions of the IOCs. You can include only one of these parameters in the JSON object. All of the IOCs must be of the same type. Possible fields in the JSON object:
|
Headers |
|
Response
JSON object field | Description |
---|---|
success |
“true” |
message |
“n {iocType} added”: Indicates the number of IOCs successfully loaded onto the platform and their type. |
error |
“null” |
PandaAlertId |
Internal identifier assigned to the IOC. |
Delete IOCs Imported onto the Platform
Deletes IOCs previously imported onto the platform, interrupting any retrospective or real-time searches that might be in progress.
Request
Command |
POST |
URL |
/api/v1/applications/iocs/{iocType}/eraser/ |
Required parameters in the URL |
|
Required parameters in the HTTP message body |
List of JSON objects with descriptions of the IOCs you want to delete. You can include only one of these parameters in the JSON object. All of the IOCs must be of the same type. Possible fields in the JSON object:
|
Headers |
|
Response
JSON object field | Description |
---|---|
success |
“true” |
message |
“n {iocType} deleted”: Indicates the number of IOCs successfully deleted from the platform and their type. |
error |
“null” |
PandaAlertId |
Internal identifier assigned to the IOC. |
List IOCs Loaded onto the Platform by Attributes
Shows the list of IOCs loaded onto the platform according to their attributes and when they were imported.
Request
Command |
POST |
URL |
/api/v1/applications/iocs/{iocType}/getter/ |
Required parameters in the URL |
|
Required parameters in the HTTP message body |
List of JSON objects with descriptions of the IOCs you want to list. You can include only one of these parameters in the JSON object. All of the IOCs must be of the same type (specified in the iocType field). Possible fields in the JSON object:
|
Headers |
|
Response
JSON object field | Description |
---|---|
IocType |
Indicates the type of the IOCs in the list.
|
KeyValueAsString |
IOC value. |
IocJson |
|
DeploymentDateUTC |
Date the IOC was loaded onto the platform. |
ExpirationDateUTC |
Date the IOC will be deleted from the platform. |
LastRetroScanUTC |
Date on which a retrospective search for the IOC was last run. |
PandaAlertId |
Internal identifier assigned to the IOC. |
List IOCs by Date Loaded onto the Platform
Shows the list of IOCs loaded onto the platform by date of publication.
Request
Command |
GET |
URL |
/api/v1/applications/iocs/{iocType} |
Required parameters in the URL |
|
Required parameters in the HTTP message body |
|
Headers |
Accept: application/json |
Response
JSON object field | Description |
---|---|
IocType |
Indicates the type of the IOCs in the list.
|
KeyValueAsString |
IOC value. |
IocJson |
|
DeploymentDateUTC |
Date the IOC was loaded onto the platform. |
ExpirationDateUTC |
Date the IOC will be deleted from the platform. |
LastRetroScanUTC |
Date on which a retrospective search for the IOC was last run. |
PandaAlertId |
Internal identifier assigned to the IOC. |
Search for IOCs Retrospectively
Searches for patterns in all events generated so far on the SOC clients’ computers. It returns a list of JSON objects with the IOCs found. The call to this method has a maximum execution time of 90 seconds. It shows all results at the end of the search. If, after the maximum execution time has passed, Cytomic Orion has not been able to retrieve all available threats, the connection terminates without returning any results.
Request
Command |
POST |
URL |
/api/v1/applications/iocs/{iocType}/retrospectivesearcher |
Required parameters in the URL |
|
Required parameters in the HTTP message body |
List of JSON objecs with descriptions of the IOCs. You can include only one of these parameters in the JSON object. All of the IOCs must be of the same type. Possible fields in the JSON object:
|
Headers |
|
Response
List of JSON objects with descriptions of the attributes of the IOCs found.
JSON object field | Description |
---|---|
MUID |
Computer ID in Cytomic Orion. |
clientid |
Client ID. |
firstSeen |
Date the IOC was first seen on the client’s computer. |
lastSeen |
Date the IOC was last seen on the client’s computer. |
ioc |
Description of the IOC found.
|
PandaAlertId |
Internal identifier assigned to the IOC. |
List of IOCs in the Cytomic Orion Console
To view a list of loaded IOCs in the console, select Settings in the top menu. In the side menu. select IOCs. A list appears that shows information equivalent to that provided in the response to API calls for listing the IOCs loaded onto the platform. See List IOCs Loaded onto the Platform by Attributes or List IOCs by Date Loaded onto the Platform.
Field | Description |
---|---|
IOC type |
Type of the data that appears in the IOC value field. It matches the content of the API iocType parameter. |
IOC value |
Value used in IOC searches. It matches the content of the API KeyValueAsString parameter. |
Import date |
Date the IOC was created. It matches the content of the API DeploymentDateUTC parameter. |
Expiration date |
Date the IOC will be deleted from the platform. It matches the content of the API ExpirationDateUTC parameter. |
Additional data |
It matches the content of the API additionalData parameter. |
Source |
It matches the content of the API source parameter. |
Policy |
It matches the content of the API policy parameter. |
Description |
It matches the content of the API description parameter. |
Examples of IOC API Calls
This example loads multiple IOCs that identify source and target traffic related to C&C (Command & Control) networks, checks whether they are loaded, runs a retrospective search, and deletes them.
When you load the list of IOCs, Cytomic Orion retrospectively examines, only once, the telemetry stored over the last year and generates indicators if it finds threats that match the loaded IOCs. Additionally, it examines, in real time, the events occurred on computers until the IOC expiration date (10 days).
#IOC type iocType='IPIoc' #IOC data ioc_data=[{'ip':'192.168.0.1'},{'ip':'192.168.0.2'},{'ip':'192.168.0.3'}] #Headers for the API call including the access token h_request_ioc = { 'Authorization': f'Bearer {access_token}', 'Accept': 'application/json', 'Content-Type': 'application/json-patch+json' } |
#Aim: To load three IOCs of type IP (IPIoC) onto the server #Enable retrospective search retrospective=True #Call URL url_ioc_add = f'https://api.orion.cytomic.ai/api/v1/applications/iocs/{iocType}?retrospective={retrospective}' #Returns a JSON object with the number of successfully loaded IOCs r = requests.post(url_ioc_add, headers=h_request_ioc, json=ioc_data, verify=False) ioc_add=r.json() |
#Aim: To check the IOCs loaded onto the platform #Call URL url_ioc_list = f'https://api.orion.cytomic.ai/api/v1/applications/iocs/{iocType}/getter/' r = requests.post(url_ioc_list, headers=h_request_ioc, json=ioc_data, verify=False) #Returns a JSON object with a description of the loaded IOCs of the specified type and the #load date iocs_list=r.json() |
#Aim: To start a retrospective search for a list of IOCs #Call URL url_ioc_search = f'https://api.orion.cytomic.ai/api/v1/applications/iocs/{iocType}/retrospectivesearcher/' r = requests.post(url_ioc_search, headers=h_request_ioc, json=ioc_data, verify=False) #Returns a list of JSON objects with the IOCs found on the client’s network iocs_found=r.json() |
#Aim: To delete previously loaded IOCs #Call URL url_ioc_del = f'https://api.orion.cytomic.ai/api/v1/applications/iocs/{iocType}/eraser/' #Returns a JSON object with the number of successfully deleted IOCs r = requests.post(url_ioc_del, headers=h_request_ioc, json=ioc_data, verify=False) ioc_del=r.json() |