TrustDefender Labs

Technical Updates from the TrustDefender Labs

I can’t believe that we haven’t blogged about Zeus/Wsnpoem, as it is one of the more common trojans that targets media and social networking websites especially financial institutions worldwide since more than 3 years now. However we are seeing the technology improving throughout this period. It steals user private and confidential information (form grabber), can inject arbitrary HTML code into any website (also encrypted websites), can steal certificates and will take screenshots to defeat virtual keyboards especially those virtual keyboards commonly used by financial institutions still today.

In addition to its business features, Zeus/Wsnpoem continues to be enhanced and is  one of the most advanced trojans from a technical point of view as well. The most important reasons are:

  • incredibly hard to detect once a system is infected (see below)
  • easy to use backend system provided
  • easy to configure by simple (but encrypted) configuration files.

So let’s have a detailed look what this trojan is doing.

Overview

Quite often, and simply a Zeus trojan is delivered via a Spam email (e.g. UPS Invoice) and once the dropper is executed, it will inject its self into key windows components. This means that the trojan will not be visible at all (e.g. in task manager), and all internet communication is performed by the “authentic” processes. This way the trojan can invade any firewall as well.

It will install its self (ntos.exe) into the Registry (HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon\UserInit to make sure it will be started every time Windows starts. The initial ntos.exe process will inject its self into winlogon.exe (a core windows process) and will spread from there into every single process. The files on the harddrive are protected with rootkit features so they are not visible in the Windows Explorer. Altogether, it’s incredibly hard even for security professionals to detect whether the system is compromized!!!

A very detailed, very technical and very interesting study of one of the early variants of this trojan by Lance James and Michael Ligh can be found here: http://www.securescience.net/FILES/securescience/10378/pubMalwareCaseStudy.pdf. Even though this study is from 2006, most of the technical details are still valid and the paper is still current. As you would expect though, we have seen quite a bit of technical improvement.

Technical Details

The sample we looked at was MD5=8f5668c69fb4924ba15313dcf87f4d42 and according to Virustotal only 5 out of 38 detect this dropper. (http://www.virustotal.com/analisis/45625ba20a8d6e4c79cd10658efa9da8). Unfortunately we see this with almost all sophisticated trojans. The detection for new threats is way too low.

As discussed before, the trojan is neither visible as a user process nor as a system driver

all-good1

The only way to detect this trojan is to look at hooked system functions:

hooks

Our sample targeted 279 financial institutions, including 36 financial institutions in Australia (First, econd and third tier), including 3 of the four major Australian suppliers of banking backend services to mostly second and third tier financial institutions.

For a full list, please contact us at info@trustdefender.com

A normal user will not notice anything suspicious when he is doing an internet banking session. The trojan will do all its work in the background and our sample was very well written and we did not experience a single crash and could not notice any slowdown of the system at all! The Trojan would then send the captured information to the C&C server where this information is typically onsold. So the fraudsters who compromize the accounts are in most cases not identical with the fraudsters who steal your money! A fact that make life for Law Enforcement around the world very tricky.

How TrustDefender protects the user

TrustDefender will ‘detect’ and ‘successfully protect’ the user from any known Zeus/wsnpoem/zbot infection as TrustDefender will detect the system file hooking and with its secure lockdown it will isolate any potential malicious code (include the hooked code). If implemented by the financial institution, TrustDefender enables the financial institution to notify and provide feedback to the user within the login page based on the security health of the user’s computer and within a web2.0 environment…..most importantly before the customer puts in his or her confidential details i.e. ID, Password, 2nd factor security code.

yaludleboa-time-0_04_0306

If you opt to view the details, you can see that TrustDefender will detect the system hooks as part of its forensics engine

kernel-forensics1

However the most important part is not the details, the most important part is that ‘all TrustDefender users and those customers of financial institutions deploying TrustDefender are protected by default and by design’ – straight out of the box! No need to do anything. Let TrustDefender do the hard part.

However as always: Even though TrustDefender protects you from the attack, we believe in defence in depth and we recommend cleaning an infected system as soon as possible.

Are you infected? Removal

As the Trojan is almost impossible to detect from its files, the best way to see whether you are infected is to check the registry key HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon\UserInit. Make sure that there is no ntos.exe in here. It it is, you are infected!!!

A complete removal is quite tricky as the files are rootkit-protected and cannot be easily deleted. However you can disable the trojan by removing the ntos.exe part (just that part!) in the above mentioned registry key. After a restart, the trojan will not be active. However the malicious files (protected by the rootkit) are still on the computer. In addition, the above mentioned study provides removal instructions in chapter 16.

Furthermore you can contact us at TrustDefender for more detailed information at info@trustdefender.com.

Just in time for Christmas 2008, we have been seeing a new wave of our old friend the MBR/Mebroot/Sinowal/Torpig rootkit. This is one of the nastiest rootkits the world has ever seen – with only one goal: To steal people’s money and their identity. The MBR rootkit has been covered heavily in our Kernel Forensics Whitepaper and as there have been so many improvements of this rootkit, we will revisit a few of them here in this blog.

First of all, it is quite heavily distributed through drive-by-downloads via Neosploit, which is a very advanced exploit framework to compromise website visitors. The whole distribution method is one of the most advanced and well-thought-through processes.

First of all, it employs geographic IP checking so that they control specifically who will be targeted. This way they can target special geographic locations, but could potentially also target home user making life harder for security professionals. In our case, we couldn’t get infected from Australia, but were easily infected from Germany!

Secondly, after infection, the loader will “sleep” for a random period of time before anything happens. In our case, we had to wait approx. 6 minutes before the Master-Boot-Record was changed. This was clearly done to fool security researchers and automatic malware testing tools (as they would execute the loader and not see any activity at all!!!)

Thirdly, as with all MBR/Mebroot infections, the malicious code will only run AFTER a reboot as the loader will just infect the Master-Boot-Record. It is not until the next reboot, the whole Mebroot boot sequence will begin.

The boot sequence is a complicated, seven step procedure and will ensure that the computer will be infected without any malicious process or component even running on the system. This is possible because Mebroot has full control over the boot sequence of Windows.

But how can Mebroot/Sinowal do their dirty work without a malicious component? Well, because Mebroot/Sinowal controls the boot sequence, it can inject the malicious code into existing/legitimate Windows Components. It will “hook” key functions that the Internet Explorer will use to do it’s day-to-day job like sending and receiving data and encrypting that data. Yes, you are right. Mebroot/Sinowal does have full control over the encrypted data stream as it has access to it before it will be encrypted and after it has been decrypted. The picture below shows the key parts where code was injected – mainly into explorer.exe and iexplore.exe (Internet Explorer)

hooked_functions1

 This is also the reason why the rootkit is so invisible – simply because there is no malicious component on its own running. An infected computer with Norton 2009 running will not detect anything even for a full computer scan.

nis2009_full_scan

But how does Mebroot/Sinowal actually work from a user’s perspective?

Well, as Mebroot/Sinowal have full control over the internet session; they will dynamically inject their own malicious HTML code into the banking website to either steal existing information or to steal additional information. This is typically done after the user is logged in to what is for all intense purposes the authenticated secure banking website and therefore almost all users will be deceived as they are sure that they are not at a phishing site.

Please note: The user is actually at the right site. The SSL certificate is correct and valid. You even see the green bar from your SSL EV certificate, however the content is injected locally by the Trojan. Below are two screenshots from Bank of America and Citibank where the Trojan injects its own HTML to get additional personal information from the user.

Technical Details

As per always on this blog, we will provide some technical background and how it looks like from a user’s point of view. A full technical description of Mebroot/Sinowal is available here: http://web17.webbpro.de/index.php/analysis-of-sinowal (thanks to Peter Kleissner)

We analyzed the following sample on Jan 5, 2009 and according to Virustotal, only 8 out of 38 Antivirus Engines detected this Mebroot/Sinowal sample (http://www.virustotal.com/analisis/fe95bd3e4e26a22c8be7b6f1ead6bcec). None of the big Antivirus Engines like F-Secure, McAfee, Sophos or Symantec detected it. At least Trend Micro’s heuristic engine came up with the name “Cryp_Xed-3″)

What are the Antivirus Engines doing?

This brings me to one of the main points of this post. “What on earth are the Antivirus Engines doing?” As always, we were doing our analysis on a clean machine without Antivirus Engine to see what the virus is doing.

However we couldn’t believe our eyes when we retested with Norton Internet Security 2009 running and it did just nothing. Norton Internet Security 2009 is one of the best Antivirus Engines with a fast scanner, a nice user interface and a good protection, however it did just nothing!!! The Mebroot/Sinowal installer successfully infected the Master-Boot-Record, after a restart, the machine was compromized and NIS 2009 was just silent. (Note: We really do not want to single out Norton 2009 here. As stated above we think it’s one of the best products and many people we know use it and for good reason. However you can imagine what the situation looks like for less advanced products like any of the free Antivirus products used by consumers today)

norton_2009_siteisapproved1

Side Note: This picture illustrates another problem of many “phishing” protection tools. I don’t think that the page as it is displayed belongs to the company represented…

Movie / TrustDefender

TrustDefender will successfully protect the user from this attack by default . TrustDefender will alert you that your Windows Kernel has been compromized and will automatically secure the internet banking transaction regardless.

We have put together a little screen capture movie that demonstrates how Mebroot/Sinowal successfully infects a customer’s PC even with Norton 2009 installed and how TrustDefender protects this use for a Bank of America session.

Please note: In this movie, TrustDefender does not run in quiet mode for this transaction with Bank of America as the TrustDefender Enterprise Server is not integrated with the BofA backend systems. Financial Institutions can integrate the Enterprise Server enabling the full functionality and run in a quiet mode protecting the consumer with little or no interaction required from the account holder. However TrustDefender Gold Customers will be protected regardless.

(click on the picture to start the movie)

movie

Outlook

We will leave this machine running and will update soon on how the Antivirus Engine will pick it up once they update their patterns. It will be quite interesting as there is no process running or anything… Let’s see.

In this blog, we normally analyze nasty Trojans or other nasty stuff that is – in almost all cases – so new that very few Antivirus Engines can pick it up and protect the user (see e.g. the post about the yaludle/Silentbanker Trojan).

However, today the story is about a typical internet user, about Joe the Plumber, about the Hockey-Mum, about an old Trojan and about the reality out there in the world wide web.

Paula (not her real name) had AVG Free 8 and SUPERAntispyware installed and both components were up-to-date, however she got infected with a Trojan of the limbo family that stole her login names and passwords and only after 9 days it got removed partly by SUPERAntispyware and after 10 days completely by AVG. 10 days!!!

Two months later, she got infected again, this time with the Vundo Trojan even though she has AVG8 & SUPERAntispyware installed. Most probably she got infected through a vulnerability, through a compromised website and/or she got tricked into downloading it deliberately. Unfortunately we have seen this way too often.

But the most interesting part for us was the behavior of the user (Paula) and the current Security Software. For the first 7 days since infection, she didn’t notice anything. No alerts from AVG, however she noticed that she got to funny websites and got offered to install Antivirus 360!!! After approx 7 days, she got a message box from AVG saying that there are some DLL’s on her computer with the Vundo Trojan. However AVG couldn’t remove the DLL’s (as they were protected with rootkit-techniques). Now she knew her system is compromised but her Antivirus failed to secure her!!!

The issue here is that the lay person has no idea if they are protected or not and Paula was not protected.
What now happened is that whenever she opened a web browser, the Trojan would open more windows with Advertising, Adware, Spyware and other nasty stuff. Quite regularly she got alerted that her computer is infected and she would need to download XP Antivirus or Antivirus 360 to fix it. (What a great marketing as these websites know for sure that the machine is compromised ;-) . Luckily she knew that she had already an Antivirus Engine running and didn’t download one of those rogue Antivirus Engines……even though this pop up sounded like a familiar named Antivirus Engine she had heard of before.

We thought this is a good field test and installed Norton Internet Security 2009 and after it forced us to remove AVG (apparently Symantec wants to rule the desktop!), it did a quick scan and alerted us that the computer is infected with Trojan Vundo. The Norton User Interface was actually very nice as it didn’t list all the infected files, it realized that they all belong to Vundo and only showed one line. Impressed with this, we found a button “Fix this” and thought we give it a try.

We got a nice green alert saying that the threat has been removed successfully and the computer is safe now. We thought that was really easy and even a typical internet user may be able to do this – until we restarted the machine.
The startup was uneventful and Norton did not alert us of anything. However when we used the webbrowser, other windows with adware/spyware appeared again!!! When we did a Quickscan in Norton 2009, the Trojan Vundo was back!!! A “Fix this” removed it (again), making us believe it is gone, but it will always re-appear……every time the user restarts the machine.

So in the end, we AVG Free 8 and SUPERAntispyware didn’t stop the Trojan from installing and doing its nasty work. Norton Internet Security 2009 provided a much better protection, however failed to remove the Trojan completely causing the potential ongoing threat to the user. And this for a Trojan that is around for more than 4 years (in various mutations)!!!! We as a security software industry can’t be serious. There has to be a better way. How can a typical user even think that they are protected by traditional Antivirus Engines?

We had to manually remove all entries in the various startup sections of the system as well as one BHO inside the Internet Explorer to successfully get rid of Vundo. Now we could remove the files with specialized tools (to counter the rootkit-component) to have a clean machine again :-)

Even though this Trojan was technically not very challenging or advanced, we learned a valuable lesson.

Some technical details

The Trojan consisted of three DLL’s. No executables were involved – this was clearly done to avoid detection from security tools that check the running processes. Two DLL’s were started during system startup with two entries into the HKLM\…\Run section with rundll32.exe (which is a totally legitimate Microsoft application) and one DLL was registered as a Browser-Helper-Object (BHO) in Internet Explorer.

Interestingly all three DLL’s were NOT visible in the Windows Explorer as they used user-mode rootkit techniques to avoid detection.

All three components checked the presence of each other, meaning that if you only remove the BHO but not the other DLL’s, the BHO will be automatically re-created. And if you remove the two startup DLLS’s but not the BHO, the two startup DLL’s will be recreated automatically as well.

Virustotal Detection is unfortunately again very low!

BTW: One of the offered rogue Antivirus Engines had the filename InstallAVg_770522170802.exe! Sounds familiar, doesn’t it?

TrustDefender

A quick note on TrustDefender: Even though Vundo does not try to steal confidential information like username/passwords, TrustDefender picked up the Vundo DLL’s from the first second with our whitelisting approach and the DLL’s were automatically removed from memory on-the-fly. Our rootkit scanner detected them without any problems. All TrustDefender users were protected, especially for any enterprises (Online businesses) that use the TrustDefender system, for all Financial Institutions that are part of our Financial Trust Network and for all self-defined websites.

After a few reports in the press around a new Malware that specifically targets Firefox users, we thought we have a more detailed look at this piece of malware.

In general, it only targets Firefox users. This fact will disturb many users that “escaped” Internet Explorer and switched over to Firefox for security reasons. It is long known that Firefox has with the XUL Interface and the Plugins a mechanism that is very similar to Internet Explorer’s BHO (Browser Helper Objects). In fact, the browser plugin is essentially just a DLL that can contain whatever content – including malicious one.

When we installed this component, the first interesting thing was that it will install itself silently without any user interaction or user notification. This is a bit disturbing as normally the Firefox User Design is quite well-thought through.

What this malware then does is as follows:

  • It has a pre-compiled list of hostnames that it watches for. If the user goes to any of these websites, the malware will load the malicious DLL and inject HTML into the current Firefox page.
  • This additional code will then steal any information they want, including username and passwords and other identity related information.
  • The sample we analyzed affected 103 financial institutions worldwide, including 10 financial institutions in Australia.

Technical Details

After the malware is installed, it is actually visible as a plugin, however it has the innocent name “Basic Example Plugin for Mozilla”

It hooks into the XUL engine and “watches” the internet traffic for the URL’s it is interested and injects then HTML code.

Overall this malware is not anywhere as sophisticated as the top-class trojans like silentbanker, Sinowal, …, however it gets the job done. A few things are worth mentioning as they are quite unique:

  • The malicious component (DLL) will only be loaded if the user goes to any of the URL’s the malware watches. This means that e.g. when you start Firefox, the system and all components are fine and the malware actually is not active in memory.
  • Only when the user enters one of the affected financial institutions website, the malicious DLL is loaded.

How to check whether you are infected?

You can check whether you are infected by openin your Firefox Browser and clickin on the Tools-Menu and select “Add-ons”. Then select the last tab called “Plugins” and make sure that you do not have a plugin called “Basic Example Plugin for Mozilla – npbasic”.

If you see this, you can disable the plugin by clicking on “disable”.

All TrustDefender users are protected by default from this attack.

Overview

We were looking last week at a compromised computer that was infected with the Silentbanker.B variant and we could recover all relevant files including the installer.
Initially the Silentbanker Installer was executed as a drive-by-download and as the Antivirus Engine had no signatures for it, it could install itself.
After that, the Silentbanker Trojan will use a number of techniques to steal confidential information:

  • It downloads encrypted configuration files from the internet to stay up-to-date with the policies
  • It injects malicious HTML inside the current browser process to circumvent any browser based security solutions, including (EV-) SSL certificates, …
  • It is a real-time Trojan that will transmit the stolen information instantly to circumvent any sandbox security solutions and 2-factor authentication devices. That also means that someone without your knowledge and without your approval is successfully authenticated. Even with a One-Time-Password.
  • It uses userland-rootkit techniques to hide the malicious components from the harddrive to evade detection.

However in the end, the Silentbanker Trojan is a very sophisticated BHO (Browser Helper Object) that works only with the Internet Explorer.

TrustDefender customers were protected against this by design with the Safe&Secure Mode and the Secure Lockdown.

Technical Details
Once infected, the malicious BHO named mscorews.dll is loaded as a BHO from the Internet Explorer. However the interesting part is that once it is loaded, it will not be visible in the file system.

Even more: Once the component is loaded, it will hide the file from the Windows API thus making the file “invisible”. Also the malicious DLL cannot be located through traversal of the module list of the Internet Explorer. In some sense, it does neither exist in memory, nor on the disk. Pretty clever :-)

If the user now browses to a banking website that is known to the Silentbanker Trojan, it will inject the malicious HTML code.

     

 

 

 

Now that the Trojan asks for addition private and confidential information from the user as opposed to the information the real bank login would ask. This information is collected and sent ‘in real-time’ to the C&C server located in Russia.

 

What happens if TrustDefender is deployed: With TrustDefender installed, when the customer logs in, we can also verify that the Secure Lockdown will successfully protect the user from having their confidential details stolen as the Silentbanker Trojan cannot send anything to anywhere (except the “real” SSL Certificate Fingerprints of Bank of America).

 

 

 

 

Note: Another interesting fact is that this Silentbanker Trojan specifically targets the TAN (One-Time-Passwords) implemented mostly by german banks. This shows that there is only so much you can do on the server side and a full security solution has to include the client.

The targeted banks for the TAN systems are: Postbank.de, Citibank.de, Deutsche-Bank.de, Norisbank.de, Seb-Bank.de, Fiducia.de (all Volks-/Raiffeisenbanken), Comdirect.de, 1822direkt.com, Haspa.de, Hypovereinsbank.de, Weberbank.de, Gad.de, Sparda.de, Mlp.de, Kaupthinedge.de, Psd-bank.de,

Unfortunately the virustotal results of the malicious Silentbanker Module is quite disastrous (only 7 out of 36 Antivirus Engines detected the Trojan) last week. (see http://www.virustotal.com/analisis/9e1c5e1c068fd0de61133594ca404519)

 

 

 

We were analyzing an interesting piece of malware today which is a recent mutation of the yaludle/silentbanker trojan with rootkit capabilities.

This rootkit is typically installed via drive-by downloads.

It targets financial institutions worldwide (with a focus on US, Germany, Spain, Australia) and as the silentbanker versions before, it can successfully cicrumvent Two-Factor-Authentication, which is why quite a few banks with 2FA solutions are targeted.

The trojan operates in two modes:

  1. completely silent (this is typically for banks with just username/password) and just “uploads” the collected information in real-time in an encrypted way to a malicious host
  2. it introduces dynamically (in real-time) malicious HTML elements into the banks website to collect additional information. This malicious HTML elements appear within the bank’s site, so nobody (not even security experts) can spot anything suspicious.

As we would have expected, virtually no Antivirus Engines were detecting this Rootkit (1/36, 2.78%, http://www.virustotal.com/analisis/756098da62febc1ae372f947e2b62184)

This is the original citibank site when someone tries to login with a wrong username/password (so no yaludle/silentbanker here) (click the image for bigger picture)

 

This is the citibank site in exactly the same scenario, this time yaludle/silentbanker is active. (Note the yellow padlock and the correct URL!!!) (click the image for bigger picture)

How to detect this Rootkit

This rootkit creates the following registry key and thus can be detected if this key is present

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Drivers32
wave1 = "<RANDOM>1.CPX"

Also the <RANDOM>1.CPX file is present in the C:\WINDOWS\SYSTEMS32 directory.

TrustDefender

All TrustDefender users (most notably all of our enterprise customers) are protected as TrustDefender’s Secure Lockdown will make sure that no personal information will leave the computer as it will only allow internet requests to the banks website.

Also all TrustDefender users are also protected for all banks who are part of our Financial Trust Network (see http://www.trustdefender.com/lang-en/support-portal/knowledge-base/knowledge-base-article?id=50120000000DB0q)

more information

please contact us at support@trustdefender.com if you want to know if your financial institution is affected or you need more information.

When we recently got hold of a new “trick” to load a driver bypassing HIPS and security programs that block SYS drivers when they are loaded, we thought we give it a go…

While there is a bit of discussion whether this is actually a new mutation or the famous rustock.b rootkit, it looks more like a zlob variant.

Whatever the nomenclature, this piece of malware is very sophisticated in the way it infects your system and also in the way it works.

First of all, it bypasses HIPS and other security programs by using a little known trick that exploits loose security settings with a system wide cache of internal windows objects (\KnownDlls). This enables the driver to be installed silently.

Secondly, this rootkit resides solely in kernel space and has no user mode component at all. It hooks into your google search and while you think you get to the search result, this rootkit controls the session and gives you content that you definitely don’t want to see… Pretty scary stuff, as nobody would realize that the google search page is infected!!!

But see yourself… Simply click on the screenshot below or click here to start the video.

P.S. you’ll also see how TrustDefender’s Kernel Forensics Engine will pick this up and how financial institutions can protect their customers _before_ anything bad happens…

We at TrustDefender Labs have seen a quite dramatic increase in so-called “Rogue Antivirus Enines“. These have been around for several years, but the sophistication to trick users to install them are mind-blowing…

We looked at a wsnpoem malware that served as a dropper for the adware called “XP Security Center”. Everything looks really authentic and even though the system was clean before, the adware will physically create random files and pretend they are malware… Then they harrass you to buy the XP Security center for $49.95 a year to get rid of them…

The lesson to be learned is that it gets harder and harder to distinguish legitimate and genuine software from fake and rogue software.

Have a look at a screencapture yourself… (click on the image to start the streaming video)

Back in January 2008, we looked at how the TrustDefender Kernel Forensics Engine can detect the Silentbanker Trojan and the Master Boot Record (MBR) virus.

Since then, many new variants of te same rootkits have been released and we thought we have a more detailed look into a new variant of the MBR Rootkit (Torpig)

Alarmingly we found that the wider Antirivus products do not pick up this variant (and possibly also earlier ones) more or less at all (!)

Almost not a single Antivirus Engine was detected the MBR/Torpig-Dropper when we got a sample. When we checked it first, 2 out of 33 (6%) of the Antivirus Engines detected some suspicious behavior (see Attachment 1).

The next day, only 11 out of 33 (33%) detected the threat with some of the big names still not protecting their customers like CA, McAfee, Sophos or Symantec. (see Attachment 2).”
This variant of the MBR/Torpig trojan is installed as a drive-by download which is triggered by some highly obscusfated Javascript Code. So, innocent users won’t even notice any download or installation, especially If they haven’t kept their Windows up-to-date. Even for those who are up-to-date or if they have accidently allowed the program to run, it’s game over.

 
Attachment 1 – Virustotal Result

 
Attachment 2 – Virustotal result next day


Attachment 3 – TrustDefender Kernel Forensics Dialog