🐳
Swayam's Blog
LinkedinGithub
  • 🫚root@Swayam's Blog
  • 🕺About Me
  • 🛠️Projects
    • CurveLock
    • ShadowChain
  • 🐞Malware Analysis
    • Basic Malware Analysis
      • LAB Network Setup
      • Basic Static Analysis
      • Basic Dynamic Analysis
      • Advanced Dynamic Analysis
      • Advanced Static Analysis
      • Identifying Anti analysis techniques
      • Binary Patching
      • Shellcode Analysis
      • Malware.unknown.exe.Malz
      • Challenge-Sillyputty
      • Bind_shell RAT Analysis
      • Malicious Powershell Script
      • Malicious HTA(HTML Applications)
      • Phishing Excel Embedded Malware
      • Reversing Csharp And DotNET Framework
      • YARA rules
      • Automating Malware Analysis
    • MASM 64 Bit Assembly
      • Hello World Of Assembly Language
      • Computer Data Representation and Operations
      • Memory Access And Organization
      • Constants, Variables And Data Types
      • Procedures
  • 👨‍💻Malware/Exploit Development
    • Driver Development
      • Driver 101
      • Kernel Calbacks
      • Process Protection
      • Process Token Privilege
  • 📖Notes And Cheatsheets
    • OSCP / Application Security
      • OS stuff
        • Footprinting
        • Nmap
        • Shells
        • Metasploit
        • Windows Buffer Overflow
        • Windows
        • Windows Privilege Escalation
        • Linux Commands
        • Linux Privilege Escalation
        • Password Cracking
        • Pivoting And Tunneling
        • Macos
      • General Introduction
        • Basic Tools
        • Basic Networking
      • WebApps
        • Attacking Common Applications
        • Attacking Common Services
        • Broken Authentication
        • Burp Proxy
        • Common Apps
        • Command Injection
        • ffuf Fuzzing
        • File Inclusion
        • File Transfer
        • File Upload
        • Javascript Deobfuscation
        • Password Attacks
        • SQLi
        • Web attacks
        • Web Information Gathering
        • Wordpress
        • Brute Forcing
        • HTTP Curl
      • Active Directory
    • Wireless Attacks
    • Red Teaming
    • BloodHound
    • Pentesting
    • ADCS
  • 🚩CTFs
    • Google CTF
Powered by GitBook
On this page
  • Sample Details
  • Analysis
  • Note-
  • Conclusion
  1. Malware Analysis
  2. Basic Malware Analysis

Reversing Csharp And DotNET Framework

PreviousPhishing Excel Embedded MalwareNextYARA rules

Last updated 1 month ago

Sample Details


Sample Name-Malware.cryptlib64.dll Malware Type- C2 Dropper

Analysis


Upon running floss we see some interesting strings-

mscorelib is a part of a C# binary. Thus this is a C# binary and a part of the .NET framework.

Note-

C# is part of the .NET framework. C# binaries don't interact directly with the OS but with the .NET framework. C# is executed by the CLR(common Language Runtime). After C# is compiled, it is converted to IL(Intermediary Language) which is further run by the CLR.

Turn on inetsim on REMnux and use DNSspy on flare-vm

On dnspy we get-

The dll has two classes - Cryptor and Program

Cryptor-

Program-

We see a base64 string in Program function.

Also a xml and a vbs file is being created. Now we run the dll using rundll32 and the main method of the dll - embed.

	 rundll32.exe .\Malware.cryptlib64.dll,embed

After running, we find the xml file -

Also a registry key has been created by the dll pointing to the vbs file-

The xml file is using MSBuild to execute malware. Running it-

It is requesting for something off of -http://ocsp.digicert.com and srv.masterchiefsgruntemporium.local.

Conclusion


This is a C2 dropper from the Covenant C2 framework. When run, a grunt from the c2 framework will deliver the malware to the system.

🐞