Attacks/Breaches
3/22/2013
11:55 AM
Connect Directly
RSS
E-Mail
50%
50%
Repost This

How TeamSpy Turned Legitimate TeamViewer App Into Cyberespionage Tool

Attackers abused TeamViewer's functionality as part of their effort to go undetected for years

The discovery of the so-called TeamSpy espionage campaign marks yet another example of malware sliding under the radar while pilfering data from sensitive systems. But perhaps the most striking element of the attack is its abuse of a legitimate remote access tool (RAT) to administer infected machines.

TeamSpy is a cyberespionage operation targeting government agencies, businesses, and activists that may stretch back as far as roughly a decade. Many of its victims appear to be from Europe. The crew took advantage of the functionality of the TeamViewer application, which is used for remote control, Web conferencing, desktop sharing, online meetings, and transferring files between computers.

The malware installs a version of TeamViewer on infected systems. The attackers then extend TeamViewer's functionality to provide additional stealth, dynamically patching it in memory to remove indications of its presence.

"This set of TeamSpy attacks is unique for a number of reasons, including the attackers' use of TeamViewer, and then extending TeamViewer functionality on target desktops with a DLL hijacking exploit," explains Kurt Baumgartner, senior security researcher at Kaspersky Lab.

The DLL hijacking occurs courtesy of a module called Avicap32, which contains a PE EXE file written in Assembler. That file is stored in the same folder as TeamViewer.exe, and when TeamViewer is launched it will "show no warning, no popups, no systray icons and will silently continue working providing remote access to the infected machine," Kaspersky Lab notes in a report examining the attacks.

"This module not only disables TeamViewer popups but also extends its functionality to the classical HTTP bot supporting a set of commands," according to the report. "This module installed with Teamviewer 6 allows the attackers to access computer desktop remotely, activate webcam or microphone, download or upload files to the infected machine and many more."

Dr. Boldizsar Bencsath, of Laboratory of Cryptography and Systems Security (CrySyS Lab) at the Budapest University of Telecommunications and Economics, says he is not all that surprised to see a legitimate remote access tool used in this way.

"If hackers attack a Linux server, they also abuse regular Linux tools; for many things they don't have to write malware -- just reconfigure or start them to use," he says. "It is a good trick that they don't write the whole tool, just a part, and [antivirus] companies can't set a signature on TeamViewer itself, just for the small malicious modification, which then can be easily modified if detected.

"Of course, it's not that tricky, not impossible to be detected, but if there is no reason for the user to check, it won't be that easy to see he or she has a problem."

In its analysis of TeamSpy, CrySys Lab observed that TeamViewer had also been leveraged in the "Sheldor" attack campaign, which was detected between 2010 and 2011 and resulted in between $600,000 and $832,000 in assets being stolen. Though there were also similarities in command-and-control traffic between the campaigns, CrySys Lab researchers stopped short of saying the campaigns were connected beyond the tool level.

Once inside a network, targeted attackers may attempt to blend in by using legitimate tools and stolen credentials from the network, Kaspersky's Baumgartner says, but he would not call what happened with TeamViewer "common." The most unique aspect of the attack, he opines, is that an almost decade-long cyberespionage operation relied heavily on a digitally signed, well-known RAT.

TeamViewer spokesperson Magdalena Brzakala said in a statement that the presence of the avicap32.dll is an indication of infection, and that users should patch their systems and run up-to-date antivirus to deal with attacks.

The exact number of victims is not known, but security researchers at CrySys Lab and Kaspersky Lab believe the number is less than 1,000.

"An overall number is hard to arrive at, because the operation ran for almost a decade across multiple command and control servers," according to Baumgartner. "I would say overall, victims ran into the high hundreds, partly because of the inefficiencies of running watering hole schemes."

Have a comment on this story? Please click "Add Your Comment" below. If you'd like to contact Dark Reading's editors directly, send us a message.

Comment  | 
Print  | 
More Insights
Register for Dark Reading Newsletters
White Papers
Cartoon
Current Issue
Video
Slideshows
Twitter Feed
Dark Reading - Bug Report
Bug Report
Enterprise Vulnerabilities
From DHS/US-CERT's National Vulnerability Database
CVE-2012-0360
Published: 2014-04-23
Memory leak in Cisco IOS before 15.1(1)SY, when IKEv2 debugging is enabled, allows remote attackers to cause a denial of service (memory consumption) via crafted packets, aka Bug ID CSCtn22376.

CVE-2012-1317
Published: 2014-04-23
The multicast implementation in Cisco IOS before 15.1(1)SY allows remote attackers to cause a denial of service (Route Processor crash) by sending packets at a high rate, aka Bug ID CSCts37717.

CVE-2012-1366
Published: 2014-04-23
Cisco IOS before 15.1(1)SY on ASR 1000 devices, when Multicast Listener Discovery (MLD) tracking is enabled for IPv6, allows remote attackers to cause a denial of service (device reload) via crafted MLD packets, aka Bug ID CSCtz28544.

CVE-2012-3062
Published: 2014-04-23
Cisco IOS before 15.1(1)SY, when Multicast Listener Discovery (MLD) snooping is enabled, allows remote attackers to cause a denial of service (CPU consumption or device crash) via MLD packets on a network that contains many IPv6 hosts, aka Bug ID CSCtr88193.

CVE-2012-3918
Published: 2014-04-23
Cisco IOS before 15.3(1)T on Cisco 2900 devices, when a VWIC2-2MFT-T1/E1 card is configured for TDM/HDLC mode, allows remote attackers to cause a denial of service (serial-interface outage) via certain Frame Relay traffic, aka Bug ID CSCub13317.

Best of the Web