Skip to content

Quarantine

The Quarantine service collection provides operations for managing quarantined files. Get quarantine file metadata and aggregates, update quarantine states by ID or query, and search for quarantine file IDs using FQL filters.

LanguageLast Update
Pythonv1.4.6
PowerShellv2.2.9
Gov0.20.0
TypeScriptv0.6.0
Rustv0.7.0
Rubyv1.2.0
OperationDescription
ActionUpdateCount
action_update_count
Returns count of potentially affected quarantined files for each action.
GetAggregateFiles
get_aggregate_files
Get quarantine file aggregates as specified via json in request body.
GetQuarantineFiles
get_quarantine_files
Get quarantine file metadata for specified ids.
UpdateQuarantinedDetectsByIds
update_quarantined_detects_by_id
Apply action by quarantine file ids.
QueryQuarantineFiles
query_quarantine_files
Get quarantine file ids that match the provided filter criteria.
UpdateQfByQuery
update_quarantined_detects_by_query
Apply quarantine file actions by query.

Returns count of potentially affected quarantined files for each action.

GET /quarantine/aggregates/action-update-count/v1
Scope Quarantined Files: READ Consumes · Produces application/json
PEP 8 action_update_count
NameTypeData typeDescription
filterquerystringThe filter expression that should be used to filter results. FQL syntax.
parametersquerydictionaryFull query string parameters payload in JSON format.
from falconpy import Quarantine
falcon = Quarantine(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.action_update_count(filter="string")
print(response)

Get quarantine file aggregates as specified via json in request body.

POST /quarantine/aggregates/quarantined-files/GET/v1
Scope Quarantined Files: READ Consumes · Produces application/json
PEP 8 get_aggregate_files
NameTypeData typeDescription
bodybodylist of dictionariesFull body payload in JSON format.
date_rangesbodylist of dictionariesApplies to date_range aggregations. Example: [{“from”: “2016-05-28T09:00:31Z”, “to”: “2016-05-30T09:00:31Z”}, {“from”: “2016-06-01T09:00:31Z”, “to”: “2016-06-10T09:00:31Z”}]
excludebodystringElements to exclude.
fieldbodystringThe field on which to compute the aggregation.
filterbodystringFQL syntax formatted string to use to filter the results.
frombodyintegerStarting position.
includebodystringElements to include.
intervalbodystringTime interval for date histogram aggregations. Valid values include: year, month, week, day, hour, minute.
max_doc_countbodyintegerOnly return buckets if values are less than or equal to the value here.
min_doc_countbodyintegerOnly return buckets if values are greater than or equal to the value here.
missingbodystringMissing is the value to be used when the aggregation field is missing from the object. In other words, the missing parameter defines how documents that are missing a value should be treated. By default they will be ignored, but it is also possible to treat them as if they had a value.
namebodystringName of the aggregate query, as chosen by the user. Used to identify the results returned to you.
qbodystringFull text search across all metadata fields.
rangesbodylist of dictionariesApplies to range aggregations. Ranges values will depend on field. For example, if max_severity is used, ranges might look like: [{“From”: 0, “To”: 70}, {“From”: 70, “To”: 100}]
sizebodyintegerThe max number of term buckets to be returned.
sub_aggregatesbodylist of dictionariesA nested aggregation, such as: [{“name”: “max_first_behavior”, “type”: “max”, “field”: “first_behavior”}]. There is a maximum of 3 nested aggregations per request.
sortbodystringFQL syntax string to sort bucket results. _count - sort by document count; _term - sort by the string value alphabetically. Supports asc and desc using | format. Example: _count|desc
time_zonebodystringTime zone for bucket results.
typebodystringType of aggregation. Valid values include: date_histogram (aggregates counts on a specified time interval, requires use of “interval” field), date_range (aggregates counts on custom defined date range buckets), terms (buckets alerts by the value of a specified field), range (buckets alerts by specified numeric ranges of a specified field), cardinality (returns the count of distinct values in a specified field), max (returns the maximum value of a specified field), min (returns the minimum value of a specified field), avg (returns the average value of the specified field), sum (returns the total sum of all values for the specified field), percentiles (returns the following percentiles for the specified field: 1, 5, 25, 50, 75, 95, 99).
from falconpy import Quarantine
falcon = Quarantine(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
ranges = [
{
"From": 0,
"To": 0
}
]
response = falcon.get_aggregate_files(date_ranges="string",
exclude="string",
field="string",
filter="string",
from=integer,
include="string",
interval="string",
max_doc_count=integer,
min_doc_count=integer,
missing="string",
name="string",
q="string",
ranges=ranges,
size=integer,
sort="string",
sub_aggregates=["string"],
time_zone="string",
type="string")
print(response)

Get quarantine file metadata for specified ids.

POST /quarantine/entities/quarantined-files/GET/v1
Scope Quarantined Files: READ Consumes · Produces application/json
PEP 8 get_quarantine_files
NameTypeData typeDescription
bodybodydictionaryFull body payload in JSON format.
idsbodystring or list of stringsList of Quarantine IDs to retrieve.
from falconpy import Quarantine
falcon = Quarantine(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.get_quarantine_files(ids=id_list)
print(response)

Apply action by quarantine file ids.

PATCH /quarantine/entities/quarantined-files/v1
Scope Quarantined Files: WRITE Consumes · Produces application/json
PEP 8 update_quarantined_detects_by_id
NameTypeData typeDescription
actionbodystringAction to perform against the quarantined file. Allowed values: delete, release, unrelease.
bodybodydictionaryFull body payload in JSON format.
commentbodystringComment to list along with action taken.
idsbodystring or list of stringsList of Quarantine IDs to update.
from falconpy import Quarantine
falcon = Quarantine(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.update_quarantined_detects_by_id(action="string",
comment=["string"],
ids=id_list)
print(response)

Get quarantine file ids that match the provided filter criteria.

GET /quarantine/queries/quarantined-files/v1
Scope Quarantined Files: READ Consumes · Produces application/json
PEP 8 query_quarantine_files
NameTypeData typeDescription
filterquerystringFQL query specifying the filter parameters. Special value * means to not filter on anything. Filter term criteria: status, adversary_id, device.device_id, device.country, device.hostname, behaviors.behavior_id, behaviors.ioc_type, behaviors.ioc_value, behaviors.username, behaviors.tree_root_hash. Filter range criteria: max_severity, max_confidence, first_behavior, last_behavior.
limitqueryintegerMaximum number of IDs to return. Max: 5000.
offsetquerystringStarting index of overall result set from which to return ids.
qquerystringMatch phrase_prefix query criteria, included fields: _all (all filter string fields), sha256, state, paths.path, paths.state, hostname, username, date_updated, date_created.
sortquerystringPossible order by fields: hostname, username, date_updated, date_created, paths.path, state, paths.state. Example: date_created|asc. Sort order: asc or desc.
parametersquerydictionaryFull query string parameters payload in JSON format.
from falconpy import Quarantine
falcon = Quarantine(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
response = falcon.query_quarantine_files(filter="string",
q="string",
limit=integer,
offset="string",
sort="string")
print(response)

Apply quarantine file actions by query.

PATCH /quarantine/queries/quarantined-files/v1
Scope Quarantined Files: WRITE Consumes · Produces application/json
PEP 8 update_quarantined_detects_by_query
NameTypeData typeDescription
actionbodystringAction to perform against the quarantined file. Allowed values: delete, release, unrelease.
bodybodydictionaryFull body payload in JSON format.
commentbodystringComment to list along with action taken.
filterbodystring or list of stringsFilter string to use to match to quarantine records. FQL syntax.
qbodystringMatch phrase_prefix query criteria, included fields: _all (all filter string fields), sha256, state, paths.path, paths.state, hostname, username, date_updated, date_created.
from falconpy import Quarantine
falcon = Quarantine(client_id=CLIENT_ID,
client_secret=CLIENT_SECRET
)
id_list = 'ID1,ID2,ID3' # Can also pass a list here: ['ID1', 'ID2', 'ID3']
response = falcon.update_quarantined_detects_by_query(action="string",
comment=["string"],
ids=id_list)
print(response)