| name | automating-ioc-enrichment |
| description | Automates the enrichment of raw indicators of compromise with multi-source threat intelligence context using SOAR platforms, Python pipelines, or TIP playbooks to reduce analyst triage time and standardize enrichment outputs. Use when building automated enrichment workflows integrated with SIEM alerts, email submission pipelines, or bulk IOC processing from threat feeds. Activates for requests involving SOAR enrichment, Cortex XSOAR, Splunk SOAR, TheHive, Python enrichment pipelines, or automated IOC processing.
|
| domain | cybersecurity |
| subdomain | threat-intelligence |
| tags | ["SOAR","enrichment","IOC","Cortex-XSOAR","Splunk-SOAR","VirusTotal","automation","CTI","NIST-CSF"] |
| version | 1.0.0 |
| author | team-cybersecurity |
| license | Apache-2.0 |
| nist_csf | ["ID.RA-01","ID.RA-05","DE.CM-01","DE.AE-02"] |
| mitre_attack | ["T1071.001","T1583.001","T1588.001","T1590.005","T1596"] |
Automating IOC Enrichment
When to Use
Use this skill when:
- Building a SOAR playbook that automatically enriches SIEM alerts with threat intelligence context before routing to analysts
- Creating a Python pipeline for bulk IOC enrichment from phishing email submissions
- Reducing analyst mean time to triage (MTTT) by pre-populating alert context with VT, Shodan, and MISP data
Do not use this skill for fully automated blocking decisions without human review — enrichment automation should inform decisions, not execute blocks autonomously for high-impact actions.
Prerequisites
- SOAR platform (Cortex XSOAR, Splunk SOAR, Tines, or n8n) or Python 3.9+ environment
- API keys: VirusTotal, AbuseIPDB, Shodan, and at minimum one TIP (MISP or OpenCTI)
- SIEM integration endpoint for alert consumption
- Rate limit budgets documented per API (VT: 4/min free, 500/min enterprise)
Workflow
Step 1: Design Enrichment Pipeline Architecture
Define the enrichment flow for each IOC type:
SIEM Alert → Extract IOCs → Classify Type → Route to enrichment functions
IP Address → AbuseIPDB + Shodan + VirusTotal IP + MISP
Domain → VirusTotal Domain + PassiveTotal + Shodan + MISP
URL → URLScan.io + VirusTotal URL + Google Safe Browse
File Hash → VirusTotal Files + MalwareBazaar + MISP
→ Aggregate results → Calculate confidence score → Update alert → Notify analyst
Step 2: Implement Python Enrichment Functions
import requests
import time
from dataclasses import dataclass, field
from typing import Optional
RATE_LIMIT_DELAY = 0.25
@dataclass
class EnrichmentResult:
ioc_value: str
ioc_type: str
vt_malicious: int = 0
vt_total: int = 0
abuse_confidence: int = 0
shodan_ports: list = field(default_factory=)
misp_events: = field(default_factory=)
confidence_score: =
() -> EnrichmentResult:
result = EnrichmentResult(ip, )
vt_resp = requests.get(
,
headers={: vt_key}
)
vt_resp.status_code == :
stats = vt_resp.json()[][][]
result.vt_malicious = stats.get(, )
result.vt_total = (stats.values())
time.sleep(RATE_LIMIT_DELAY)
abuse_resp = requests.get(
,
headers={: abuse_key, : },
params={: ip, : }
)
abuse_resp.status_code == :
result.abuse_confidence = abuse_resp.json()[][]
result.confidence_score = (
(result.vt_malicious / (result.vt_total, )) * +
(result.abuse_confidence / ) * ,
)
result
() -> EnrichmentResult:
result = EnrichmentResult(sha256, )
vt_resp = requests.get(
,
headers={: vt_key}
)
vt_resp.status_code == :
stats = vt_resp.json()[][][]
result.vt_malicious = stats.get(, )
result.vt_total = (stats.values())
result.confidence_score = ((result.vt_malicious / (result.vt_total, )) * )
result