Collecting orders from Command and Control servers by impersonating an infected machine
@xanhacks
https://slides.com/xanhacks/c2-active-monitor/
# whoami
C2 Active Monitoring - @xanhacks
@xanhacks
# introduction
C2 Active Monitoring - @xanhacks
Samples (malicious files)
Types:
Format:
C&C or C2 (Command & Controls)
Goal: Communicate with samples/victims.
Protocols:
Features:
C2 Active Monitoring - @xanhacks
https://blog.sekoia.io/nobeliums-envyscout-infection-chain-goes-in-the-registry-targeting-embassies/
https://www.trellix.com/blogs/research/qakbot-evolves-to-onenote-malware-distribution/
# introduction
https://blog.sekoia.io/clickfix-tactic-revenge-of-detection/
https://www.mcafee.com/blogs/other-blogs/mcafee-labs/rising-trend-of-onenote-documents-for-malware-delivery/
https://www.logpoint.com/en/blog/security-analysis/html-smuggling-detection-essentials/
# introduction
# introduction
https://www.cisa.gov/news-events/cybersecurity-advisories/aa23-242a
Direct connection
Anonymization layers
# example: njrat
C2 Active Monitoring - @xanhacks
Technical goal | Adjectives |
---|---|
Collecting fresh IoC (live communication) | Temporality |
IoC without false positives | Quality |
IoC after the compromission | Quantity |
IoC (Indicator Of Compromise): artifact observed on a network (IP address, DNS...) or in an operating system (Hash, Registry key, files...) that, with high confidence, indicates a computer intrusion.
➜ Improve detection & CTI.
# example: njrat
C2 Active Monitoring - @xanhacks
NjRAT Sample
NjRAT Panel (Green Edition - Attacker POV)
# example: njrat
C2 Active Monitoring - @xanhacks
Top 10 on Malware Trends (any.run)
Leaked C&C Panel
# how it works
MWDB
Malware Database
Karton
Configuration extraction
Downloader
Download samples
C2 Active Monitoring - @xanhacks
# how it works
MalwareBazaar & Tria.ge API
VT Enterprise - Live Hunt API
# how it works
Well-known malware databases
# how it works
C2 Active Monitoring - @xanhacks
# how it works
C2 Active Monitoring - @xanhacks
# how it works
C2 Active Monitoring - @xanhacks
New sample
Tasks
Upload config
to MWDB
# how it works
C2 Monitoring API
API & database for C2 & Orders
C2 Connectors
Python scripts to
communicate with C2
C2 Active Monitoring - @xanhacks
C2 Servers
One class for each
malware family
NjratClient
XWormClient
# how it works
C2 Active Monitoring - @xanhacks
# how it works
C2 Active Monitoring - @xanhacks
# example: njrat
C2 Active Monitoring - @xanhacks
NjRAT is a Remote Access Trojan made in .NET that communicates through unencrypted TCP socket
(default port: 5552)
# example: njrat
C2 Active Monitoring - @xanhacks
# example: njrat
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
Timeline
"ill fucking kill your computer"
"im getting your bank information"
"you will be fucking poor"
# results
C2 Active Monitoring - @xanhacks
https://www.youtube.com/watch?v=Xs3ukQql0H0
Wiper #1:
AiVDsDOsA
# results
C2 Active Monitoring - @xanhacks
https://www.youtube.com/watch?v=jK1nRADpVnw
Wiper #2:
Neptunium
# results
C2 Active Monitoring - @xanhacks
Furry lover <3
# results
C2 Active Monitoring - @xanhacks
> "gribojuyy" enter the chat
gribojuyy: Bro, hello, do you have paypal?
me: What are you doing in my computer ?
gribojuyy: do you have a discord?
me: Where are you from ?
gribojuyy: America
gribojuyy: bro do you have telegram
gribojuyy: bro do you have telegram
gribojuyy: bro do you have telegram
gribojuyy: ...
gribojuyy: message me in telegram @gribojuy
Chat exchange on 10/05/2024
At the same time:
# results
C2 Active Monitoring - @xanhacks
# results
C2 Active Monitoring - @xanhacks
# results
# results
# results
C2 Active Monitoring - @xanhacks
Timeline
"You installed a virus that I did not distribute"
"Please install antivirus"
MessageBox: Documentation to remove NjRAT
# results
C2 Active Monitoring - @xanhacks
14min interval
# results
C2 Active Monitoring - @xanhacks
14/04/2024
# results
ME | ATTACKER |
---|---|
How much money do you make in a month ? | |
and you? | |
What are you doing in my computer ? | |
you launched my warrior | |
What do you want ? | |
What is your job? | |
Answer the question and I'll leave | |
What is your job? What is your job? |
# results
ME | ATTACKER |
---|---|
What are you doing in my computer ? | |
send me 100$ and i will get out from your computer | |
Where are you from ? | |
you dont need to know this send me money or i will shut down your computer and you will never get access to | |
Can you hack my girlfriend facebook account ? | |
ok how much you will give me |
# example: njrat
C2 Active Monitoring - @xanhacks
Houdini is a RAT made in Windows Scripting Languages that communicates through HTTP
# example: njrat
Vw0rm
WshRAT
WshRAT v2
LimeWorm
Houdini
VBSBot
# results
# how it works
MWDB
Malware Database
DarkComet
C2 Active Monitoring - @xanhacks
AsyncRAT
Karton
Configuration extraction
InfeXion - Reverse a multi-steps Infection chain
https://github.com/HeroCTF/HeroCTF_v5/tree/main/Reverse/InfeXion_1
AutoInfector - Reverse a Malware & Interact with the C2
https://github.com/HeroCTF/HeroCTF_v6/tree/main/Reverse/AutoInfector_1
MalNET - Reverse a .NET malware
https://app.flag4jobs.com/challenges/malnet
MineCrack & SimpleCase - Forensic cases with malwares
https://app.flag4jobs.com/challenges/minecrack
https://app.flag4jobs.com/challenges/simplecase
Any questions ?
@xanhacks
https://slides.com/xanhacks/c2-active-monitor/