Matthew Profile picture
Jul 11, 2023 14 tweets 8 min read Read on X
Safely investigating a ransomware hosting site using Censys and GrabbrApp 😄

I'll show how to confirm that a "clean" IP was hosting ransomware. You'll also get to see some cool hunting queries and methods for safely downloading malware files.

Thread 👇
[1/12]

#Censys #malware





[2/] I started with some @censysio queries that I've previously published on my site.



The query in this case was looking for #powershell scripts contained in #python based open directories. https://t.co/cMwbV3YGShembee-research.ghost.io/shodan-censys-…
[2.1] A direct link to the censys search

search.censys.io/search?resourc…
[3/] This query returned 26 results. One of which was based out of Shanghai, China.

180.166.220[.]180

This IP had 0 VT detections as of 11/07/23.

As well as a highly suspicious open directory containing "darkside.bin" and "shell.ps1"

https://t.co/4GlRK6zOrbvirustotal.com/gui/ip-address…


[4/] The "Darkside.bin" file was interesting and I wanted to obtain a sample.

Typically I would do this with #Powershell (iwr) and a method I've demonstrated on my blog.

Today I'll show a safer and "cleaner" method using @GrabbrAppIO .

(Blog) https://t.co/G5dzsgNhkAembee-research.ghost.io/smokeloader-an…


[5/] My previous powershell method works ok, but it requires interaction with the IP and a "safe" VM/VPN which is not always available.

So I decided to try @GrabbrAppIO by @valhalla_dev.

This tool was designed for the exact purpose of safely retrieving suspicious files.
[6/] I signed up for GrabbrApp (there's a free option) and input the complete url for "darkside.bin".

You can try that here.
https://t.co/ep9iK8MowLgrabbrapp.io
[7/] GrabbrApp was able to retrieve the file and presented both a hash and link for safe download.

Checking the SHA256 hash in Virustotal immediately confirmed Darkside ransomware.

(No need to directly interact with the IP or ransomware file)

https://t.co/j7BDr20IvNvirustotal.com/gui/file/151fb…


[8/] There were numerous other files contained in the same open directory.

I was able to safely obtain the remaining files using the same method detailed above.



[9/] There were some cases where the hash was not available on #Virustotal and a manual download was required to investigate.

I was able to do this using GrabbrApp which also has the ability to save a suspicious file.

[10] I'll leave the analysis there as I just wanted to show the tool.

There are likely dozens more files across the remaining 25 results in the @censysio search. As well as the searches in the blog post.

I hope people have some fun and see what they can find😁
[11] I've been following @valhalla_dev for a while now and I genuinely think GrabbrApp is a product that I will personally be using.

I can see this saving me a lot of time and effort when doing personal research, particularly malware downloaders and confirming Censys queries.
[12/] There are likely other use cases I haven't encountered yet, and I'll try and share some more as I learn.

For now, here's some links to the queries and tools used.

GrabbrApp:

Queries: https://t.co/t67NIUPWWT

Cont'd....grabbrapp.io
embee-research.ghost.io/shodan-censys-…
[12.1/12]

Censys Search:

VT: https://t.co/zzTrScDmRvsearch.censys.io/search?resourc…
virustotal.com/gui/ip-address…

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Matthew

Matthew Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @embee_research

May 28, 2024
Three Simple Methods For Analysing Malicious Documents

A quick overview of olevba, Microsoft Word, and Procmon for analysing malware documents and extracting embedded macro content.

[1/10] 🧵

#malware #maldocs


Image
Image
Image
Image
2/ You first need to obtain a maldoc.

For this analysis we'll be using a malicious document related to #MuddyWater. Which was initially shared in a post by @suyog41.

bazaar.abuse.ch/sample/d2809e3…
3/ Obtaining Macros With Olevba

The most simple method for maldoc analysis is to use the olevba tool provided with FlareVM.

This tool will automatically extract macro content and highlight any relevant IOC's. All in one short and simple command.

github.com/decalage2/olet…

Image
Image
Read 9 tweets
May 21, 2024
🚩Malware Analysis - Decoding a Latrodectus Loader Script

➡️Let's look at a recent Latrodectus loader that uses junk comments to confuse analysis and hide malicious code.

[1/11] 🧵
#malware #cyberchef


Image
Image
Image
Image
2/ Obtaining The Sample

The initial script can be found on Malware Bazaar with SHA256: 71fb25cc4c05ce9dd94614ed781d85a50dccf69042521abc6782d48df85e6de9
3/ Opening the script in a text editor reveals a large number of junk comments.

In-between comments, are occasional lines of "real" code which make up the malware functionality.

Your first step is to remove the junk comments so that you can focus on the "real" code.
Image
Image
Read 11 tweets
Mar 24, 2024
Malware Deobfuscation With DnSpy and CyberChef 👨‍🍳

Let's look at some beginner tips for identifying encrypted data with DnSpy.

We'll then utilise CyberChef to recreate the decryption and obtain the address of the C2 server.

[1/12] 🧵

#malware #cyberchef
Image
Image
[2/] Finding encrypted strings

Config values are often initialised (and decrypted) early in execution. Hence the Entry Point is a great place to begin looking.

(In Dnspy, we can select a loaded file and use "Go To Entry Point")

Image
Image
Image
3/ Identifying Config Values

After locating the entry point, we can begin looking for signs of encrypted or obfuscated values.

The first method "Run" contains suspicious references to “”, as well as Arguments.IP and Arguments.Key StringDecrypt.Read
Image
Read 13 tweets
Jan 2, 2024
🔥Lumma Stealer - Manually Unpacking and Extracting C2's 🔥

Let's analyse a Lumma malware sample and manually unpack it with Dnspy and x32dbg.

We'll then leverage Ghidra and x32dbg to locate and decrypt four C2 addresses.

[1/24] 🖊️

#Malwareanalysis #Ghidra


Image
Image
Image
Image
1/ The initial sample can be found on Malware Bazaar

You can download it here if you'd like to follow along

bazaar.abuse.ch/sample/0ee580f…
2/ Checking What Were Up Against

Prior to manual analysis, we can submit the hash on @unpacme. This gives us an idea of how many "layers" of packing are present.

The initial sample is .NET based, but the payload is not. (This means we'll need both Dnspy and #Ghidra)
Image
Image
Read 25 tweets
Dec 30, 2023
How to Increase Your Engagement on Cyber-related Twitter Content ✏️

Tips and tricks learnt from writing about #malware on Twitter for 18 months😄

[1/9]
1/ Optimal Post Structure

Statement -> Explanation -> Conclusion

I've found this general flow is the easiest to create and for readers to follow. It follows the 1-2-1 structure by @Nicolascole77

If you don't yet have a post style/structure, this is a great place to start. Image
2/ Aim for Reposts Over Followers

The highest engagement posts are those that get reshared by large accounts.

You don't need a lot of followers for high engagement, as long as you can get reposted by someone who does. Image
Read 10 tweets
Dec 21, 2023
🔬Defeating Obfuscated .HTA Scripts to Obtain Cobalt Strike Shellcode 🔬

Let's look at Cyberchef, Manual Deobfuscation, Multi-stage script analysis and finally emulation to obtain a decoded C2.

[1/17]


Image
Image
Image
Image
2/ The analysis begins with obfuscated .hta script obtained from Malware Bazaar.

You can obtain the file here if you want to follow along.

bazaar.abuse.ch/sample/2c683d1…
3/ Initial Script Review.

The initial script contains multiple obfuscated strings, a partial powershell command, and a large blob of base64 text.
Image
Image
Read 17 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(