In 2022, remote access tools continue to provide versatile support to organizations. By controlling devices remotely from across the globe, IT teams save on response costs, travel times, and can receive remote support from external parties like contractors [1 & 2]. This is particularly relevant in cases involving specialty machines such as OT/ICS systems where physical access is sometimes limited. These tools, however, come with their own risks. The following blog will discuss these risks and how they can be addressed (particularly in OT environments) by looking at two exploit examples from the popular sphere and within the Darktrace customer base.
One of the most popular remote tools is TeamViewer, a comprehensive videoconferencing and remote management tool which can be used on both desktop and handheld devices. Like other sophisticated tools, when it works as intended, it can seem like magic. However, remote access tools can be exploited and may grant privileged network access to potential threat actors. Although TeamViewer needs to be installed on both perpetrator and victim devices, if an attacker has access to a misconfigured TeamViewer device, it becomes trivial to establish a foothold and deploy malware.
In early 2021, remote access tooling was seen on a new scale against the City of Oldsmar’s water treatment plant  (Figure 1). Oldsmar manages chemical concentration levels in the water for a 15,000-person city. The water treatment plant had been using TeamViewer to allow employees to share screens and work through IT issues. However, in February an employee noticed he had lost control of his mouse cursor. Initially he was unconcerned; the employee assumed that the cursor was being controlled by his boss, who regularly connected to the computer to monitor the facility’s systems. A few hours later though, the employee again saw his cursor moving out of his control and this time noticed that it was attempting to change levels of sodium hydroxide in the water supply (which is extremely dangerous for human consumption). Thankfully, the employee was able to quickly spot the changes and return them to their normal level. When looking back at the event, the key question posed by officials was where exactly the vulnerability was located in their security stack. . The answer was unclear.
When attackers get initial network access, the primary challenge for any enterprise is identifying a) that a device compromise has happened and b) how it happened. These were the same challenges seen in the Oldsmar attack. When the first physical signs of compromise occurred (cursor movement), the impacted user was still unsure whether the activity was malicious. A detailed investigation from Dragos revealed the how: evidence of a watering hole, reconnaissance activity a month prior, a targeted variant of the Tofsee botnet, and the potential presence of two separate threat actors [6 & 7]. The answer to both questions pointed to a complex attack. However, with Darktrace these questions become less important.
Darktrace DETECT does not rely on signatures but instead has AI-based models for live detection of these tools and anomalies within the wider network. Regardless of the security ‘hole’, live detection gives security teams the potential to respond in near-live time.
According to Darktrace’s Chief Product Officer, Max Heinemeyer, the Oldsmar attack was possible because it “Abused off-the-shelf tools that were already used by the client, specifically TeamViewer. This tactic, which targeted the domain controller as the initial vector, made the malware deployment easy and effective.” .
Darktrace has multiple DETECT models to provide visibility over anomalous TeamViewer or remote access tool usage:
· Compliance / Incoming Remote Access Tool
· Compliance / Remote Management Tool On Client
· Compliance / Remote Management Tool On Server
· Device / Activity Identifier / Teamviewer
General incoming privileged connections:
· Compliance / Incoming Remote Desktop
· Compliance / Incoming SSH
Industrial DETECT can also highlight any new or unusual changes in ICS/OT systems:
· ICS / Incoming ICS Command
· ICS / Incoming RDP And ICS Commands
· ICS / Uncommon ICS Error
Darktrace gives security teams the opportunity for a proactive response, and it is up to those teams to utilize that opportunity. In recent months our SOC Team have also seen remote access controls being abused for high-profile threats. In one example, Darktrace detected a ransomware attack supported by the installation of AnyDesk.
In May a company’s mail server was detected making multiple external requests for an unusual file ‘106.exe’ using a PowerShell agent (6b79549200af33bf0322164f8a4d56a0fa08a5a62ab6a5c93a6eeef2065430ce). Although some requests were directed to sinkholes, many were otherwise successful. Subsequently a DDL file with hash f126ce9014ee87de92e734c509e1b5ab71ffb2d5a8b27171da111f96f3ba0e75 (marked by VirusTotal as malicious) was downloaded. This was followed by the installation of AnyDesk: a remote access tool likely deployed for backdoor purposes during further compromises. It is clear the threat actor then moved on to reconnaissance, with new Mimikatz use and a large volume of ICMP and SMBv.1 scanning sessions using a default credential. DCE-RPC calls were also made to the Netlogon service, suggesting a possible attempt to exploit 2020’s Zerologon vulnerability (CVE-2020-1472) . When the customer then discovered a ransom note pertaining to LV (repurposed REvil), Darktrace analysts helped them to re-configure Darktrace RESPOND and turn it to active rather than human confirmation mode (Figure 2).
Whilst in this instance the tool was not used for initial access, it was still an important contingency tool to ensure the threat actor’s persistency as the customer tried to respond to the ongoing breach. Yet it was the visibility provided by Darktrace model detection and changes to RESPOND configuration which ensured the customer kept up with this actor and reduced the impact of the attack.
Looking back at Oldsmar, it is clear that being aware of remote access tools is only half the battle. More importantly, most organizations are asking if their use in attacks can be prevented in the first place. As an off-the-shelf tool, restricting TeamViewer use seems like an easy solution but such tools are often essential for maintenance and support operations. Even if limited to privileged users, these accounts are also subject to potential compromise. Instead, companies can take a large-scale view and consider the environment in which the Oldsmar attack occurred.
In this context, the separation of OT and IT systems is a potential solution - if attackers cannot access at-risk systems, then they also cannot attack those systems. However, with recent discourse around the IT-OT convergence and increased use of IOT devices, this separation is increasingly challenging to implement . Complex networking designs, stringent patching requirements and ever-changing business/operational needs are all big considerations when establishing industrial security. In fact, Tenable’s CEO Amit Yoran encouraged less separation following Oldsmar: “There’s business reasons and efficiency reasons that you might want to connect those to be able to predict when parts are going to fail or when outages are going to occur [sic].” .
When neither addressing remote access use or industrial set-up provides a quick solution, then security teams need to look to third-party support to stop similar attacks. In addition to Darktrace DETECT, our Darktrace PREVENT range with PREVENT/Attack Surface Management (ASM) can also alert security teams to internet-facing devices at risk of remote access exploitation. ASM actively queries the Shodan API for open ports on company websites and exposed servers. This highlights those assets which might be vulnerable to this type of remote access.
In conclusion, TeamViewer and other remote access tools offer a lot of convenience for security teams but also for attackers. Attackers can remotely access important systems including those in the industrial network and install malware using remote access tools as leverage. Security teams need to know both their normal authorized activities and how to enforce them. With Darktrace DETECT, the tools are given transparency, with Darktrace RESPOND they can be blocked, and now Darktrace PREVENT/ASM helps to mitigate the risk of attack before it happens. As the professional world continues to embrace hybrid working, it becomes increasingly crucial to embrace these types of products and ensure protection against the dangers of unwanted remote access.
Thanks to Connor Mooney for his contributions to this blog.