Technical Breakdown:
──────────────────
-
File Extension & Renaming Patterns
• Confirmation of File Extension: .WNCRY or .WCRY added after the original extension (e.g.,budget.xlsx.WNCRY).
• Renaming Convention: Files keep their original name and internal directory structure; the only visible change is the appended “.WNCRY”. Folders also receive the ransom note@[email protected], and the desktop wallpaper is replaced by@[email protected]. -
Detection & Outbreak Timeline
• Start Date: 12 May 2017 at 07:44 UTC, with an explosive global propagation wave that peaked before close-of-business on May 12. A kill-switch domain (iuqerfsodp9ifjaposdfjhgosurijfaewrwergwea.com) was registered later that day, dramatically reducing new infections. -
Primary Attack Vectors
• SMBv1 “EternalBlue” exploit (MS17-010) – wormable lateral movement once an initial foothold is gained.
• Remote Desktop Protocol brute-force used for initial foothold in many documented cases.
• Phishing e-mails with malicious attachments, often zips containing .exe or double-extension Office droppers.
• Watering-hole “drive-by” downloads observed against specific regional websites (original outbreak weeks showed additional Flash and Silverlight exploit chains).
Remediation & Recovery Strategies:
────────────────────────────────
-
Prevention
• Patch Windows systems immediately with MS17-010 (and black-list SMBv1 via group policy).
• Disable SMBv1 across the environment (sc config lanmanworkstation depend= bowser/mrxsmb20/nsi).
• Segment internal networks; block direct outbound SMB/TCP 445, 139/135.
• Enforce strong RDP passwords + 2-factor authentication; move RDP behind a VPN or jump host.
• Feature-locked backup snapshots stored offline or immutable (WORM, S3 Object Lock, GCS Bucket Lock, etc.).
• Application Control / Allow-listing; use of Microsoft Security Baselines & EMET/ASR rules.
• Continuous log ingestion + anomaly detection for rapid kill-switch domain lookups (DNS log monitoring). -
Removal (step-by-step)
-
Isolate the host: pull network cable / disable Wi-Fi immediately (Wannacry worm is active).
-
Identify and terminate MSSECSS.EXE and any spawned taskhsvc.exe, service.exe, @[email protected].
-
Delete the dropper payloads typically found in:
•%ProgramData%\{random-name}\taskhsvc.exe
•%UserProfile%\AppData\Local\Temp\b.wnry, c.wnry -
Remove persistence entries:
• Registry Run key:HKLM\Software\Microsoft\Windows\CurrentVersion\Runvalued “taskeche.exe”.
• Scheduled tasks “Taskee”, “DownloadAgent”. -
Deploy a reputable offline-scanner (Kaspersky Virus Removal Tool, Malwarebytes, Microsoft MSERT).
-
Reboot into Safe-Mode w/ Networking only after confirming traffic-blocking rules are in place, then patch.
-
File Decryption & Recovery
• Feasible by design? – YES
WannaCry uses a dual-layer encryption scheme:
1. Per-file AES-128 with a 128-bit key that is unique per file.
2. The AES keys are RSA-2048 encrypted with the attackers’ public key.
Shortly after the outbreak, release of the private RSA key used for Windows XP SP3 / Windows 7 (x86 & x64) was extracted from memory (source: Adrien Guinet – “Wannakey”) and later automated into “wanadecrypt” / “WannaDecrypt v2” – free tools that can decrypt absolute-disk reads where the memory page containing the key has remained unchanged.
• Procedure:
a. Do not power-cycle or wipe the system; keys stay in RAM only.
b. Image the infected drive bit-for-bit.
c. Boot a clean machine; run WanaKiwi (compatible w/ WinXP–Win7 x86/x64, memory must not have rebooted) or WannaKey + wanadecrypt lab tools.
d. Output = recovers raw AES keys → restores unencrypted files.
• What if RAM is lost? – Fallback to clean backups; the RSA public keys distributed in 2017 remain uncompromised for newer systems (Win8.1/Win10) unless law-enforcement seizes future private keys. -
Other Critical Information
• Double-kill switch: variant 2.1 hard-coded a second domain (ifferfsodp9ifjaposdfjhgosurijfaewrwergwea.com) found in July-2017; continuous passive monitoring of DNS early-warning lists is still recommended.
• Hidden-Tear ransom note similarity: C2 uses Tor v3 onion addresses; domain generation algorithm (DGA) not part of the 2017 dataset – so DNS blacklist is reliable.
• Screen-locker style distribution: renders systems practically unusable (>160 file types) and decommissioned shadow copies viavssadmin delete shadows /all /quiet. Maintain nightly VSS chains on isolated storage for secondary recovery.
• Broader Impact:
– Estimated 200 000+ machines across 150 countries within the first 24 h; significant collateral impact on critical medical systems (UK NHS), logistics (FedEx), and the world-wide Maersk shipping network (>$300 M loss).
– Solidified the case for “Patch Tuesday” emergency out-of-band and inspired modern frameworks such as CISA RA (“Ransomware Readiness Assessment”).