Darktrace AI Detects Anomalous Behavior in Empty Office
AI uncovered hackers mining cryptocurrency on a biometric server in a deserted office during COVID-19. Learn how Darktrace detected this attack in real-time.
Darktrace cyber analysts are world-class experts in threat intelligence, threat hunting and incident response, and provide 24/7 SOC support to thousands of Darktrace customers around the globe. Inside the SOC is exclusively authored by these experts, providing analysis of cyber incidents and threat trends, based on real-world experience in the field.
Written by
Max Heinemeyer
Global Field CISO
Share
09
Aug 2020
Darktrace recently detected a crypto-mining campaign that used the processing power of a corporate server to mine cryptocurrency at a manufacturing firm based in APAC. This server was in control of biometric door access within the client’s office and first downloaded a suspicious executable before beginning to mine for cryptocurrency. This occurred while the firm’s physical office was closed, with all employees working remotely due to COVID-19.
External-facing servers often face increased risk of compromise due to frequent touchpoints with the internet. It is vital that security teams are made aware of malicious activity on these devices as quickly as possible given their role in managing various business operations. Crypto-mining is difficult for many security tools to detect, particularly due to encrypted communications, and can go undetected on servers for long periods of time, slowing or damaging business operations.
Armed with an understanding of ‘normal’ for this manufacturing firm Darktrace’s AI was able to recognize the anomalous behavior, and the Cyber AI Analyst launched a fully autonomous investigation into the incident.
Figure 1: A timeline of the attack
The first signs of compromise
Darktrace identified an internet-facing server downloading a suspicious executable file, Securitcy.111, from a new external IP that had never been seen on the network before. The server had RDP, SMB, and SQL ports open externally – a successful incoming SQL connection from the external IP was seen shortly before the file download, suggesting a likely source of compromise. Successful RDP and SMB version 1 connections were also seen around the time of this activity.
Following this file download, the server began to repeatedly connect to external endpoints using self-signed TLS certificates. These endpoints are associated with mining pools for the digital currency Monero.
Darktrace’s detection
Despite a lack of threat intelligence on the external source of the file download, Darktrace’s AI easily detected that this behavior was highly unusual, alerting the firm to the serious emerging incident and enabling the customer to quickly take action. Instead of relying on known IoCs, the crypto-mining connections were immediately identified by Darktrace as suspicious due to their use of self-signed TLS certificates, alongside the statistical rarity of the endpoints for the business.
The new user agent was generic, and commonly associated with legitimate and malicious processes alike. This use of user agents means that C2 communication is less likely to be detected by the traditional security stack, however its unusual use was immediately flagged by Darktrace as suspicious.
AI Analyst coverage
Darktrace’s Cyber AI Analyst investigated this crypto-mining incident, providing an immediate indication that the device had been compromised.
Figure 2: Screenshot of AI Analyst detection of the crypto-mining
The below image shows the infected device over the same five-day period, with model breaches represented by dots and color indicating severity. The clear increase in model breaches on the device during this activity is a clear indication of compromise.
Figure 3: A graph showing a large increase in models breached by the device on 3 June
Figure 4: A sample of models breached by the server at the time of this compromise
As thousands of organizations moved to remote working this year – with the questions of when, how, and whether to return still unanswered – it is critical to ensure that physical IT infrastructure within offices remains secure. Internet-facing servers in particular must be able to withstand a multitude of external threats. This incident demonstrates the importance of security tools that can not only detect known IoCs, but emerging and unknown incidents.
Darktrace’s AI-powered approach was able to immediately detect the suspicious behavior and identify the compromise. Thanks to Darktrace’s quick detection, and the investigation of the Cyber AI Analyst, the client could remediate the crypto-mining infection.
Thanks to Darktrace analyst Emma Foulger for her insights on the above threat find.
Darktrace cyber analysts are world-class experts in threat intelligence, threat hunting and incident response, and provide 24/7 SOC support to thousands of Darktrace customers around the globe. Inside the SOC is exclusively authored by these experts, providing analysis of cyber incidents and threat trends, based on real-world experience in the field.
Why attack-centric approaches to email security can’t cope with modern threats
What’s the problem with an attack-centric mindset?
For decades, traditional email security strategies have been built around an attack-centric mindset. Secure Email Gateways (SEGs) and other legacy solutions operate on the principle of identifying and blocking known threats. These systems rely heavily on predefined threat intelligence – blacklists, malware signatures, and reputation-based analysis – to filter out malicious content before it reaches the inbox.
While this approach was sufficient when email threats were relatively static and signature-based, it’s increasingly ineffective against the sophistication of modern attacks. Techniques like spear phishing, business email compromise (BEC), and supply chain attacks often bypass traditional SEG defenses because they lack obvious malicious indicators. Instead, they leverage social engineering, look-alike domains, and finely tuned spoofing tactics that are designed to evade detection.
The challenge extends beyond just legacy SEGs. Many modern email security providers have inherited the same attack-centric principles, even if they've reimagined the technology stack. While some vendors have shifted to API-based deployments and incorporated AI to automate pattern recognition, the underlying approach remains the same: hunting for threats based on known indicators. This methodology, though it’s undergone modernization using AI, still leaves gaps when it comes to novel, hyper-targeted threats that manipulate user behavior rather than deploy predictable malicious signatures. Attack-centric security will always remain one step behind the attacker.
By the way, native email security already covers the basics
One of the most overlooked realities in email security is that native solutions like Microsoft 365’s built-in security already handle much of the foundational work of attack-centric protection. Through advanced threat intelligence, anti-phishing measures, and malware detection, Microsoft 365 actively scans incoming emails for known threats, using global telemetry to identify patterns and block suspicious content before it even reaches the user’s inbox.
This means that for many organizations, a baseline level of protection against more obvious, signature-based attacks is already in place – but many are still disabling these protections in favour of another attack-centric solution. By layering another attack-centric solution on top, they are effectively duplicating efforts without enhancing their security posture. This overlap can lead to unnecessary complexity, higher costs, and a false sense of enhanced protection when in reality, it’s more of the same.
Rather than duplicating attack-centric protections, the real opportunity lies in addressing the gaps that remain: the threats that are specifically crafted to evade traditional detection methods. This is where a business-centric approach becomes indispensable, complementing the foundational security that’s already built into your infrastructure.
Introducing… the business-centric approach
To effectively defend against advanced threats, organizations need to adopt a business-centric approach to email security. Unlike attack-centric models that hunt for known threats, business-centric security focuses on understanding the typical behaviors, relationships, and communication patterns within your organization. Rather than solely reacting to threats as they are identified, this model continuously learns what “normal” looks like for each user and each inbox.
By establishing a baseline of expected behaviors, business-centric solutions can rapidly detect anomalies that suggest compromise, such as sudden changes in sending patterns, unusual login locations, or subtle shifts in communication tone. This proactive detection method is especially powerful against spear phishing, business email compromise (BEC), and supply chain attacks that are engineered to bypass static defenses. This approach also scales with your organization, learning and adapting as new users are onboarded, communication patterns evolve, and external partners are added.
In an era where AI-driven threats are becoming the norm, having email security that knows your users and inboxes better than the attacker does is a critical advantage.
Why native + business-centric email security is the winning formula
By pairing native security with a business-centric model, organizations can cover the full spectrum of threats – from signature-based malware to sophisticated, socially engineered attacks. Microsoft 365’s in-built security manages the foundational risks, while business-centric defense identifies subtle anomalies and targeted threats that legacy approaches miss.
Layering Darktrace on top of your native Microsoft security eliminates duplicate capabilities, costs and workflows without reducing functionality
Rather than layering redundant attack-centric solutions on top of existing protections, the future of email security lies in leveraging what’s already in place and building on it with smarter, behavior-based detection. The Swiss Cheese Model is a useful one to refer to here: by acknowledging that no single defense can offer complete protection, layering defenses that plug each other’s gaps – like slices of Swiss cheese – becomes critical.
This combination also allows security teams to focus their efforts more effectively. With native solutions catching broad-based, known threats, the business-centric layer can prioritize real anomalies, minimizing false positives and accelerating response times. Organizations benefit from reduced overlap, streamlined costs, and a stronger overall security posture.
Download the full guide to take the first step towards achieving your next-generation security stack.
Darktrace researchers have identified a custom Go-based Linux botnet named “PumaBot” targeting embedded Linux Internet of Things (IoT) devices. Rather than scanning the Internet, the malware retrieves a list of targets from a command-and-control (C2) server and attempts to brute-force SSH credentials. Upon gaining access, it receives remote commands and establishes persistence using system service files. This blog post provides a breakdown of its key functionalities, and explores binaries related to the campaign.
Technical Analysis
Filename: jierui
md5: cab6f908f4dedcdaedcdd07fdc0a8e38
The Go-based botnet gains initial access through brute-forcing SSH credentials across a list of harvested IP addresses. Once it identifies a valid credential pair, it logs in, deploys itself, and begins its replication process.
Figure 1: Overview of Jierui functions.
The domain associated with the C2 server did not resolve to an IP address at the time of analysis. The following details are a result of static analysis of the malware.
The malware begins by retrieving a list of IP addresses of likely devices with open SSH ports from the C2 server (ssh.ddos-cc[.]org) via the getIPs() function. It then performs brute-force login attempts on port 22 using credential pairs also obtained from the C2 through the readLinesFromURL(), brute(), and trySSHLogin() functions.
Within trySSHLogin(), the malware performs several environment fingerprinting checks. These are used to avoid honeypots and unsuitable execution environments, such as restricted shells. Notably, the malware checks for the presence of the string “Pumatronix”, a manufacturer of surveillance and traffic camera systems, suggesting potential IoT targeting or an effort to evade specific devices [1].
Figure 2: Fingerprinting of “Pumatronix”.
If the environment passes these checks, the malware executes uname -a to collect basic system information, including the OS name, kernel version, and architecture. This data, along with the victim's IP address, port, username, and password, is then reported back to the C2 in a JSON payload.
Of note, the bot uses X-API-KEY: jieruidashabi, within a custom header when it communicates with the C2 server over HTTP.
The malware writes itself to /lib/redis, attempting to disguise itself as a legitimate Redis system file. It then creates a persistent systemd service in /etc/systemd/system, named either redis.service or mysqI.service (note the spelling of mysql with a capital I) depending on what has been hardcoded into the malware. This allows the malware to persist across reboots while appearing benign.
[Unit] Description=redis Server Service
[Service] Type=simple Restart=always RestartSec=1 User=root ExecStart=/lib/redis e
[Install] WantedBy=multi-user.target
In addition to gaining persistence with a systemd service, the malware also adds its own SSH keys into the users’ authorized_keys file. This ensures that access can be maintained, even if the service is removed.
A function named cleankill() contains an infinite loop that repeatedly attempts to execute the commands “xmrig” and “networkxm”. These are launched without full paths, relying on the system's PATH variable suggesting that the binaries may be downloaded or unpacked elsewhere on the system. The use of “time.Sleep” between attempts indicates this loop is designed to ensure persistence and possibly restart mining components if they are killed or missing.
During analysis of the botnet, Darktrace discovered related binaries that appear to be part of a wider campaign targeting Linux systems.
Ddaemon is a Go-based backdoor. The malware begins by parsing command line arguments and if conditions are met, enters a loop where it periodically verifies the MD5 hash of the binary. If the check fails or an update is available, it downloads a new version from a C2 server (db.17kp[.]xyz/getDdaemonMd5), verifies it and replaces the existing binary with a file of the same name and similar functionality (8b37d3a479d1921580981f325f13780c).
The malware uses main_downloadNetwork() to retrieve the binary “networkxm” into /usr/src/bao/networkxm. Additionally, the bash script “installx.sh” is also retrieved from the C2 and executed. The binary ensures persistence by writing a custom systemd service unit that auto starts on boot and executes ddaemon.
The networkxm binary functions as an SSH brute-force tool, similar to the botnet. First it checks its own integrity using MD5 hashes and contacts the C2 server (db.17kp[.]xyz) to compare its hash with the latest version. If an update is found, it downloads and replaces itself.
Figure 3: Part of networkxm checking MD5 hash.
Figure 4: MD5 hash
After verifying its validity, it enters an infinite loop where it fetches a password list from the C2 (/getPassword), then attempts SSH connections across a list of target IPs from the /getIP endpoint. As with the other observed binaries, a systemd service is created if it doesn’t already exist for persistence in /etc/systemd/system/networkxm.service.
Figure 5: Bash script installx.sh.
Installx.sh is a simple bash script used to retrieve the script “jc.sh” from 1.lusyn[.]xyz, set permissions, execute and clear bash history.
Figure 6: Snippet of bash script jc.sh.
The script jc.sh starts by detecting the operating system type Debian-based or Red Hat-based and determines the location of the pam_unix.so file. Linux Pluggable Authentication Modules (PAM) is a framework that allows for flexible and centralized user authentication on Linux systems. PAM allows system administrators to configure how users are authenticated for services like login, SSH, or sudo by plugging in various authentication modules.
Jc.sh then attempts to fetch the current version of PAM installed on the system and formats that version to construct a URL. Using either curl or wget, the script downloads a replacement pam_unix.so file from a remote server and replaces the existing one, after disabling file immutability and backing up the original.
The script also downloads and executes an additional binary named “1” from the same remote server. Security settings are modified including enabling PAM in the SSH configuration and disabling SELinux enforcement, before restarting the SSH service. Finally, the script removes itself from the system.
Based on the PAM version that is retrieved from the bash query, the new malicious PAM replaces the existing PAM file. In this instance, pam_unix.so_v131 was retrieved from the server based on version 1.3.1. The purpose of this binary is to act as a rootkit that steals credentials by intercepting successful logins. Login data can include all accounts authenticated by PAM, local and remote (SSH). The malware retrieves the logged in user, the password and verifies that the password is valid. The details are stored in a file “con.txt” in /usr/bin/.
Figure 7: Function storing logins to con.txt
Filename: 1
md5: cb4011921894195bcffcdf4edce97135
In addition to the malicious PAM file, a binary named “1” is also retrieved from the server http://dasfsdfsdfsdfasfgbczxxc[.]lusyn[.]xyz/jc/1. The binary “1” is used as a watcher for the malicious PAM file using inotify to monitor for “con.txt” being written or moved to /usr/bin/.
Following the daemonize() function, the binary is run daemonized ensuring it runs silently in the background. The function read_and_send_files() is called which reads the contents of “/usr/bin/con.txt”, queries the system IP with ifconfig.me, queries SSH ports and sends the data to the remote C2 (http://dasfsdfsdfsdfasfgbczxxc[.]lusyn[.]xyz/api/).
Figure 8: Command querying SSH ports.
For persistence, a systemd service (my_daemon.service) is created to autostart the binary and ensure it restarts if the service has been terminated. Finally, con.txt is deleted, presumably to remove traces of the malware.
Conclusion
The botnet represents a persistent Go-based SSH threat that leverages automation, credential brute-forcing, and native Linux tools to gain and maintain control over compromised systems. By mimicking legitimate binaries (e.g., Redis), abusing systemd for persistence, and embedding fingerprinting logic to avoid detection in honeypots or restricted environments, it demonstrates an intent to evade defenses.
While it does not appear to propagate automatically like a traditional worm, it does maintain worm-like behavior by brute-forcing targets, suggesting a semi-automated botnet campaign focused on device compromise and long-term access.
Recommendations
Monitor for anomalous SSH login activity, especially failed login attempts across a wide IP range, which may indicate brute-force attempts.
Audit systemd services regularly. Look for suspicious entries in /etc/systemd/system/ (e.g., misspelled or duplicate services like mysqI.service) and binaries placed in non-standard locations such as /lib/redis.
Inspect authorized_keys files across user accounts for unknown SSH keys that may enable unauthorized access.
Filter or alert on outbound HTTP requests with non-standard headers, such as X-API-KEY: jieruidashabi, which may indicate botnet C2 communication.
Apply strict firewall rules to limit SSH exposure rather than exposing port 22 to the internet.