Sekoia.io Defend Executor¶
Category: Threat Intelligence
Script: sekoia_defend.py
Integration: REST API
Faraday Plugin: Raw JSON
Website: https://www.sekoia.io/
Description¶
Imports SOC alerts and threat-intelligence observables (IOCs) from Sekoia.io into Faraday. Each alert or observable becomes a vulnerability under a single host.
Prerequisites¶
- A Sekoia.io account with an API key (created in the console under Settings > API Keys) that can read alerts and observables
- Network access to the Sekoia.io API
Configuration¶
Environment Variables (Setup)¶
| Variable | Required | Description |
|---|---|---|
SEKOIA_HOST |
Yes | Sekoia.io API URL (default: https://api.sekoia.io). Change it for a regional or on-premises instance. |
SEKOIA_TOKEN |
Yes | Sekoia.io API key used as Bearer token |
These variables are also accepted as execution arguments, so a single run can override them.
Execution Arguments¶
| Parameter | Type | Mandatory | Description |
|---|---|---|---|
SEKOIA_FILTER |
string | No | Sekoia.io filter expression applied to alerts and observables (e.g., urgency:>=70 AND status.name:"Open"). Default: no filter. |
SEKOIA_LIMIT |
integer | No | Page size for API requests, from 1 to 100 (default: 100) |
YAML Configuration Example¶
executors:
sekoia_defend:
repo_executor: sekoia_defend.py
max_size: 65536
varenvs:
SEKOIA_HOST: "https://api.sekoia.io"
SEKOIA_TOKEN: "<sekoia_token>"
params:
SEKOIA_FILTER:
mandatory: false
type: string
base: string
SEKOIA_LIMIT:
mandatory: false
type: integer
base: integer
How It Works¶
- Authenticates with
Authorization: Bearer <SEKOIA_TOKEN>againstSEKOIA_HOST - Reads alerts from
/v1/sic/alertsand observables from/v1/iocs/observables, applyingSEKOIA_FILTERto both and usingSEKOIA_LIMITas the page size - Creates one vulnerability per record, named
[Sekoia][Alert] <title>or[Sekoia][IOC] <value> - Maps severity from Sekoia's 0-100 score (alert urgency or observable confidence): 80+ critical, 60+ high, 40+ medium, 20+ low, below 20 info
- Adds references to the record in the Sekoia.io console, CVEs found in the text, and Sekoia metadata such as rule, assets, entity and labels
Notes¶
- All records are placed under a single host with IP
0.0.0.0and hostnamesekoia-defend, because Sekoia.io records belong to a tenant rather than to individual hosts. - Alerts in the
Closed,RejectedorMitigatedstates are imported withinfoseverity. All imported vulnerabilities have status open. - Each endpoint is read up to 5000 records.
- The same
SEKOIA_FILTERexpression is sent to both endpoints, so use fields that exist in both or leave it empty. - The shared agent parameters (
AGENT_CONFIG_*tags and severity filters) are not applied by this executor.