🔍 Contexte

Publié le 9 avril 2026 par Evgen Blohm (InfoGuard Labs), cet article est issu d’une investigation de réponse à incident liée à une attaque DragonForce ransomware. Lors de la revue de persistance, un artefact inhabituel a été identifié : une tâche planifiée nommée 523135538 exécutant C:\ProgramData\cp49s\pythonw.exe sans arguments.

🧩 Mécanisme de persistance et chargement

La persistance repose sur sitecustomize.py, un module Python auto-importé au démarrage. Ce fichier utilise ctypes pour appeler Py_GetArgcArgv et vérifier le contexte d’exécution. Si argc == 1, il charge et exécute b5yogiiy3c.dll (un script Python déguisé en DLL) via runpy.run_path().

🔐 Obfuscation multi-couches

Le fichier b5yogiiy3c.dll présente trois couches d’obfuscation :

  • Encodage Base85 (b85decode) et compression zlib
  • Primitives cryptographiques : blake3, SHA256, AES, ChaCha20, PBKDF2, HKDF
  • Aplatissement du flux de contrôle (control-flow flattening) avec boucle while True et variable d’état
  • Noms de fonctions et variables aléatoires pour contrer l’analyse statique
  • Exécution en mémoire via compile() + exec() avec nom de fichier synthétique <jK6xvQeYbpkDD>

🌐 Payload final : proxy SOCKS5

Le payload final implémente un proxy SOCKS5 avec tunnel sortant vers un C2 hardcodé sur le port 443 (mimétisme HTTPS). Il comprend trois classes :

  • Commander : thread principal, handshake C2, instancie les Relay
  • Relay : logique SOCKS5, médiation entre C2 et réseau local
  • Wire : abstraction socket, encapsulation des données du tunnel

Credentials hardcodés : AnyUser / AnyPassword.

📊 Clustering chronologique (4 groupes)

Groupe Période Caractéristiques
Early Development Déc. 2023 Typos, pas de C2 hardcodé, pas d’obfuscation
Adoption outils publics Sept. 2024 Minification, PyOBFUSCATE, C2 via argv
Refinement & Debugging Déc. 2024 – Sept. 2025 Debug flags, argparse, C2 hardcodé introduit
Modern Production Sept. – Déc. 2025 Classes Wire/Relay/Commander, port hardcodé, stealth

🔗 Infrastructure et Pyramid C2

L’infrastructure C2 présente une signature distinctive :

  • Ports ouverts : 22 (SSH), 443, 8000 (Pyramid C2)
  • Port 443 retourne 00 00 statique
  • Port 8000 : réponse HTTP 401 avec WWW-Authenticate: Basic realm="Proxy" (déviation du défaut Pyramid Demo Realm)
  • Double header Python Server basé sur BaseHTTP avec versions variables (spoofing probable)
  • 100% des IPs géolocalisées aux États-Unis
  • OS majoritaire : Ubuntu 22.04 LTS (SSH-2.0-OpenSSH_8.9p1)
  • Pyramid délivre du code chiffré (ChaCha20/XOR) et inclut secretsdump.py, LaZagne.py

Query Censys pivot : host.services.banner_hex = "0000" AND host.services.protocol: "SSH" AND "python"

Body hash HTTP 401 : 537a7628eb1b2fe117c9081e65579397a4d9b63f227802cac4028f4c34e2b337

🦠 ShadowCoil : malware connexe

ShadowCoil (alias COILCAGE, RATTLEGRAB) partage le même framework d’obfuscation que VIPERTUNNEL. C’est un stealer de credentials ciblant Chrome, Edge et Firefox. Il inclut des vérifications anti-debug Linux (TracerPid dans /proc/self/status), suggérant un développement cross-platform en cours.

🎯 Attribution

ViperTunnel est attribué à UNC2165 / EvilCorp (sources : Google Threat Horizons, GuidePoint Security). Souvent déployé en follow-on de FAKEUPDATES, l’accès est monétisé ou revendu à des groupes ransomware. Le lien avec DragonForce dans cet incident n’est pas confirmé.

📄 Type d’article

Analyse technique approfondie issue d’un IR réel, visant à documenter le malware VIPERTUNNEL, son évolution, son infrastructure et à fournir des règles YARA et IOCs exploitables pour la threat hunting.

🧠 TTPs et IOCs détectés

Acteurs de menace

TTP

  • T1053.005 — Scheduled Task/Job: Scheduled Task (Persistence)
  • T1546.001 — Event Triggered Execution: Change Default File Association (Persistence)
  • T1027 — Obfuscated Files or Information (Defense Evasion)
  • T1027.002 — Obfuscated Files or Information: Software Packing (Defense Evasion)
  • T1059.006 — Command and Scripting Interpreter: Python (Execution)
  • T1090.001 — Proxy: Internal Proxy (Command and Control)
  • T1090.003 — Proxy: Multi-hop Proxy (Command and Control)
  • T1071.001 — Application Layer Protocol: Web Protocols (Command and Control)
  • T1573 — Encrypted Channel (Command and Control)
  • T1055 — Process Injection (Defense Evasion)
  • T1140 — Deobfuscate/Decode Files or Information (Defense Evasion)
  • T1555.003 — Credentials from Password Stores: Credentials from Web Browsers (Credential Access)
  • T1497.001 — Virtualization/Sandbox Evasion: System Checks (Defense Evasion)

IOC

Malware / Outils

  • VIPERTUNNEL (backdoor)
  • ShadowCoil (stealer)
  • Pyramid (framework)
  • FAKEUPDATES (loader)
  • LaZagne (tool)
  • secretsdump (tool)
  • PyOBFUSCATE (tool)
  • DragonForce (ransomware)

🟢 Indice de vérification factuelle : 75/100 (haute)

  • ⬜ labs.infoguard.ch — source non référencée (0pts)
  • ✅ 30224 chars — texte complet (fulltext extrait) (15pts)
  • ✅ 43 IOCs dont des hashes (15pts)
  • ✅ 5/6 IOCs confirmés (AbuseIPDB, ThreatFox, URLhaus, VirusTotal) (15pts)
  • ✅ 13 TTPs MITRE identifiées (15pts)
  • ✅ date extraite du HTML source (10pts)
  • ✅ acteur(s) identifié(s) : UNC2165, EvilCorp, DragonForce (5pts)
  • ⬜ pas de CVE à vérifier (0pts)

IOCs confirmés externellement :

  • 38.146.28.93 (ip) → VT (16/94 détections) + ThreatFox (RansomHub)
  • 38.135.54.24 (ip) → VT (13/94 détections) + ThreatFox (RansomHub)
  • CarryingItAll.com (domain) → VT (5/94 détections)
  • rentiantech.com (domain) → VT (3/94 détections)
  • chateaugalicia.com (domain) → VT (4/94 détections)

🔗 Source originale : https://labs.infoguard.ch/posts/slithering_through_the_noise/