maradydd: (Default)
maradydd ([personal profile] maradydd) wrote2009-10-03 11:19 pm

New malware vector: short-circuit victims' rational thought with fake IRS notices!

I'm not quite smart enough to do real malware analysis like [livejournal.com profile] foxgrrl does, but ever since the days of the "I Love You" virus, I've been tremendously amused by the social-engineering tricks that malware authors use to trick victims into opening their payloads. Tonight I received one that struck me as especially clever: a fake "Notice of Underreported Income" letter with a link to a page where the target (my company) is prompted to download an .exe which purports to be the tax statement. The page -- which is now down, and I'm sorry I didn't get a screenshot -- is a well-done mockup of the IRS' own site, but it's actually a PHP page hosted on www.irs.gov.vdsl.im. Ha ha!

I saved the offending .exe and ran it through a decompiler. From the sheer number of CryptoAPI symbols and symbols related to Windows file handling present, I'm guessing it's some kind of "encrypts your whole hard drive" ransomware. There are also several other symbols, such as BuildImpersonateExplicitAccessWithNameW, which suggest that the original source language was Delphi. (Aside: why the hell is Delphi such a popular language among malware authors? Some of the most eye-poppingly awful source I've ever seen -- in a 2004-era issue of 2600, amusingly -- was somebody's attempt at a rootkit written in Delphi. The author waxed rhapsodic about how great it was that a Delphi compiler could be had for free on a CD-ROM that came with some magazine that was on the stands at that time. This further cements my opinion that malware authors these days are nothing more than a combination of the worst aspects of script kiddies and cut-and-paste wannabe programmers. If you're trying to write something for Win32 without access to Visual Studio or one of those other closed-source compilers, either learn cygwin/MinGW or get off my lawn. Amateurs.)

More than that I do not know, as figuring out what a program does from its representation in assembler is beyond me. If any of my Faithful Readers want a look at it, I'll be happy to send them a copy.

And, of course, if you receive what appears to be a threatening email from the IRS, take a close look at the links in the message, and examine the email headers as well. (In this particular case, an email that was really from support@mail.irs.gov would not have a Return-Path header of scubaedrs530@shatneresque.com. It's also important to look at the Received headers -- particularly the last one, as this will tell you what IP the message originated from. In this case, it came from 95.58.33.236, which looks to be a metro broadband network in Kazakhstan. Again, not the kind of place the IRS is likely to be sending anything from.)

ETA: [livejournal.com profile] patrickat rightly points out that the IRS does not send official tax correspondence via e-mail, so you don't even have to look at the headers to know that a letter like this isn't legit.

[identity profile] patrickat.livejournal.com 2009-10-03 11:03 pm (UTC)(link)
It would also help if more people knew that the IRS never, ever sends official tax correspondence through e-mail. If they want to notify someone about a problem with his or her taxes, they'll send a good old fashioned nastygram via the U.S. Postal Service.

[identity profile] allonymist.livejournal.com 2009-10-04 02:12 am (UTC)(link)
I've got no experience with it, but I have heard that hooking Windows system calls in Delphi is exceptionally easy. I have no idea if this is so, or why.

[identity profile] barbarienne.livejournal.com 2009-10-04 02:41 am (UTC)(link)
This is why I maintain multiple email addys. If something hits a particular one of them, I know it's fake.

I love all the letters purporting to be about a PayPal issue when I don't have a PayPal account.

[identity profile] buruna-enu.livejournal.com 2009-10-04 04:18 am (UTC)(link)
Heh heh.

Get off my lawn.

:)
vatine: Generated with some CL code and a hand-designed blackletter font (Default)

Even funnier...

[personal profile] vatine 2009-10-04 09:24 am (UTC)(link)
They don't know/care who they're sending to. I got at least one to a work address (non-US, working for a non-US company, in non-US).

[identity profile] grimmtooth.livejournal.com 2009-10-04 06:36 pm (UTC)(link)
Wait - RANSOMWARE? Wow, the future got here faster than I expected.

You know, technically they don't even need to be able to decrypt it. Get moniez, then run. What are they going to do, leave a negative eBay rating? "Results not as expected. Would not pay ransom again."

[identity profile] maradydd.livejournal.com 2009-10-04 06:40 pm (UTC)(link)
Yep. [livejournal.com profile] foxgrrl has had some interesting posts on it recently, spoke at BruCon about it, and will probably speak at ToorCon about it.

There's an advantage to actually recovering the victim's files -- that way the victim can be hit by the virus again. The next step should really be protection-money-ware, where if you don't pay a fee every month, your files get encrypted all over again (and you have to pay more to get them unencrypted, naturally).

[identity profile] grimmtooth.livejournal.com 2009-10-04 10:05 pm (UTC)(link)
Excellent point. Plus, I suppose, blackmailware (pay us or we tell people what is on your hard drive).

[identity profile] neoliminal.livejournal.com 2009-10-04 08:45 pm (UTC)(link)
Delphi!!!

I love it. (Not Delphi, I mean I have no opinion on that language other than it's a bit fringe...)

I mean did the guy program it on an Amiga too? Just to be safe.

I've always wanted to write malware that, you know, helps people. [rolls eyes].

[identity profile] maradydd.livejournal.com 2009-10-06 11:16 am (UTC)(link)
You might enjoy reading about Code Green, authored by Markus Kern.

[identity profile] neoliminal.livejournal.com 2009-10-13 04:33 pm (UTC)(link)
I actually read about this a long time ago.

[identity profile] http://users.livejournal.com/_rck_/ 2009-10-06 02:48 am (UTC)(link)
Microsoft Visual C++ entry level is now free, btw. Still closed source of course.

[identity profile] maradydd.livejournal.com 2009-10-07 01:59 pm (UTC)(link)
It probably betrays my age that I'm more comfortable with cygwin, g++ and emacs on the few occasions when I do have to code for Windows.

[identity profile] http://users.livejournal.com/_rck_/ 2009-10-07 02:13 pm (UTC)(link)
Well, since I am older than you (I am pretty sure), I am not quite clear what to reply ... Emacs + cygwin is clearly my preference as well.

[identity profile] staghounds.livejournal.com 2009-10-07 01:45 pm (UTC)(link)
Yet another reason I'm glad I use a mac and web based email.

[identity profile] maradydd.livejournal.com 2009-10-07 01:54 pm (UTC)(link)
I'm too twitchy about the idea of people I don't know having access to my email to really trust web-based email, but I swear by my Linux box.

[identity profile] palecur.livejournal.com 2009-10-08 07:36 pm (UTC)(link)
I sometimes think of setting up an at-home box to serve up my tiny webpages and handle all my own email, but frankly I'm lazy. It's my ethnic birthright! *tips down sombrero, hides behind burro*. I guess my personal effort vs. risk familiarity curve intersection is at a different spot on the chart. But I guess I don't want to wait to get badly burned to shift my risk profile. *strives to be less lazy, yawns* Tomorrow maybe.