Skip to main content
COSMICBYTEZLABS
NewsSecurityHOWTOsToolsStudyTraining
ProjectsChecklistsAI RankingsNewsletterStatusTagsAbout
Subscribe

Press Enter to search or Esc to close

News
Security
HOWTOs
Tools
Study
Training
Projects
Checklists
AI Rankings
Newsletter
Status
Tags
About
RSS Feed
Reading List
Subscribe

Stay in the Loop

Get the latest security alerts, tutorials, and tech insights delivered to your inbox.

Subscribe NowFree forever. No spam.
COSMICBYTEZLABS

Your trusted source for IT intelligence, cybersecurity insights, and hands-on technical guides.

429+ Articles
114+ Guides

CONTENT

  • Latest News
  • Security Alerts
  • HOWTOs
  • Projects
  • Exam Prep

RESOURCES

  • Search
  • Browse Tags
  • Newsletter Archive
  • Reading List
  • RSS Feed

COMPANY

  • About Us
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CosmicBytez Labs. All rights reserved.

System Status: Operational
  1. Home
  2. HOWTOs
  3. Incident Response Playbook: Ransomware
Incident Response Playbook: Ransomware
HOWTOAdvanced

Incident Response Playbook: Ransomware

Complete ransomware incident response playbook following NIST framework. Covers detection, containment, eradication, recovery, and lessons learned.

Dylan H.

Security Operations

February 3, 2026
11 min read

Prerequisites

  • Understanding of incident response fundamentals
  • Access to security monitoring tools (SIEM, EDR)
  • Familiarity with forensic concepts
  • Established IR team and communication channels

Overview

Ransomware attacks continue to be one of the most devastating cyber threats, capable of crippling organizations within hours. This playbook provides a structured approach to ransomware incident response, following the NIST Cybersecurity Framework and industry best practices.

Who Should Use This Playbook:

  • Incident Response (IR) teams responding to active incidents
  • Security Operations Center (SOC) analysts
  • IT administrators handling security events
  • CISOs and security leaders developing IR procedures

NIST Incident Response Lifecycle:

┌────────────────────────────────────────────────────────────────────┐
│                    NIST IR Lifecycle                                │
├────────────────────────────────────────────────────────────────────┤
│                                                                    │
│  ┌──────────────┐    ┌──────────────┐    ┌──────────────┐         │
│  │  Preparation │───▶│  Detection & │───▶│ Containment, │         │
│  │              │    │   Analysis   │    │ Eradication, │         │
│  │              │    │              │    │  & Recovery  │         │
│  └──────────────┘    └──────────────┘    └──────┬───────┘         │
│         ▲                                        │                 │
│         │         ┌──────────────┐               │                 │
│         └─────────│Post-Incident │◀──────────────┘                 │
│                   │  Activity    │                                 │
│                   └──────────────┘                                 │
│                                                                    │
└────────────────────────────────────────────────────────────────────┘

Severity Classification:

SeverityCriteriaResponse Time
CriticalProduction systems encrypted, business stoppedImmediate (24/7)
HighSignificant systems affected, spreading< 1 hour
MediumLimited scope, contained to segment< 4 hours
LowSingle endpoint, no spread< 24 hours

Phase 1: Detection and Identification

Initial Detection Sources

Common Ransomware Indicators:

SourceIndicatorPriority
EDR AlertRansomware behavior detectedCritical
User ReportFiles encrypted, ransom noteCritical
SIEM AlertMass file encryption activityCritical
AV AlertKnown ransomware signatureHigh
File ServerUnusual file extension changesHigh
Backup SystemBackup deletion attemptsHigh
Network MonitorC2 communication detectedHigh

Initial Triage Checklist:

□ Confirm this is ransomware (not false positive)
□ Identify affected systems (hostname, IP, user)
□ Determine ransomware variant if possible
□ Assess current scope (endpoints, servers, segments)
□ Check if attack is active or completed
□ Identify any ransom notes or communications
□ Document initial timeline of events

Ransomware Identification

Collect Ransom Note:

# Search for common ransom note filenames
$ransomNotes = @(
    "*README*.txt", "*DECRYPT*.txt", "*RESTORE*.txt",
    "*HOW_TO*.txt", "*HELP*.txt", "*.hta"
)
 
foreach ($pattern in $ransomNotes) {
    Get-ChildItem -Path "C:\" -Filter $pattern -Recurse -ErrorAction SilentlyContinue |
    Select-Object FullName, LastWriteTime | Format-Table
}

Identify Ransomware Family:

  1. ID Ransomware: https://id-ransomware.malwarehunterteam.com/
  2. No More Ransom: https://www.nomoreransom.org/
  3. Upload encrypted file sample + ransom note
  4. Document identified variant and known decryptors

Collect Encrypted File Sample:

# Find recently modified encrypted files
Get-ChildItem -Path "C:\Users" -Recurse -File -ErrorAction SilentlyContinue |
Where-Object { $_.LastWriteTime -gt (Get-Date).AddHours(-24) } |
Where-Object { $_.Extension -match "\.(encrypted|locked|crypt|enc)$" } |
Select-Object -First 5 FullName, Extension, LastWriteTime

Phase 2: Containment

Immediate Containment Actions

CRITICAL: Within First 15 Minutes

┌─────────────────────────────────────────────────────────────────┐
│              IMMEDIATE CONTAINMENT ACTIONS                       │
├─────────────────────────────────────────────────────────────────┤
│                                                                 │
│  1. ISOLATE affected systems from network                       │
│     - Disable network adapter (don't power off)                 │
│     - Block at switch port / firewall                          │
│     - Quarantine in EDR                                         │
│                                                                 │
│  2. PRESERVE evidence                                           │
│     - Do NOT shut down systems (memory forensics)              │
│     - Take screenshots of ransom notes                         │
│     - Document all actions with timestamps                     │
│                                                                 │
│  3. PROTECT backup systems                                      │
│     - Disconnect backup infrastructure                          │
│     - Verify backup integrity                                   │
│     - Air-gap critical backups                                  │
│                                                                 │
│  4. ALERT key stakeholders                                      │
│     - IR team lead                                              │
│     - IT management                                             │
│     - Legal/Compliance (if required)                           │
│                                                                 │
└─────────────────────────────────────────────────────────────────┘

Network Isolation Commands:

# PowerShell - Disable network adapters (preserves memory)
Get-NetAdapter | Disable-NetAdapter -Confirm:$false
 
# Windows - Isolate via Windows Firewall
netsh advfirewall set allprofiles state on
netsh advfirewall firewall add rule name="IR-Block-All" dir=out action=block
netsh advfirewall firewall add rule name="IR-Block-In" dir=in action=block

EDR Isolation (Examples):

# Microsoft Defender for Endpoint
# Via Security Center: Device page → Isolate device
 
# SentinelOne
# Console: Sentinels → Select agent → Actions → Network Quarantine
 
# CrowdStrike Falcon
# Console: Hosts → Select host → Network Contain

FortiGate Quarantine:

# Block specific IP at firewall
config firewall address
    edit "Quarantine-<Hostname>"
        set type ipmask
        set subnet <IP> 255.255.255.255
    next
end
 
config firewall policy
    edit 0
        set name "Block-Quarantine"
        set srcintf "any"
        set dstintf "any"
        set srcaddr "Quarantine-<Hostname>"
        set dstaddr "all"
        set action deny
        set schedule "always"
        set service "ALL"
    next
end

Contain Lateral Movement

Identify Potential Spread:

# Check for lateral movement indicators
# Recent RDP connections
Get-WinEvent -LogName "Microsoft-Windows-TerminalServices-LocalSessionManager/Operational" -MaxEvents 50 |
Where-Object { $_.Id -eq 21 -or $_.Id -eq 25 } |
Select-Object TimeCreated, Message
 
# Recent SMB connections
Get-SmbConnection | Select-Object ServerName, ShareName, UserName
 
# Check scheduled tasks for persistence
Get-ScheduledTask | Where-Object { $_.Date -gt (Get-Date).AddDays(-7) } |
Select-Object TaskName, TaskPath, Date

Block Lateral Movement Protocols:

# FortiGate - Block SMB/RDP between segments during incident
config firewall policy
    edit 0
        set name "IR-Block-Lateral"
        set srcintf "internal"
        set dstintf "internal"
        set srcaddr "all"
        set dstaddr "all"
        set action deny
        set service "SMB" "RDP"
        set schedule "always"
    next
end

Active Directory Protections:

# Reset compromised accounts
Set-ADAccountPassword -Identity "<compromised-user>" -Reset -NewPassword (ConvertTo-SecureString -AsPlainText "TempP@ss123!" -Force)
Disable-ADAccount -Identity "<compromised-user>"
 
# Reset KRBTGT (twice, 10+ hours apart for full rotation)
# WARNING: This will invalidate all Kerberos tickets
# Only do this if AD compromise is confirmed
# Reset-KrbtgtPassword -DomainName "domain.local"

Phase 3: Evidence Collection

Forensic Evidence Preservation

Evidence Collection Priority:

PriorityEvidence TypeVolatility
1Memory (RAM)Very High
2Running processesVery High
3Network connectionsHigh
4Logs (Security, System)Medium
5Disk imageLow
6Ransom notes, encrypted filesLow

Memory Acquisition:

# Using WinPMEM (download from GitHub)
.\winpmem_mini_x64.exe memory.raw
 
# Using DumpIt
.\DumpIt.exe
 
# Output location: Document and preserve chain of custody

Collect Volatile Data:

# Create collection directory
$collectionPath = "C:\IR-Collection-$(Get-Date -Format 'yyyyMMdd-HHmmss')"
New-Item -ItemType Directory -Path $collectionPath
 
# Running processes
Get-Process | Select-Object Id, ProcessName, Path, StartTime |
Export-Csv "$collectionPath\processes.csv" -NoTypeInformation
 
# Network connections
Get-NetTCPConnection | Select-Object LocalAddress, LocalPort, RemoteAddress, RemotePort, State, OwningProcess |
Export-Csv "$collectionPath\network-connections.csv" -NoTypeInformation
 
# DNS cache
Get-DnsClientCache | Export-Csv "$collectionPath\dns-cache.csv" -NoTypeInformation
 
# Scheduled tasks
Get-ScheduledTask | Export-Csv "$collectionPath\scheduled-tasks.csv" -NoTypeInformation
 
# Services
Get-Service | Select-Object Name, DisplayName, Status, StartType |
Export-Csv "$collectionPath\services.csv" -NoTypeInformation
 
# Recent file modifications
Get-ChildItem -Path "C:\" -Recurse -File -ErrorAction SilentlyContinue |
Where-Object { $_.LastWriteTime -gt (Get-Date).AddHours(-24) } |
Export-Csv "$collectionPath\recent-files.csv" -NoTypeInformation

Export Windows Event Logs:

# Security log
wevtutil epl Security "$collectionPath\Security.evtx"
 
# System log
wevtutil epl System "$collectionPath\System.evtx"
 
# PowerShell logs
wevtutil epl "Microsoft-Windows-PowerShell/Operational" "$collectionPath\PowerShell.evtx"
 
# Defender logs
wevtutil epl "Microsoft-Windows-Windows Defender/Operational" "$collectionPath\Defender.evtx"

Timeline Analysis

Key Events to Identify:

EventWindows Event IDSignificance
Logon4624Initial access point
Failed logon4625Brute force attempts
Process creation4688Malware execution
Service installed7045Persistence mechanism
RDP connection1149Lateral movement
SMB share access5140Data access
Scheduled task4698Persistence
PowerShell execution4104Script execution

Query Security Logs:

# Find initial access (Type 10 = Remote RDP, Type 3 = Network)
Get-WinEvent -FilterHashtable @{
    LogName = 'Security'
    ID = 4624
} -MaxEvents 1000 |
Where-Object { $_.Properties[8].Value -in @(3, 10) } |
Select-Object TimeCreated,
    @{N='Account'; E={$_.Properties[5].Value}},
    @{N='LogonType'; E={$_.Properties[8].Value}},
    @{N='SourceIP'; E={$_.Properties[18].Value}}
 
# Find process creation events
Get-WinEvent -FilterHashtable @{
    LogName = 'Security'
    ID = 4688
} -MaxEvents 500 |
Select-Object TimeCreated,
    @{N='Process'; E={$_.Properties[5].Value}},
    @{N='CommandLine'; E={$_.Properties[8].Value}}

Phase 4: Eradication

Remove Ransomware Artifacts

Identify Persistence Mechanisms:

# Check Run keys
Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Run"
Get-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Run"
 
# Check scheduled tasks
Get-ScheduledTask | Where-Object { $_.State -eq "Ready" } |
Select-Object TaskName, TaskPath, @{N='Actions'; E={$_.Actions.Execute}}
 
# Check services
Get-WmiObject Win32_Service | Where-Object { $_.PathName -notlike "*Windows*" } |
Select-Object Name, PathName, StartMode
 
# Check startup folder
Get-ChildItem "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup"
Get-ChildItem "$env:APPDATA\Microsoft\Windows\Start Menu\Programs\Startup"

Remove Persistence:

# Remove malicious scheduled task
Unregister-ScheduledTask -TaskName "<malicious-task>" -Confirm:$false
 
# Remove malicious service
Stop-Service -Name "<malicious-service>" -Force
sc.exe delete "<malicious-service>"
 
# Remove registry persistence
Remove-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" -Name "<malicious-entry>"
 
# Delete malicious files (after forensic collection)
Remove-Item -Path "<malicious-file-path>" -Force

Clean with EDR:

  1. Run full system scan
  2. Review and remediate all detections
  3. Verify no active threats remain
  4. Check for dormant/scheduled malware

Validate Clean State

Verification Checklist:

□ No malicious processes running
□ No suspicious network connections
□ No persistence mechanisms remain
□ EDR shows clean status
□ AV scan completes with no detections
□ Startup items verified clean
□ Scheduled tasks reviewed
□ Services reviewed
□ User accounts audited

Phase 5: Recovery

Recovery Priority

Recovery Order:

PrioritySystemsJustification
1Domain ControllersAuthentication required for all systems
2DNS/DHCPNetwork services
3Backup InfrastructureRequired for restoration
4Critical Business SystemsRevenue/operations
5File ServersUser data access
6End User WorkstationsEmployee productivity

Restore from Backup

Pre-Restoration Checks:

□ Backup integrity verified (not encrypted)
□ Backup predates infection (check timeline)
□ Clean environment ready for restoration
□ Network isolation maintained during restore
□ Credentials reset for restored systems

Restoration Process:

  1. Verify backup integrity
# Veeam - Check backup job status
Get-VBRBackup | Where-Object { $_.JobType -eq "Backup" } |
Select-Object Name, LastResult, LastPointCreationTime
 
# Azure Backup - List recovery points
az backup recoverypoint list --resource-group <RG> --vault-name <Vault> --container-name <Container> --item-name <Item>
  1. Restore to isolated network
- Create isolated VLAN for restoration
- No connection to production network
- Verify restored system is clean
- Run full security scan
- Check for persistence
  1. Validate before reconnection
# Verify no malicious files
Get-ChildItem -Path "C:\" -Recurse -Include "*.exe", "*.dll" -ErrorAction SilentlyContinue |
Where-Object { $_.LastWriteTime -gt $infectionDate } |
Select-Object FullName, LastWriteTime
 
# Verify no scheduled tasks
Get-ScheduledTask | Where-Object { $_.Date -gt $infectionDate }
 
# Verify services
Get-Service | Where-Object { $_.Status -eq "Running" -and $_.StartType -eq "Automatic" }

Password Reset Strategy

Critical Password Resets:

Account TypeActionPriority
Domain AdminReset immediatelyCritical
Service AccountsReset and update servicesCritical
KRBTGTReset twice (10+ hours apart)High
All privileged accountsReset before reconnectionHigh
All user accountsForce password change at logonMedium
# Force password change for all users
Get-ADUser -Filter * | Set-ADUser -ChangePasswordAtLogon $true
 
# Reset specific privileged account
Set-ADAccountPassword -Identity "admin-account" -Reset -NewPassword (Read-Host -AsSecureString "New Password")

Phase 6: Post-Incident Activities

Lessons Learned

Post-Incident Review Meeting:

TopicQuestions to Address
DetectionHow was the incident detected? Could we detect earlier?
ResponseWhat went well? What could be improved?
ContainmentWas containment effective? How fast?
CommunicationWere stakeholders informed appropriately?
ToolsDid our tools perform as expected?
TrainingWhat training gaps were identified?

Documentation Requirements:

1. Incident Timeline
   - Initial detection time
   - Key response actions with timestamps
   - Recovery completion time
   - Total incident duration
 
2. Technical Analysis
   - Attack vector (how did they get in?)
   - Ransomware variant and behavior
   - Systems affected
   - Data potentially exfiltrated
 
3. Business Impact
   - Downtime duration
   - Systems affected
   - Data loss (if any)
   - Financial impact estimate
 
4. Recommendations
   - Security improvements needed
   - Process improvements
   - Training needs
   - Tool enhancements

Improve Defenses

Common Ransomware Attack Vectors:

VectorMitigation
Phishing emailEmail filtering, user training, DMARC
RDP exposureMFA, VPN-only access, network segmentation
Vulnerable softwarePatch management, vulnerability scanning
Compromised credentialsMFA, privileged access management, credential monitoring
Supply chainVendor assessment, software allowlisting

Recommended Improvements:

□ Implement/improve backup strategy (3-2-1 rule, air-gapped)
□ Enable MFA on all privileged accounts
□ Deploy EDR with ransomware protection
□ Implement network segmentation
□ Enable PowerShell logging and constraints
□ Improve email filtering and user training
□ Establish incident response retainer
□ Conduct regular IR tabletop exercises

Communication Templates

Internal Notification

SUBJECT: [SECURITY INCIDENT] Ransomware Detected - ACTION REQUIRED
 
Priority: CRITICAL
Time: [TIMESTAMP]
Incident ID: [IR-YYYY-###]
 
SITUATION:
We have detected ransomware activity affecting [SCOPE]. The Incident Response team is actively responding.
 
IMMEDIATE ACTIONS:
1. Do NOT attempt to access affected systems
2. Do NOT open suspicious emails or attachments
3. Report any unusual system behavior immediately
4. [Additional specific instructions]
 
CURRENT STATUS:
- Affected systems have been isolated
- Investigation is ongoing
- Backup integrity is being verified
 
NEXT UPDATE: [TIME]
 
Contact: [IR Team Contact]

Executive Brief

EXECUTIVE INCIDENT BRIEF
Incident: Ransomware Attack
Date: [DATE]
Status: [Active Response / Contained / Recovered]
 
SUMMARY:
[Brief description of incident, scope, and current status]
 
IMPACT:
- Systems Affected: [COUNT/LIST]
- Business Functions Impacted: [LIST]
- Estimated Downtime: [DURATION]
- Data at Risk: [ASSESSMENT]
 
RESPONSE STATUS:
- Containment: [Complete/In Progress]
- Eradication: [Complete/In Progress]
- Recovery: [Complete/In Progress/Pending]
 
NEXT STEPS:
1. [Action item]
2. [Action item]
3. [Action item]
 
ESTIMATED RECOVERY: [TIMEFRAME]

Quick Reference

Critical Contact List

RoleContactResponsibility
IR Lead[Name/Phone]Overall incident command
IT Operations[Name/Phone]System isolation and recovery
Security Team[Name/Phone]Investigation and analysis
Legal/Compliance[Name/Phone]Regulatory requirements
Communications[Name/Phone]Internal/external messaging
Executive Sponsor[Name/Phone]Business decisions
External IR Firm[Name/Phone]Additional support if needed
Cyber Insurance[Policy #/Phone]Claim notification
Law EnforcementFBI IC3/LocalReporting if required

Decision Tree

RANSOMWARE DETECTED
        │
        ▼
Is attack active (spreading)?
    │           │
   YES          NO
    │           │
    ▼           ▼
ISOLATE       Assess scope
IMMEDIATELY   and impact
    │           │
    ▼           ▼
Preserve      Collect
evidence      evidence
    │           │
    └─────┬─────┘
          ▼
    Can we recover
    from backup?
    │           │
   YES          NO
    │           │
    ▼           ▼
Proceed to    Consider
recovery      options*
    │           │
    ▼           ▼
Reset all     Engage legal,
credentials   insurance, IR firm

*Options may include negotiation as last resort - always involve legal and insurance.


Verification Checklist

Incident Closed Criteria:

  • All affected systems identified and documented
  • Root cause determined
  • All malware artifacts removed
  • Systems restored and validated
  • Credentials reset across environment
  • Monitoring enhanced for indicators
  • Lessons learned documented
  • Recommendations provided to leadership
  • Insurance claim filed (if applicable)
  • Regulatory notifications made (if required)

References

  • NIST SP 800-61 Rev. 2 - Incident Handling Guide
  • CISA Ransomware Guide
  • No More Ransom Project
  • ID Ransomware
  • MITRE ATT&CK - Ransomware

Last Updated: February 2026

#Incident Response#Ransomware#Security Operations#DFIR#NIST#Cyber Security

Related Articles

How to Deploy Wazuh SIEM/XDR for Unified Security Monitoring

Step-by-step guide to deploying Wazuh as an open-source SIEM and XDR platform. Covers server installation, agent deployment across Windows and Linux,...

13 min read

How to Configure Microsoft Sentinel Analytics Rules

End-to-end SOC guide for Microsoft Sentinel: build KQL-based scheduled and NRT analytics rules, wire automation rules for incident triage, and deploy...

15 min read

Security Baseline Hardening: CIS Controls Implementation

Implement CIS Critical Security Controls for enterprise security. Covers IG1/IG2/IG3 controls mapping, implementation priorities, and tooling recommendations.

17 min read
Back to all HOWTOs