reverser-dotnet-malware
यह क्या करती है
यह .NET मैलवेयर की जाँच का तरीका बताती है, फ़ाइल पहचानने से लेकर उसका डिकोड किया कोड और सेटिंग पढ़ने तक। यह .NET नमूनों पर काम करने वाले मैलवेयर विश्लेषकों के लिए है।
कब इस्तेमाल करें
- ✓जब विश्लेषक को .NET में लिखा संदिग्ध Windows प्रोग्राम मिले और उसका स्रोत चाहिए।
- ✓जब शोधकर्ता को पढ़ने से पहले .NET फ़ाइल से obfuscation हटाना हो।
- ✓जब टीम को .NET सैंपल से छिपे कॉन्फ़िगरेशन मान निकालने हों।
Skill का लिंक
https://github.com/BitterSecurity/Decepticon/blob/main/packages/decepticon/decepticon/skills/standard/reverser/dotnet-malware/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“यह .NET फ़ाइल बहुत ज़्यादा स्क्रैम्बल की गई है। मैं पढ़ कैसे सकता हूँ कि यह क्या करती है?”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
यह स्किल फ़ाइल पहचानने, उसका obfuscation साफ़ करने, उसे पढ़ने योग्य कोड में डीकम्पाइल करने और कॉन्फ़िगरेशन निकालने के चरण देती है। हर चरण यह दर्ज करता है कि उसने क्या दिखाया।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
.NET Malware Analysis
Analyze .NET malware from initial triage through full decompilation, de-obfuscation, config extraction, and behavioral mapping.
Quick Reference
# Identify .NET assembly
file <TARGET>
python3 -c "import pefile; pe=pefile.PE('<TARGET>'); print('CLR:', pe.OPTIONAL_HEADER.DATA_DIRECTORY[14].VirtualAddress)"
# Fast metadata check
monodis --assembly <TARGET>
strings -n 10 <TARGET> | grep -iE 'System\.Reflection|Assembly\.Load|FromBase64|Invoke|WebClient|DownloadString'
# De-obfuscate with de4dot
de4dot <TARGET> -o <TARGET>.cleaned.exe
# Decompile to C# project
ilspycmd -p -o ./decompiled/ <TARGET>
# Extract embedded resources
python3 -c "
import dnfile
dn = dnfile.dnPE('<TARGET>')
for r in dn.net.resources:
print(f'{r.name} offset={r.offset} size={r.size}')
"
MITRE ATT&CK Mapping
| Technique | ID | How It Appears |
|---|---|---|
| Software Packing | T1027.002 | ConfuserEx, .NET Reactor, SmartAssembly, Babel packing |
| Deobfuscate/Decode | T1140 | Base64 decode + Assembly.Load, XOR decryption of payloads |
| PowerShell | T1059.001 | Cradle execution: powershell -enc <base64> from managed code |
| Obfuscated Files | T1027 | String encryption, control flow flattening, anti-tamper |
| Reflective Code Loading | T1620 | Assembly.Load(byte[]) for in-memory stage loading |
1. Identify .NET Assembly
Confirm the sample is managed code before committing to .NET tooling.
# Check PE headers for CLR data directory (index 14)
python3 << 'EOF'
import pefile, sys
pe = pefile.PE("<TARGET>")
clr_dir = pe.OPTIONAL_HEADER.DATA_DIRECTORY[14]
if clr_dir.VirtualAddress > 0:
print(f"[+] .NET assembly confirmed — CLR RVA: {hex(clr_dir.VirtualAddress)}")
# Check runtime version
import struct
clr_offset = pe.get_offset_from_rva(clr_dir.VirtualAddress)
pe.__data__.seek(clr_offset + 8)
major, minor = struct.unpack('<HH', pe.__data__.read(4))
print(f" Runtime: v{major}.{minor}")
else:
print("[-] Not a .NET assembly")
sys.exit(1)
EOF
# Alternative quick checks
file <TARGET> # Look for "Mono/.Net assembly"
exiftool <TARGET> | grep -i "assembly\|\.net\|framework"
2. Detect Obfuscator
Identify what protection was applied before attempting decompilation.
# de4dot auto-detects most obfuscators
de4dot --detect-only <TARGET>
# Output example: "Detected .NET Reactor 6.x"
# Detect It Easy (DIE) for packer/protector identification
diec <TARGET>
# Manual signature checks
strings <TARGET> | grep -iE 'ConfuserEx|Reactor|SmartAssembly|Babel|Crypto Obfuscator|Dotfuscator|Eazfuscator|AgileDotNet'
# Check for anti-tamper / anti-debug module initializers
monodis --method <TARGET> | grep -i "cctor\|InitializeComponent\|Module"
# Entropy per section — high entropy in .text = packed/encrypted
python3 << 'EOF'
import pefile, math
pe = pefile.PE("<TARGET>")
for s in pe.sections:
data = s.get_data()
if len(data) == 0: continue
counts = [data.count(bytes([b])) for b in range(256)]
total = len(data)
ent = -sum((c/total)*math.log2(c/total) for c in counts if c)
name = s.Name.decode().rstrip('\x00')
print(f" {name:10s} entropy={ent:.2f} {'PACKED' if ent > 7.2 else 'normal'}")
EOF
3. De-obfuscate
Strip protections layer by layer.
# de4dot — handles ConfuserEx, .NET Reactor, SmartAssembly, Babel, etc.
de4dot <TARGET> -o <TARGET>.cleaned.exe
# If de4dot detects "Unknown obfuscator", try force mode:
de4dot <TARGET> --strtyp delegate --strtok 0x06000042 -o <TARGET>.cleaned.exe
# For ConfuserEx specifically:
# 1. Remove anti-tamper first (patches module cctor)
de4dot <TARGET> --un-name "!^<Module>$&!^<" -o step1.exe
# 2. Then full clean
de4dot step1.exe -o <TARGET>.cleaned.exe
# For .NET Reactor:
# Use .NET Reactor Slayer or NETReactorSlayer
NETReactorSlayer.CLI <TARGET>
# Verify result decompiles cleanly
ilspycmd <TARGET>.cleaned.exe | head -50
4. Decompile and Analyze
Full source recovery from cleaned assembly.
# ILSpy command-line — full project decompilation
ilspycmd -p -o ./decompiled/ <TARGET>.cleaned.exe
# Search decompiled source for key behaviors
grep -rn "WebClient\|HttpClient\|WebRequest" ./decompiled/
grep -rn "Registry\|RegistryKey\|SetValue" ./decompiled/
grep -rn "Process\.Start\|ProcessStartInfo" ./decompiled/
grep -rn "Assembly\.Load\|Activator\.CreateInstance" ./decompiled/
grep -rn "FromBase64String\|Convert\.FromBase64" ./decompiled/
grep -rn "R
अक्सर पूछे जाने वाले सवाल
.NET क्या है?
यह Microsoft का सॉफ़्टवेयर फ़्रेमवर्क है, और कई Windows प्रोग्राम इससे बने होते हैं।
क्या यह स्क्रैम्बल किए गए कोड से निपटती है?
हाँ। यह बताती है कि कोड पढ़ने से पहले आम obfuscation टूल की सुरक्षा कैसे हटाई जाती है।
इसे कौन इस्तेमाल करता है?
.NET सैंपल का अध्ययन करने वाले मैलवेयर विश्लेषक और सुरक्षा टीमें।
जानकारी
लेखक का मूल विवरण
.NET malware analysis — dnSpy/ILSpy decompilation, de-obfuscation (ConfuserEx, .NET Reactor, Babel, Crypto Obfuscator), behavioral analysis of managed assemblies, PowerShell cradle extraction, and config decryption for common .NET RAT families.
लोकप्रियता
- GitHub स्टार
- 6.5k
- रैंकिंग में स्थान
- #14164
- लाइसेंस
- Apache-2.0
- अपडेट की गई
- 1/11/2026
कमेंट
- …
इस repository की और skills
detector-overview
6.5kयह आपके एजेंट को स्कैनर से चिह्नित कोड पढ़ने और तय करने में मदद करती है कि कौन सी जगहें असली सुरक्षा बग हैं और कौन सी गलत चेतावनी।
exploiter-overview
6.5kयह आपके एजेंट को कई पक्की सुरक्षा कमज़ोरियों को एक परीक्षण श्रृंखला में जोड़ने और जाँचने में मदद करती है कि वह श्रृंखला कितनी दूर तक पहुँच सकती है।
llm-redteam-overview
6.5kयह आपके एजेंट को परीक्षण के लिए सही AI रेड-टीम गाइड खोजने में मदद करती है, प्रॉम्प्ट इंजेक्शन से लेकर मॉडल के दुरुपयोग तक 15 रणनीति समूहों में।
aatmf-t01-prompt-injection
6.5kसमझाती है कि प्रॉम्प्ट इंजेक्शन क्या है, जिसमें छिपे निर्देश AI सिस्टम के नियम बदलने की कोशिश करते हैं, ताकि सुरक्षा परीक्षक उसकी जाँच कर सकें।
मिलती-जुलती skills
reverse-engineer-anything
422kयह आपके एजेंट को REA टूल से शिप हुई ऐप्स और पैकेज को अंदर से समझने, वर्ज़न की तुलना करने या दोबारा बनाने में मदद करती है।
1password
394kयह आपके एजेंट को 1Password CLI सेट करने, साइन इन करने और सीक्रेट्स की वैल्यू चैट में छापे बिना उन्हें पढ़ने या इस्तेमाल करने में मदद करती है।
healthcheck
394kयह आपके एजेंट को उस कंप्यूटर या सर्वर का सुरक्षा ऑडिट करने देती है जिस पर OpenClaw चलता है, जिसमें SSH, firewall, अपडेट और बैकअप शामिल हैं, और फिर सुरक्षित सुधार सुझाती है।