Stephan Berger Profile picture
Aug 8 19 tweets 7 min read
1/ Playing around with #manjusaka, as reported by @TalosSecurity [1].

Following are some insights and potential #ThreatHuning tips and ideas. 🧵

#CyberSecurity @b3ard3dav3ng3r
2/ After starting the ELF binary (a reduced version is publicly available on GitHub [2]), the login credentials are printed out (username: manjusaka, PW: b3e..), and the port (3200) on which the panel is accessible.
3/ The password is different for each instance of manjusaka.

This mechanism prevents the use of default passwords in case scanners would find the login panel.
4/ However, if the IP address from the panel is visited without specifying the port, the instance automatically redirects to microsoft.com - another protection against automated scanner.
5/ But beware, it's trivial to change these default values via command line parameters on startup.
6/ After logging in to the panel, we can create a new project.
7/ The implants of the different projects uses a different URL to connect to the C2 server.

The routing ID "c15.." is used within the URL from the GET request. The pooling frequency is super high - in the free version the latency cannot be adjusted.
8/ The URL "/general/favicon.png" was mentioned in the Talos blog [1], but this URL (/general/) is only used if no project is defined.
9/ We can create implants for Windows and Linux.

The encryption key does not matter in this version because an implant with an encryption key and one without one have identical hash sums.
10/ Whereby already various AV manufacturers recognize the implant from this version.
11/ In the screenshot below, two systems have reported to our C2 instance (a Windows and a Linux machine).

Only one infected host can be selected at a time in the workbench because the selection unlocks further possibilities to interact with the infected machine.
12/ After selecting an infected host, among other things, a live terminal can be opened. Direct commands can be issued on the host via this terminal.

Limitedly, the shell also works for Windows systems, but passget did not work on either platform.
13/ The file browser works on Windows as it does on Linux.
14/ We can also upload files directly to the infected machines.

The freely available version of manjusaka has no persistence mechanism (neither on Win nor on Linux), but with the upload functionality, we could load a binary to the different startup locations.
15/ manjusaka creates a SQLite database named nps.db at the first startup:

$ file nps.db
nps.db: SQLite 3.x database, last written using SQLite version 3036000
16/ This database contains information about the infected hosts and could be interesting to evaluate after the seizure of a C2 instance by LEA.
17/ Last but not least, the Shodan favicon search from the panel currently returns no hits (http.favicon.hash:cbfb102cebf1f72f195697293f138128).
18/ As Talos mentions in the blog post, this freely available version is probably only a teaser of the original software but already potent enough to perform actual attacks.

• • •

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

Keep Current with Stephan Berger

Stephan Berger 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 @malmoeb

Aug 6
1/ #ThreatHunting for #AsyncRAT

We have various ways to find infected hosts with AsyncRAT:

1⃣ Usage of standard C2 ports
2⃣Hunting for persistence
3⃣Mutexes FTW
4⃣Last but not least, hunting for dropped DLLs

Let's go 🤠🧵

#CyberSecurity
2/ AsyncRAT is a popular Trojan executed at the end of an infection chain on target computers.

@hpsecurity ([2],[3]) and @Trellix ([4]) have both reported in recent reports that TAs have been deploying AsyncRAT.
3/ Since the source code of AsyncRAT is publicly available [1], we can obtain a copy to investigate and build detection capabilities for this RAT.
Read 25 tweets
Aug 1
1/ @ZephrFish and @myexploit2600 presented "Paving The Way To DA" at this year's @Steel_Con.

A few thoughts on the topics mentioned in the talk 🧵:

1⃣MFA, Password Spraying, Common Passwords
2⃣RDP Shadowing
3⃣MFA spamming
4⃣Password in Shares
5⃣GPP
6⃣Sam the admin
2/ 1⃣ A popular initial vector they often use is Citrix without MFA.

This is also a classic from our IR cases, where either the password was found out with password spraying (the user used a weak password), or the user was phished beforehand.
3/ MFA is a MUST for any remote access.

If Azure AD is used, Azure Active Directory Password Protection could be used, which checks the password from the user against a global blocklist or a configurable blocklist [2] (this is done when the user changes the password).
Read 15 tweets
Jul 27
1/ We analyzed a breached server and found the IP address and domain from which the TA downloaded additional tools onto the server.

The initial breach happened a few months ago, but the TA uses the same server till today. 🧵
2/ Because of an open-dir, we can see various tools and scripts placed (and replaced over time) on the server by the TA.

Following are some takeaways from the analysis of the arsenal of the TA:
3/ One hosted tool on the server is KrbRelayUp.exe (717fccf1e6081d012f06d24872563529), a compiled version from the GitHub repo of the same name. [1]

The binary is quite well known at VT with 38 AV detections [2], but that doesn't seem to bother the TA as there are also various
Read 18 tweets
Jul 25
1/ In one ransomware case, the attackers started an EXE file that dropped the vulnerable GIGABYTE driver to C:\Windows\System\gdrv.sys.

The TA used the vulnerable driver to load a malicious driver as a kernel driver, who hunted and killed Symantec processes. 🧵

#CyberSecurity
2/ The same procedure was described in detail by @SophosLabs before [1]:
3/ "64-bit Windows computers have a mechanism called driver signature enforcement which means that Windows only allows drivers to be loaded that has been properly signed by both the manufacturer and Microsoft.
Read 20 tweets
Jul 22
1/ "PDQ Deploy is a software deployment tool that allows system administrators to silently install almost any application or patch to multiple Windows computers simultaneously." [1]

We have investigated a ransomware case where the TA used PDQ to carry out the encryption. 🧵
2/ I guess we are late to the party 😂

@SecurityAura has already handled various cases involving PDQ Deploy in November 2021:
3/ PDQ Deploy comes with different license models, but with the free license, simple packages can be deployed, and the attacker can conveniently select the targets for deployment, including the entire AD.
Read 15 tweets
Jul 22
1/ Although Windows logs the creation of new services in the SYSTEM event log (Event ID 7045 - New Service was installed), attackers often delete these logs.

But we can use the Windows Firewall event logs for #ThreatHunting new installations (of backdoors) 🧵

#CyberSecurity
2/ The screenshot above shows the 2004 Event ID (the creation of a new firewall rule).

The screenshot is from an actual case where the attacker installed Splashtop as a backdoor (among others) to get back into the network.
3/ Using @velocidex Velociraptor and the EvtxHunter Hunt, we can conveniently collect these event logs on all clients and servers in the network.
Read 6 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 on Twitter!

:(