Skip to content
Pwnversity
CTI-IOCintermediate · 11 min · upd. 2026-11

IOCs and TTPs

Pirámide del dolorSigmaYARA

An IOC (Indicator of Compromise) is an observable artifact that points to malicious activity: a hash, an IP, a domain, a registry key. A TTP (Tactics, Techniques and Procedures) describes how the adversary acts: dumps credentials from LSASS, moves over WinRM, exfiltrates to cloud storage. IOCs are easy to use and easy to evade; TTPs are harder to detect and much harder to change. A mature defense uses both, knowing what each is worth.

  • Turning intelligence into something a control can apply: block, alert, hunt.
  • Knowing which type of indicator deserves effort: a hash expires in hours; a behavioral detection can last for years.
  • Avoiding both extremes: blocking thousands of expired IOCs that generate false positives, or ignoring IOCs and arriving late to an active campaign.

In 2013 David Bianco proposed the pyramid of pain: the higher an indicator sits, the more it costs the adversary to change it once the defender detects it.

flowchart TB
    T["TTPs<br/>Tough"]
    H["Tools<br/>Challenging"]
    A["Network and host artifacts<br/>Annoying"]
    D["Domain names<br/>Simple"]
    I["IP addresses<br/>Easy"]
    HA["Hash values<br/>Trivial"]
    T --- H --- A --- D --- I --- HA
Level Example Cost to the adversary Typical shelf life
Hashes SHA-256 of an executable Trivial: recompile or change one byte Hours or days
IP addresses A C2 server IP Easy: another VPS, proxies, residential networks Days
Domains C2 or phishing domain Simple: register another, though it costs something Days or weeks
Artifacts User agent, URI path, named pipe, registry key Annoying: the tool has to change Weeks or months
Tools A malware family or a specific framework Challenging: develop or buy another Months
TTPs LSASS dumping, deleting shadow copies before encryption Tough: change how they operate Years

The practical consequence: IOCs at the bottom help react fast to a specific campaign; detections at the top are the ones that last.

Type Examples Where it is applied Caveat
Files SHA-256, MD5, imphash, name and path EDR, antivirus, YARA A hash only identifies one exact version
Network IP, domain, URL, TLS certificate, JA4 Firewall, proxy, DNS, IDS Shared IPs (CDN, cloud) produce false positives
Email Sender, subject, sending server, attachment Email gateway (phishing) Senders change with every send
Host Registry keys, services, tasks, mutexes, named pipes EDR, Sysmon, fleet-wide search Some names mimic legitimate software
Behavior Process chain, command sequence, access pattern SIEM and EDR rules (detection) Needs full telemetry and tuning
flowchart LR
    A["Ingestion<br/>(report, feed, IR)"] --> B["Validation<br/>malicious?<br/>false positives?"]
    B --> C["Enrichment<br/>context, actor, technique,<br/>confidence"]
    C --> D["Deployment<br/>block, alert, retrospective<br/>search"]
    D --> E["Review<br/>has it alerted?<br/>still active?"]
    E --> F["Expiry<br/>retire or keep<br/>as history only"]
    E -.-> C
  • Validate before blocking: a cloud provider’s IP or an abused legitimate service’s domain will block legitimate traffic.
  • Retrospective search: when you receive an IOC, also search the logs from previous weeks; the adversary may already have been through.
  • Explicit expiry: every indicator carries a validity date (valid_until in STIX). A C2 IP from six months ago may belong to another organization today.
  • Measure: an indicator that never triggers an alert or a retrospective match may not be relevant to the organization.
  • STIX 2.1 to describe them with context (type, confidence, validity, relationship to actors and techniques) and TAXII to exchange them (CTI fundamentals).
  • MISP and OpenCTI are the most widespread open-source platforms for managing, correlating and sharing them with communities.
  • TLP 2.0 on every share, so the recipient knows how far each indicator may be redistributed.

Sigma is an open format for writing log-based detection rules, independent of the SIEM. The same rule is converted into each platform’s query. Rule for deleting shadow copies (ATT&CK technique T1490):

title: Shadow copy deletion with vssadmin
status: experimental
logsource:
category: process_creation
product: windows
detection:
selection:
Image|endswith: '\vssadmin.exe'
CommandLine|contains|all:
- 'delete'
- 'shadows'
condition: selection
level: high
tags:
- attack.impact
- attack.t1490

Conversion with pySigma 1.5.1 and its Splunk and Elasticsearch backends:

from sigma.collection import SigmaCollection
from sigma.backends.splunk import SplunkBackend
from sigma.backends.elasticsearch import LuceneBackend
rule = SigmaCollection.from_yaml(open("rule.yml").read())
print(SplunkBackend().convert(rule)[0])
print(LuceneBackend().convert(rule)[0])
Image="*\\vssadmin.exe" CommandLine="*delete*" CommandLine="*shadows*"
Image:*\\vssadmin.exe AND (CommandLine:*delete* AND CommandLine:*shadows*)

This rule sits at the top of the pyramid: it detects the behavior regardless of the ransomware group. Its weak spot is also instructive: deletion with wmic shadowcopy delete or with PowerShell does not match, which is why a good TTP rule usually combines several variants.

YARA describes malware families or artifacts by strings and conditions, not by hash. Lab rule tested with yara-python 4.5.4:

rule Ransom_note_lab
{
strings:
$a = "YOUR FILES HAVE BEEN ENCRYPTED" ascii wide nocase
$b = /[a-z2-7]{56}\.onion/ ascii
condition:
filesize < 50KB and all of them
}

On a note containing that text and a 56-character .onion address, the rule matches; on a normal text file, it does not. Unlike a hash, it keeps detecting the note even if the address or the amount changes. More detail in YARA.

Recent IOCs and the TTPs of relevant actors feed search hypotheses over historical telemetry (threat hunting), something real-time blocking does not cover.

  • 3CX supply chain (March 2023): 3CX’s desktop application, signed by the vendor itself, was distributed trojanized to its customers. The first IOCs (installer hashes, C2 domains) enabled a fast reaction, but the binary was legitimate and signed: blocking by hash or signature would have broken the company’s software, and many teams had to choose between stopping the application or keeping the business running. Mandiant later found the origin was an earlier supply chain compromise: a 3CX employee had installed compromised trading software. Lesson: IOCs help to respond, but what allowed the activity to be detected was the anomalous behavior of the signed process.
  • Volt Typhoon (advisory AA24-038A, 2024): an actor living off the land leaves very few useful IOCs (it uses the system’s own tools and compromised infrastructure that keeps changing). The advisory’s recommendations are based on behaviors and logging, not indicator lists. Lesson: against some actors, the bottom of the pyramid is practically empty.
  • Loading entire feeds into blocking without validation or deduplication.
  • No expiry: block lists that grow without limit and block reassigned IPs.
  • Measuring the CTI program by the number of IOCs ingested.
  • Treating a hash as sufficient detection of a malware family.
  • Writing TTP rules so broad that nobody handles their alerts, or so narrow that a variant slips past.
  • Every indicator with type, context, source, confidence and expiry date
  • False positive validation before blocking (cloud services, CDN, abused legitimate services)
  • Retrospective search when new indicators arrive
  • Periodic review and retirement of expired indicators
  • Indicators shared in STIX 2.1 / MISP with TLP 2.0
  • Behavioral detections (Sigma) for relevant actors’ TTPs, tagged with ATT&CK
  • YARA rules for relevant families in files and memory
  • Rules tested with real data and with variants of the technique