Slashdot Mirror


'Stealth' Worm Hinders Sandbox Analysis

Tuxedo Jack writes "The Register reports that the new Atak worm cannot be analyzed or debugged by antivirus companies without quite a bit of work, due to the author being sloppy with his or her code. Windows machines, as per the norm, are the only vulnerable ones, and it still requires user intervention to infect. Perhaps future worms will start including this 'bug' in their releases. We can only hope not." It doesn't sound like a bug at all, from the virus writer's perpective.

121 of 461 comments (clear)

  1. Strange by Metteyya · · Score: 4, Interesting

    I've always heard that it takes a very good programmer to write effective and powerful virus.

    1. Re:Strange by cuzality · · Score: 5, Insightful

      "The greatest trick the Devil ever pulled was convincing the world he didn't exist." --Verbal Kint

      And the greatest trick this guy pulled is making himself look like an ID10T...

    2. Re:Strange by Homology · · Score: 2, Funny
      I've always heard that it takes a very good programmer to write effective and powerful virus. /I>

      Not on Microsoft Windows, it seems. From the article it's even better if the virus writer is sloppy.

    3. Re:Strange by ObsessiveMathsFreak · · Score: 3, Funny

      Clearly sir, you have never heard of VBA.

      Empowering amatuers with sysadmin capabilities since 1993!
      Where would you like script kiddies to joyride your computer to today?

      --
      May the Maths Be with you!
    4. Re:Strange by scooby111 · · Score: 3, Interesting

      That alone is a powerful and elegant argument that some of these virus writers are in the business. I've long suspected that some of the smarter members of the antivirus teams are actually writing worms and viruses.

      Arsonists and firebugs like to watch firemen put out their fires. Is it really a stretch to apply that behavior to digital firestarters?

    5. Re:Strange by Anonymous Coward · · Score: 5, Funny
      The creator of the Melissa virus left his email address in a comment. What sort of very good programmer uses comments?!?

      The guy who framed that poor patsy for creating Melissa, that's who.

    6. Re:Strange by PeterPumpkin · · Score: 2, Interesting

      I imagine that is why there is a plethora of professional closed-source Windows freeware out there, with all the fancy professional "Easy To Use ONE CLICK Software!" (emphasis not added) - from entities that only produce or distribute freeware programs.

      The virii that come out of those are mostly yet-to-be detected, I'm sure...

      For example, on this specimin, they have:

      ATTENTION WIN XP USERS: Windows XP will not allow you to access 16-bit screen savers (which make up about 2/3 of all the screen savers out there, including many of your classic favorites.) To get around this, you need to use a screen saver utility like Screen Control, which allows you to access ALL your 16-bit and 32-bit savers with simple one-click access from your system tray. Try a FREE DOWNLOAD today.

      Uh huh - highly suspect.

    7. Re:Strange by xandroid · · Score: 2, Informative

      Actually, that was first said by Baudelaire in "Le Joueur généreux", published 1864.

      "...la plus belle des ruses du diable est de vous persuader qu'il n'existe pas!"

      "...the devil's best trick is to persuade you that he doesn't exist!"

      --
      $ echo "ceci n'est pas une pipe" | sed -Ee 's/(eci n|pas )//g'
  2. so is this what MSFT does? by garcia · · Score: 3, Insightful

    They make such bad code knowing that it won't be looked at and hope that the hackers won't be able to find the holes?

    Without the recent access to the source for IE we would never have found out about BMP overflows, etc. Which was just poor and lazy coding.

    1. Re:so is this what MSFT does? by eldacan · · Score: 3, Interesting

      Just wondering: did people really find many bugs/bad coding/etc. in this code? I've only heard of this bmp thing, and that it was only in IE prior to version 6.

    2. Re:so is this what MSFT does? by spitzak · · Score: 3, Insightful

      This is about the fourth time I have heard the "BMP thing" being spouted by a Microsoft / closed-source apologist. Is there any documented evidence that this has been used in *any* virus/worm/hacks? And has there actually been more than one bug found (I suspect not, since trolls keep saying "bmp bug! bmp bug! bmp bug!") I don't think so.

      Availability of the source code does not lead to exploits. Anybody with even a moderate amount of experience with software development would know this. If the exploit was evident by looking at the code, the code writer would probably fix it. Every single exploit is discovered by accident, put in a "bug report", and the code writer has to spend a huge amount of time figuring out exactly how his code, which looks just fine, is producing the unwanted behavior. The discovery of unwanted behavior is exactly equal in both open and closed source.

      In fact the advantage of open source is not that it has fewer bugs, but that when such unwanted behavior is discovered by accident, a huge number of people will try to fix it. Even people who get it wrong will produce modified versions that are less likely to be attacked by a virus.

    3. Re:so is this what MSFT does? by aardvarkjoe · · Score: 3, Insightful
      This is about the fourth time I have heard the "BMP thing" being spouted by a Microsoft / closed-source apologist.
      Er ... don't know about anyone else, but "They make such bad code knowing that it won't be looked at and hope that the hackers won't be able to find the holes?" doesn't sound much like apologism to me. (Doesn't sound much like proper grammar, either, but I suppose that's beside the point.) If anything, the fact that we haven't heard about a rash of new exploits based on it seems to indicate that broken portions of the code aren't as obvious and easy to fix (or exploit) as some parties like to claim.
      --

      How can we continue to believe in a just universe and freedom to eat crackers if we have no ale?
    4. Re:so is this what MSFT does? by maximilln · · Score: 5, Insightful

      The parent is horribly bipolar.

      I have heard the "BMP thing" being spouted by a Microsoft / closed-source apologist

      Actually an apologist wouldn't be spouting about the BMP exploit. Rather an apologist would be trying to dismiss it as you do in here:

      Is there any documented evidence that this has been used in *any* virus/worm/hacks?

      There. Now you're being the closed source apologist by saying,"We're sorry about the BMP thing but does it really make a difference?" Since it's been pointed out that the BMP thing was only present in older editions of MSIE (5.5?) it's pretty plausible that the forensic trail of tracking any exploits is long covered, formatted, and reinstalled.

      And has there actually been more than one bug found

      The security industry has its hands full simply processing data on exploits which are submitted. The people who have time to go over that released source code routine by routine, structure by structure, loop by loop, aren't going to tell you about it first. If they're nefarious they're not telling anyone.

      Additionally, did you read this yesterday? Did you try contacting the authors who published those vulnerabilities? It's quite possible that they came onto those vulns by looking at the source code.

      So sit down and...

      If the exploit was evident by looking at the code, the code writer would probably fix it

      That's a bit shallow minded. Not every programmer who works for MS was a 4.0 overachiever who visualized code loops and logic flow in real time. Very few middle managers were 4.0 overachievers--many got to their position because they were better at social networking than coding networks. By the time the code gets to the upper management it's not being audited line by line. Even 4.0 students aren't always guaranteed overachievers with amazing perceptual abilities. Many 4.0 students know how to stand in line and keep their mouths shut. That's the most assured way to a 4.0.

      Every single exploit is discovered by accident

      I would agree that the majority of exploits are discovered by someone noticing erratic behavior in a program and taking the initiative to dig in deeper. However I know a number of people who take great delight in poring over changelogs and then going back to audit source code when "Bug in <sourcefile.c> fixed." The changelog may have been a roadsign but when sourcefile.c is 1000+ lines it's still a testament to skill to find the bug which was fixed.

      --
      +++ATHZ 99:5:80
  3. Mailers? by Deflagro · · Score: 4, Insightful

    Now just imagine if someone wanted to actually be malicious with this stuff..
    I wonder if a virus with some code to re-partition your drive on a reboot would cause this issue to be taken more seriously.
    I think we're just lucky these writers don't do more with the holes Microsoft gives them.

    --
    Der Tod ist der einzige Weg hier raus!
    1. Re:Mailers? by Tyler+Eaves · · Score: 4, Insightful

      The thing with destructive viruses is that they don't tend to spread very far, since by definition they take their host (and thus themselves) out after a few minutes or hours, where as something like Code Red, Nimda, etc,etc, can go for years without being removed.

      --
      TODO: Something witty here...
    2. Re:Mailers? by ites · · Score: 5, Insightful

      Read about the mechanics of disease spread with respect to viruses and you'll see why this does not happen.

      Highly damaging viruses don't spread far. Today's virus/work/trojan writers want to capture large numbers of zombie PCs and resell these networks. They aim for control, not damage. It's about money, not vandalism.

      --
      Sig for sale or rent. One previous user. Inquire within.
    3. Re:Mailers? by Deflagro · · Score: 3, Insightful

      But technically, if someone decided to make the virus malicious and mail itself out first before injecting the damaging code...then you can have a Code Red that kills machines.
      Although, like a poster below, the data changing aspect would be a more annoying bug.

      I'm just saying that MS can be made to look real bad in the eyes of corporations. Mind you, the person responsible for something like that would get the death sentence under Patriot Act or something i'm sure.

      --
      Der Tod ist der einzige Weg hier raus!
    4. Re:Mailers? by (54)T-Dub · · Score: 3, Insightful

      Yes, but the longer a host is infected the more opportunities it has to infect other machines. Especially if the user doesn't know they are infected. Not to mention the "hype" factor of big destructive viruses tends to help quell their outbreak.

      --

      "I can not bring myself to believe that if knowledge presents danger, the solution is ignorance" - Isaac Asimov
    5. Re:Mailers? by Lumpy · · Score: 5, Insightful

      but creating an ebola computer virus would not be hard.

      code red for example if it had a timed payload that X minutes after infection kill the machine and that number of minutes was 3 days in the future it would be able to widely spread and STILL cause the death of the host machines.

      the scaries is the stealth virus that spreads slowly, is silent and act's mostly benign for 90 to 120 days then simply kicks in for a full boat infection/attack+death 4 hours after final activation.

      by the time it was discovered most people would be helpless.

      --
      Do not look at laser with remaining good eye.
    6. Re:Mailers? by tmasssey · · Score: 5, Interesting
      You really don't think something like that would be noticed?

      Let's imagine a *really* slowly reproducing virus: one that attempts to infect just a single computer a day. Now, you *could* go even slower, but 1 a day is pretty slow, wouldn't you agree?

      Now, on day 1, there might be only a single packet sent by a single computer. I don't think anyone is going to notice that. But at some point, a large-enough collection of computers will send out these requests, and it will get noticed.

      The question is, how many infected computers do you need before your attack is detected? If it's something like Code Red, a few thousand will get noticed: they spew out too many requests. One a day? It's harder to say. Will someone notice when there are 100,000 attacks a day? 1,000,000? But how long will it take to *get* to 100,000 infected computers? How many attacks will fail? Odds are, most of them will fail: not every IP has an attackable computer...

      In other words, you could easily create a silent attack that doesn't kill anyone. Or a very noisy attack that also kills no one because it's stopped in time. Can you create a somewhat silent attack that infects a large number of people before they find out? Very tricky. It's an almost impossible balance: crash too soon and it doesn't really do anything, wait too long and it'll get caught.

      To me, the better attack would be a *lightning* quick attack. Something like Slammer. According to this, Slammer was able to attack every vulnerable computer available in 20 minutes. I'm not sure how much I believe this, but I've heard that 15 Million computers were infected in that same 20 minutes. Is 15 Million dead computers enough for you?

      Create a virus that spreads for an hour. Infect 15 million computers. Kill them. Good luck stopping that. The best part is, if you do your job correctly, either build a virus that only remains in memory or have it destroy the local copy of the virus in the process of killing the computer. Not only will the computers be dead, but it'll be *real* hard to figure out what hit you...

      Now that I write that, that is a little scary...

    7. Re:Mailers? by mrogers · · Score: 5, Informative
      This paper predicts that a fast-scanning Nimda-like worm launched against a small "hit list" of known vulnerable machines could infect millions of machines in minutes - too fast for any human-mediated response. Such a worm could reach saturation point and begin destroying its hosts before most admins had even noticed what was happening. Even those who noticed would not have time to study the worm's behaviour, let alone analyze its code. Stealth code would therefore be unnecessary, except to make it more difficult for subsequent investigations to identify the source of the worm.

      The hit list technique speeds up the initial phase of infection, which is normally slow and vulnerable to isolated failures. The list is compiled ahead of time by normal vulnerability scanning; the machines on the list are simultaneously infected to start the attack. Each copy of the worm then scans for and infects further vulnerable machines as quickly as possible, dividing the address space at each hop to avoid unnecessary overlaps (some redundancy might be desirable, but completely random scanning would be inefficient). The list can be divided in a topology-aware way to reduce congestion that might otherwise limit the rate of infection.

    8. Re:Mailers? by Lumpy · · Score: 2, Interesting

      actually you have a point there that would work well...

      do a slammer attack, fast as hell infection rate delay only a 3 minutes or so and then roll the dice to speak.

      give computers a 50% chance of dying or simply an immune carrier/spreader.

      that would be even more evil... there is a 50 50 chance that your Pc unce infected will be killed, or it becomes a spreader until it is cured.

      now make the virus morphing. try attack1, infect. if attack1 fails, use attack2 and morph to hide from scanners.

      so you got atacked, cleand it, there is still a chance of you getting reinfected and killed.

      --
      Do not look at laser with remaining good eye.
    9. Re:Mailers? by king-manic · · Score: 2, Interesting

      Liek natural virii dormancy is required for widespread infection. A dead machine is an early signal somethign is wrong and brigns attention. A dormant virus would not do so. Look at aids and herpes versus ebola. Dormancy helps it spread, virilence is independant.

      --
      "There are more things in heaven and earth, Horatio, than are dreamt of in your philosophy."
    10. Re:Mailers? by Coryoth · · Score: 2, Interesting

      The question is, how many infected computers do you need before your attack is detected? If it's something like Code Red, a few thousand will get noticed: they spew out too many requests. One a day? It's harder to say. Will someone notice when there are 100,000 attacks a day? 1,000,000? But how long will it take to *get* to 100,000 infected computers? How many attacks will fail? Odds are, most of them will fail: not every IP has an attackable computer...

      The solution to that sort of problem is not to just pound wildly on everything out there. Set up your virus to create a P2P style communication network of nodes and actually have instances of the virus COORDINATE their attack.

      Such a system could be quite nasty indeed.

      Jedidiah.

    11. Re:Mailers? by king-manic · · Score: 2, Insightful

      However, Virelence will dictate response. the RPC worms are stilla round because some machines have never been patched. Thus it will be a issue until all machine are pacthed. However the stoned temple monkey is no longer aorund. IT killed the computer so it mediated a response either the machien died or admins raced to fix it.

      Critical mass for infection is harder to reach if your lethal. The virus writter would have to predict reactive patterns and behavior in the wild. Hard. A lethal virii would have a shorter window. If it had a syncranized dormancy and waited till critical mass, then maybe. But you have to balance more time to get caught vs more time to spread.

      --
      "There are more things in heaven and earth, Horatio, than are dreamt of in your philosophy."
  4. Sloppy or devious? by hcdejong · · Score: 5, Insightful

    From the article: "I haven't seen such ruses used in a mass mailer in a long time. This piece of code is so sloppy, it's devious," said Mircea Ciubotariu, a researcher at Romanian AV firm BitDefender.
    I'm sure it's lost something in the translation. The rest of the article suggests it's by design rather than accident.

    1. Re:Sloppy or devious? by toasted_calamari · · Score: 2, Interesting

      Perhaps the AV people just like to convince themselves that the virus writers are bad coders, rather than live with the apparent reality that some of them are actually quite good.

      Or maybe I'm to cynical.

    2. Re:Sloppy or devious? by afidel · · Score: 3, Informative

      No, from what I read the virus has a crappy date detection routine and for some reason the "safe" environment they run tests in causes it to break. Of course when writing a virus you go for lean and mean rather than using the standard bloated OS interface so it's not a bug in the virus so long as it works correctly under a normal environment.

      --
      There are 4 boxes to use in the defense of liberty: soap, ballot, jury, ammo. Use in that order. Starting now.
  5. Re:Okay...? by ePhil_One · · Score: 3, Funny
    Worm or Virus?

    Since they claim it requires user intervention, that would make it a virus, since worms are self-propagating.

    Of course, given the accuracy I've come to expect from Slashdot summaries, it could be a new version of MS IE...

    --
    You are in a maze of twisted little posts, all alike.
  6. Interesting Concept by pHatidic · · Score: 3, Funny

    Atak uses a variety of tactics in its attempts to escape antivirus analysis. Its main trick is to check to see if it's being run in a debugging environment. If so, it exits to avoid detection.

    Would that make this worm a 'night crawer'?

    Badum Ching!

  7. Easy way to be safe by tomhudson · · Score: 4, Funny

    So all you have to do to be safe is make sure you've got a debugger running, and the virus kills itself. I guess that adds new meaning to the term "de-bugger" :-)

  8. The 2nd oldest trick in the book by magefile · · Score: 4, Funny

    "You're right, it's pure genius - they couldn't guess we'd do that, because only a frickin' idiot would do that!" - paraphrased from (approximately) 3.14 million movies.

  9. Makes for better AV companies by StickMang · · Score: 5, Funny

    Maybe this will teach them how to teach outside the (sand)box! Maybe they can harness their synergy with this new paridigm shift into sandbox free thinking.

    Ahh, its 1999 all over again :)

    1. Re:Makes for better AV companies by DA-MAN · · Score: 5, Funny

      Score: +5 Buzzwords!

      --
      Can I get an eye poke?
      Dog House Forum
  10. geez! by manavendra · · Score: 2, Funny

    Just what we wanted - buggy bugs, erm, viruses!

    You know something's wrong with the world, when the malicious software itself is flawed..

    --
    http://efil.blogspot.com/
  11. "So sloppy it's devious"? by ites · · Score: 4, Interesting

    One or the other... devious or sloppy... but surely not both.

    Maybe it's just a sign that malware is evolving along the same rules as organic life: accidental errors get selected for survival value and passed along to following generations.

    Malware that detects and disables attempts to reverse engineer it... ?

    Or perhaps we can read the anti-virus researcher's comments in a totally different light: /tinfoil on

    "Most viruses [which we develop ourselves to stimulate sale of our products and services] have a function to let us easily identify and sandbox them. In this example, the function is broken. So sloppy it's devious [and perhaps intended as a warning that we're not paying our freelance coders enough]." /tinfoil off

    Nah.

    --
    Sig for sale or rent. One previous user. Inquire within.
    1. Re:"So sloppy it's devious"? by shadowcabbit · · Score: 3, Insightful

      One or the other... devious or sloppy... but surely not both.

      Yes, it is both. It's sloppy because whoever wrote this virus forgot to disable the suicide code before releasing it into the wild. The writer obviously would have written this into the virus during development so that he didn't hose his own machine.

      It's devious because now virus writers know that "forgetting" to "fix" their virus pisses off more people in high places, instead of just plain pissing off more people. It wastes resources and diverts attention from bigger threats-- or smaller threats which just get lucky.

      It's a tactic so totally stupid that it borders on brilliance.

      --
      "Why Subscribe?" Good question...
    2. Re:"So sloppy it's devious"? by Gigahertz · · Score: 5, Interesting

      Thats one way of looking at it... if you like looking at it the wrong way.

      It was intentional, there is no question of this. It's funny that they're calling the code sloppy, and I wish I had a copy of the virus to see if I can figure out why they're saying this.... but its obviously intentional, but barely genious....

      Too much is being made of it... It's not a new technique outside of viruses, it's been mentioned further up the page, and personally I've dealt with programs that do the same thing, and effort always wins. You find the test traps, and you patch around them. It's not even any harder for them to detect, or add signatures in their virus definitions for, it's only more difficult to analyze what it does, but we know its a virus... so this is a non-news waste of time, the attention brought to it assures that more viruses will come equipped with a debugger check, and likely some virus writer will take the extra effort to make the code SO complicated/long/difficult to trace through (this may be the case with them calling the code sloppy) and a lot of extra $$ will be wasted and probably find its way into the cost of anti-virus software subscriptions....

      It's not as if virus writers are the anti-virus writers bread and butter.... oh wait... yeah they are.

  12. Not a worm by goldspider · · Score: 5, Informative
    "...and it still requires user intervention to infect."

    Then it's not a worm.

    --
    "Ask not what your country can do for you." --John F. Kennedy
    1. Re:Not a worm by cuzality · · Score: 2, Informative

      "A computer worm is a self-replicating computer program, similar to a computer virus. A virus attaches itself to, and becomes part of, another executable program; a worm is self-contained and does not need to be part of another program to propagate itself."

      Source: Wikipedia

  13. Re:Script kiddies becoming worse? by irokitt · · Score: 4, Funny
    Sounds like a strip kiddy tried to write a virus

    Strippers writing viruses? Sounds like a Fox special. And, being your typical Slashdotter without a girlfriend, I have to ask, do you have pictures?

    /grammar nazi
    --
    If my answers frighten you, stop asking scary questions.
  14. How does it do that? by GillBates0 · · Score: 5, Interesting
    Maybe this is a trivial question for l33t haxx0rz, but how would a program figure out it was running in a debugger? The register article doesn't explain this. Are the checks limited to a set of debuggers, which probably set a certain environment/variables which can be probed?

    One possible method I would probably use (off the top of my head) is to find out the time elapsed between executing two instructions - the time would be fairly high if the code were being singlestepped to.

    --
    An Indian-American Hindu committed to non-violent thought/speech/action alarmed by the global explosion of radical Islam
    1. Re:How does it do that? by JamesO · · Score: 5, Informative

      You hook the int 2 (?) and int 3 during the run, so your code gets called before the debugger's breakpoint handler, amongst other techniques.

      Have a look at this paper and be enlightened :)

    2. Re:How does it do that? by g0bshiTe · · Score: 4, Interesting

      The virus most likely makes use of the Windows API, in such a case the virus would just have to keep an eye on the memory, when it notices a BREAKPOINT set on a certain API call (which is usually never encountered on a normal computer, unless reversing) the program exits.

      There are tons of CRACKME's (small program written solely for people to crack or bypass) I have seen which look for debuggers and will exit if encountered.

      --
      I am Bennett Haselton! I am Bennett Haselton!
    3. Re:How does it do that? by beuges · · Score: 2, Informative

      From MSDN:

      IsDebuggerPresent

      The IsDebuggerPresent function determines whether the calling process is being debugged.

      BOOL IsDebuggerPresent(void);

      Parameters
      This function has no parameters.
      Return Values
      If the current process is running in the context of a debugger, the return value is nonzero.

      If the current process is not running in the context of a debugger, the return value is zero.

      Remarks
      This function allows an application to determine whether or not it is being debugged, so that it can modify its behavior. For example, an application could provide additional information using the OutputDebugString function if it is being debugged.

      To determine whether a remote process is being debugged, use the CheckRemoteDebuggerPresent function.

      To compile an application that uses this function, define the _WIN32_WINNT macro as 0x0400 or later. For more information, see Using the SDK Headers.

      Requirements
      Client: Included in Windows XP, Windows 2000 Professional, Windows NT Workstation 4.0, Windows Me, and Windows 98.
      Server: Included in Windows Server 2003, Windows 2000 Server, and Windows NT Server 4.0.
      Header: Declared in Winbase.h; include Windows.h.
      Library: Use Kernel32.lib.

    4. Re:How does it do that? by ryants · · Score: 5, Informative
      There are a couple of ways. Here's one that I took from "Building Secure Software". Debuggers tend to reset the processor instruction cache on every operation. Normally this doesn't happen except when a jump happens. So you can write code that changes instructions that should definitely be in the cache. If we're not running under the debugger, this has no effect, because the change doesn't cause the cache to refresh. Under a debugger, things can break:
      1 cli

      2 jmp lbl1

      lbl1:
      3 mov bx, offset lbl2

      4 move byte ptr cs:[bx], 0C3h

      lbl2:
      5 nop

      6 sti

      ; Continue normal operations here
      Commentary:

      1 Clear interrupt bit, so that code is sure to stay in the cache the entire time

      2 Causes CPU I cache to reload

      3 Store addr of lbl2

      4 Store a RET over the nop at lbl2 (0C3h = RET)

      5 nop to be clobbered only if under debugger

      6 Remove interrupt bit

      Of course you need to be a bit stealthier than this, but this is the basic idea.

      --

      Ryan T. Sammartino
      "Ancora imparo"

    5. Re:How does it do that? by StillAnonymous · · Score: 4, Interesting

      There are literally dozens of ways to check for the presence of debuggers. Some people have already mentioned some here. Here's a few more:

      Int68:

      MOV AH, 43h
      INT 68h
      CMP AX, 0F386h
      JZ FoundDebugger

      Check for SoftIce(most common/powerful debugger) by using the CreateFileA API to check for the SICE VXDs.

      And an interesting one found in the SafeDisc protection where(if I recall) they use a checksum of the GDT to decrypt a section of code. The debugger modifies this table and will cause the code to crash.

    6. Re:How does it do that? by vi+(editor) · · Score: 2, Informative

      This is a very stupid method (not for a virus of course...).
      If a processor uses a different cache updating scheme which updates the instruction cache upon writes into memory then your program won't run.
      You might argue that "this would be stupid processor design" or "not necessary for any decent processor to do this" - well, such methods were the reason why several copy (crack) protected old DOS programs won't run on Pentium computers. The method used there was exploiting the same effect with the instruction pipeline instead of the instruction cache. Some nops were overwritten with a ret or an interrupt call causing a program within a debugger to exit. However, the pipeline on the Pentium was either too small or a write triggered a refresh - I don't recall the actual details. So the program always exited.

    7. Re:How does it do that? by schabi · · Score: 2, Interesting

      Well, how can I toggle the interrupt bit in userspace? I presume this is only allowed when running in kernel mode (ring 0 on x86).

      --
      plim-plam-plompudding
    8. Re:How does it do that? by julesh · · Score: 2, Informative

      1. STI/CLI are priveleged instructions, so cannot be run by a windows process (other than a driver)

      2. This will only stop a debugger in single step. If the user spots what you're doing, they just put a breakpoint after this code and run through the whole section and it works fine.

    9. Re:How does it do that? by IamTheRealMike · · Score: 3, Interesting
      And an interesting one found in the SafeDisc protection where(if I recall) they use a checksum of the GDT to decrypt a section of code. The debugger modifies this table and will cause the code to crash.

      SafeDisc also loads a driver into the kernel which reads the debug register in the CPU. SafeDisc does a whole ton of clever things though, those guys really know their stuff, so I can well believe it hashes the GDT too.

      The most common techniques are checking for SoftIce (a very, very popular kernel level debugger) using a variety of techniques, google for "MeltIce" to see one I patched Wine to work with a few weeks ago, checking the x86 debug register, playing with interrupts, examining a Windows internal structure called the PEB, and so on... lots of devious tricks you can use.

  15. Ironic quote by mabu · · Score: 4, Insightful

    "I haven't seen such ruses used in a mass mailer in a long time. This piece of code is so sloppy, it's devious," said Mircea Ciubotariu, a researcher at Romanian AV firm BitDefender.

    Considering virus writers are more motivated by being devious than impressing analysts, doesn't it seem inappropriate to assume the coding was "sloppy?"

  16. what is it gonna be? by Anonymous Coward · · Score: 3, Insightful

    "This piece of code is so sloppy, it's devious," said Mircea Ciubotariu

    If it's intentional, it's not sloppy...
    If it's not intentional, it's not devious...

  17. "HER" code? by md358 · · Score: 4, Funny

    C'mon, *her* code? Isn't that a bit gratuitous? I mean, we're talking about code here, not a delicious turkey dinner.

  18. Sound familiar? by captnjameskirk · · Score: 5, Funny

    1) Contains a "bug", well let's just call it a "feature". 2) Sloppy code, but Hey! it works. Sort of. 3) Run on Windows only. Sounds like every piece of comercial software sold by Microsoft to me.

  19. More damaging. by khasim · · Score: 5, Insightful

    If the virus randomly changed a few numbers in a few of the Excel spreadsheets it could access.

    Damaging the computer itself is too easy to catch and causes people to take it seriously.

    Changing data has more implications for CORPORATIONS and would take longer to detect.

    1. Re:More damaging. by Anonymous Coward · · Score: 5, Interesting

      This comment should be Score:10

      It has been awhile since a virus actually *did* something real bad to screw a user.

      First Gen virii: Wipe hard drives, boot sectors, etc. For the most part, I haven't scene these for awhile...

      Second Gen virii: Zombie annoying spam/dos crap that is annoyingly hard to remove. Slows the computer down but most clueless users probably don't even notice until one of us comes to clean off the 200 or so spyware/spam virus crap they have on thier machine...)

      Next-gen: Random sentence inclusion into all word docs, change #'s in excel sheets, alter contents of address books, random data into access/sql databases.

      That sh*t would be brutal to deal with.

      Its one thing to know you have to restore from backups after a harddrive is wiped, or you just can't seem to shake the virus.

      Its a whole other ballgame when the virus goes undetected for a month and the excel sheets you've been conducting your business with have been screwed with. Yeah, you can restore and recreate a month's worth of work, but how do you account for the decisions you've made with bad data over the course of that month?

      Or even more fun, long documents you produce for meetings or public distribution. Embeded within are names harvested from your address book appended with a few choices words?

      "Our gross margins have increased by 12% this last quarter and Larry Teasdale is teh suck."

    2. Re:More damaging. by ArsenneLupin · · Score: 3, Insightful
      All this would still be way to tame. Why stop at corrupting data, when you can have way much more fun leaking it?

      Or even more fun, long documents you produce for meetings or public distribution. Embeded within are names harvested from your address book appended with a few choices words?

      Why not scan Word documents for names, and cross-reference those with your address book? As soon as a match is found, mail them said document. John Smith will surely be glad to learn that you intend to announce to him at next week's meeting that you'll fire him. Or ACME-soft will be pleased to learn that you are so dissatified with their service that you are shopping for a competitor ;-) But fore-warned is fore-armed. Endless fun!

    3. Re:More damaging. by The+Conductor · · Score: 2, Funny

      Wan't a smilar virs targete at slashcoe?

    4. Re:More damaging. by LWATCDR · · Score: 2

      How about a virus that randomly changes == to = in files :)

      --
      See my blog http://ilovecookes.blogspot.com/ for light hearted technical information.
    5. Re:More damaging. by nine-times · · Score: 5, Insightful
      'Next-gen: Random sentence inclusion into all word docs, change #'s in excel sheets, alter contents of address books, random data into access/sql databases.

      That sh*t would be brutal to deal with.

      Its one thing to know you have to restore from backups after a harddrive is wiped, or you just can't seem to shake the virus.

      Its a whole other ballgame when the virus goes undetected for a month and the excel sheets you've been conducting your business with have been screwed with. Yeah, you can restore and recreate a month's worth of work, but how do you account for the decisions you've made with bad data over the course of that month?'

      You're absolutely right, and I bet most people aren't taking what you're saying seriously enough. Do you know how many businesses keep track of things, even financial data, in just Excel spreadsheets? I mean, NO real paper trail, and even nothing clear to check the numbers against?

      Even when you're talking about corrupting data, it's one thing to delete a random letter from a word document- a spell-check will probably catch it. If a virus added a particular sentence to word documents (the same sentence each time), you can at least find out if the document has been corrupted by searching for that sentence. Even random sentences, which would be much harder to deal with, would be noticable when someone goes to read it. However, shifting individual numbers in an Excel document 10%, up or down, randomly? That could easily go unnoticed for a long time, and even when you go to the backups, how do you know you have retrieved an old enough version to be an uncorrupted version?

      The idea kind of reminds me of the Office Space/Superman III scheme of writing a virus that rounds down to the nearest cent and sends the excess to a bank account.

    6. Re:More damaging. by shopi · · Score: 2, Insightful
      How about not changing nor destroying documents, but *encrypting* them? Then you could extort those companies and goverments with your secret key.

      This is called "cryptovirology" and here is a really interesting book about it.

  20. Re:Hex it? by Short+Circuit · · Score: 2

    Sure, but they can't step through it. The virus detects the debugging environment and exits.

  21. Re:Okay...? by LowneWulf · · Score: 2, Informative

    The formal definition changes depending on who you ask, but in this case, the key attribute that defines this as a worm instead of a virus is that viruses embed themselves in other programs. This program doesn't infect other programs, it just runs as a separate program placed in your Windows\system directory.

  22. Elementary, my dear Watson... by bfg9000 · · Score: 5, Funny

    This piece of code is so sloppy, it's devious

    It shouldn't be hard to find the author, he obviously works at Microsoft.

    --

    I'm not normally an irrational zealous dickhead, but I figure "When in Rome..."

  23. Hack it by Manip · · Score: 2, Insightful

    It isn't that complicated to find the part of a code that causes a break in execution (end-point). So when it detects the debugger and breaks execution couldn't you reverse engineer it from that point and maybe write a mod (like a game crack) to avoid the debugger detection?

    This would allow the rest of the program to work as normal just without the self-defence code.

  24. Code sloppy? by g0bshiTe · · Score: 4, Insightful

    My guess is that they are so confounded, that by releasing that statement labelling the coding as sloppy they hope to draw the writer out in some way. Seems they are going for his/her ego.

    Because hey no coder legit or illicit wants to be thought of as a sloppy coder.

    --
    I am Bennett Haselton! I am Bennett Haselton!
  25. obscurity by double_ooh · · Score: 5, Funny

    The code is so bad that they can't read it, so it's insecurity through obscurity?

  26. Re:Hex it? by Jonboy+X · · Score: 5, Insightful

    Can't they break it down with a hex editor and see what's under the hood?

    Not really. It's kinda like looking at that blueprints to a race car. Even if you know every little bit of the thing, you don't really understand what it does or how it does it until you can take it out on the test track.

    Besides, looking at compiled code in a hex editor is kinda like looking at a jpeg in a hex editor. Maybe you see some interesting patterns, but it's tough to get the big picture.

    BTW, yes, it is bad analogy week here on Slashdot. Didn't you get the memo?

    --

    "In a 32-bit world, you're a 2-bit user. You've got your own newsgroup, alt.total.loser." -Weird Al
  27. Re:Hex it? by Anonymous Coward · · Score: 5, Insightful

    Apparently they want to run it in one of the "modern" debuggers. If the program manages to run through a few very simple tests, it'll detect it's in a debugger environment and can easily self-destruct.

    I did things like this years ago when fiddling around with a copy protection scheme. (Remember those days?) Trivial, really .. but they're right: I don't think things like that have been done in a while. Some vandal's been playing with the Way-Back Machine :-)

    If you really step through the code with a debugger, you can see the tests and traps (if you know what to look for) and avoid them. But that's tedious, to say the least.

    Obviously somebody at the virus scanner companies couldn't be bothered, and was impressed with or surprised by a lousy "debugger bit test".

  28. Finally! by teamhasnoi · · Score: 5, Funny
    Those DMCA violating virus 'terrorists' will be prevented from infringing the copyrights of the poor, disadvantaged virus writers.

    This content author has villified every artist who has ever had their work reverse engineered.

    This is a great day for copyright, authors, and those downtrodden by IP terrorists!

    1. Re:Finally! by Kissing+Crimson · · Score: 4, Interesting

      Mod parent up! This raises an excellent point: don't the AV companies daily violate the DMCA by reverse engineering virus code? If not, how long until somebody puts some kind of copy protection system into a virus and then sues all the AV companies? (I know, copy protection in a virus would be a bit odd, but hey...)

      --
      What's that smell? Ah, that's my karma burning...
    2. Re:Finally! by debrain · · Score: 3, Informative

      Viruses are not copyright; if they were the author would be admitting to a felony, where 1. s/he cannot benefit, and 2. they cannot claim possession of something illegal, ala. controlled substances. Copyright is, in essence, a form of constructive possession. A virus is like child porn, in that sense. It's worse to claim you own it than to argue for your possessory rights.

      Hope that makes sense. :)

    3. Re:Finally! by Alsee · · Score: 3, Informative

      Viruses are not copyright; if they were the author would be admitting to a felony

      The first half is absolutely false, and the second half could be false as well. Everything you create is automatically covered by copyright. And it is not a felony to create a virus, only to intend to release it. If you accidentally release it you might get nailed by civil suits (but not criminal ones), and if someone else released your virus without your permission you would not be subject to anything.

      There's a DMCA exemption to decrypt software, but only for interoperability purposes. There is also a DMCA exemption for law enforcement agents. However any non-law-enforcement agent decrypting a virus in an effort to combat it *would* be commiting a felony. The DMCA is seriously fuxored.

      Oh, and I just thought of something else. Commiting a felony by decrypting the virus is still commiting a felony even if the (criminal) author of the virus is unknown.

      -

      --
      - - You can't take something off the Internet! That's like trying to take pee out of a swimming pool.
    4. Re:Finally! by juhaz · · Score: 2, Insightful

      There are other examptions in DMCA than those two, virus research would probably be under the "Security testing" exception.

      This exception permits circumvention of access control measures, and the development of technological means for such circumvention, for the purpose of testing the security of a computer, computer system or computer network, with the authorization of its owner or operator.

    5. Re:Finally! by Alsee · · Score: 2, Interesting

      Hmm, interesting argument there but I don't think it would fly in this case.

      For purposes of this subsection, the term ''security testing'' means accessing a computer, computer system, or computer network

      You're not accessing a computer, computer system, or computer network. You are accessing the virus.

      The only way I can see it fit is if you are working on an already infected system and you attempt to argue that the virus is now part of your computer system. Chuckle. There's sort of a logic to it, but I'm not sure that would be accepted as the intent of that exemption.

      -

      --
      - - You can't take something off the Internet! That's like trying to take pee out of a swimming pool.
  29. Clarification, there are 2 issues by ItWasThem · · Score: 4, Informative

    Hopefully this clears up the "Is it sloppy or is it devious?" posts. It is both.

    Number 1 (from the article):
    Atak uses a variety of tactics in its attempts to escape antivirus analysis. Its main trick is to check to see if it's being run in a debugging environment. If so, it exits to avoid detection. The ploy prevents casual perusal of the code by researchers and (potentially) rival virus writers.
    So that part is intentional.

    A possible bug, related to the way Atak checks its activation date, prevents it from being run in a "sandbox". A sandbox is a virtual environment commonly used by AV researchers to look at the behaviour of malware in a safe environment.

    So what I think they are saying is that even with it's ability to detect if it's being run in debug mode they would still normally be able to run it in a sandbox. Unfortunately (for the AV companies) there's the second thing. The seemingly unintentional bug that prevents it from working in a virtual environment.

    1. Re:Clarification, there are 2 issues by mikael · · Score: 4, Funny

      The Good news: The virus writer has released a patch that fixes these two bugs

      The Bad news: You can't download these patches, you have to wait for them to self-install onto your system.

      --
      Vintage computer adverts: http://www.vintageadbrowser.com/computers-and-software-ads
  30. Re:AV software particularly effective? by Azrael+Newtype · · Score: 2, Insightful

    The talk of running in a sandbox enviornment was for AV software companies. They intentionally release viruses into a sandbox environment in order to figure out how they work to develop the countermeasures included in their updates. A regular user with AV software doesn't have a separate sandbox for running e-mail usually, so it'd install into the main system, and therefore infect, and the AV software wouldn't even see it, as it won't until they release new DAT files for whatever AVS you run.

    --
    I'm always right and I can prove it, because to the best of my knowledge, I've never been wrong.
  31. Hex Value Analysis by john.mull · · Score: 2, Funny

    Found embedded in the virus code... 56 42 56 63 72 69 70 74 20 72 6f 58 6f 72 7a 21

    --
    Isaiah 43:19 (NCV)
    Look at the new thing I am going to do. It is already happening. Don't you see it?
  32. Re:Hex it? by HappyClown · · Score: 5, Interesting
    There's plenty of ways they'll be able to analyse it eventually, the problem is just that the tools they normally use trip up so they'll have to resort to more painful approaches and it'll take them a lot longer to figure out exactly what is going on.

    Anti-debugging techniques have been in use for a long time. As an example, I remember attempting to reverse engineer some (ahem) commercial code about 15 years ago on x86 (MS-DOS). The first problem I hit was they'd replaced the keyboard interrupt (INT 9) with their own handler, so my debugger no longer responded to keypresses. After I worked around that I then discovered that they'd used the breakpoint interrupt (INT 3) to implement some critical functionality. Normal users would never even know, but as soon as you're in a debugging environment everything falls apart.

    To be fair, them replacing the keyboard handler wasn't an anti-debugging feature but it still had the same effect since it still rendered my debugger impotent. It sounds like this virus has a similar effect.

    Of course it wasn't long before the debuggers started to provide ways to overcome these types of problems, but it was always a constant game of leapfrog and I can't imagine much has changed.

  33. It's part of the API - From MSDN by soundman32 · · Score: 5, Informative

    IsDebuggerPresent
    The IsDebuggerPresent function indicates whether the calling process is running under the context of a debugger.
    This function is exported from KERNEL32.DLL.
    BOOL IsDebuggerPresent(VOID)
    Parameters This function has no parameters. Return Value If the current process is running in the context of a debugger, the return value is nonzero. If the current process is not running in the context of a debugger, the return value is zero. Remarks This function allows an application to determine whether or not it is being debugged, so that it can modify its behavior. For example, an application could provide additional information using the OutputDebugString function if it is being debugged.

    --
    No sharp objects, I'm a programmer!
    1. Re:It's part of the API - From MSDN by Kirth · · Score: 2, Interesting

      Ohmygod? And how is this IsDebuggerPresent set? I mean, could I write a debugger which does not set that? Or how is the kernel (or whatever kernel32.dll is) supposed to know a debugger is running?
      --

      --
      "The more prohibitions there are, The poorer the people will be" -- Lao Tse
  34. Stealth Worm??? by pandrijeczko · · Score: 4, Funny

    Isn't a "stealth worm" that requires "user intervention" a paradox?

    --
    Gentoo Linux - another day, another USE flag.
  35. Custom VMWare environment or hardware? by swb · · Score: 4, Insightful

    I'm kind of surprised that AV companies don't use custom VMware-type environments that can be debugged at a level above what the virus or any other processor could detect, or use special hardware/simulators that also can't be detected.

    I'd think this would give them greater granularity and more control over the entire environment than trying to just run in it in a standard debugger.

    1. Re:Custom VMWare environment or hardware? by swb · · Score: 2, Interesting

      There are some things that won't work without a full blown, isolated lab environment. I'm kinda supprised that the virus companies aren't using THAT setup already. Have everything install from images, and have 5 or so computers, and call it a day.

      That was probably their first step.

      I'd think the ultimate setup would be a high end machine with 8-16 CPUs capable of x86 virtualization that could be run a half-dozen or so images that would be virtually networked with each other.

      That way you could simulate a real network on real machines, including a server, clients, etc and see what happened. Even setting up and imaging a lab of 8 machines and a server would be time consuming.

      Doesn't anyone sell x86 virtualization on Sparc or IBM mainframe hardware?

    2. Re:Custom VMWare environment or hardware? by Chester+K · · Score: 3, Informative

      I'm kind of surprised that AV companies don't use custom VMware-type environments

      They do, but you can still tell whether your code is running in one of these environments if you're tricky enough. This is exactly the "sandbox" they're referring to.

      --

      NO CARRIER
    3. Re:Custom VMWare environment or hardware? by Alsee · · Score: 2, Insightful

      I think he means more advanced hardware that would be impossible to detect. Slave a CPU to an external master CPU. The master CPU would be completely invisible to the slave. All of the slave's registers and interrupts and RAM would be undetectable because they would be perfectly authentic. Give the master CPU total read/write access and the ability to single step the slave CPU's clock. The slave couldn't even detect timing anomolies because all extra processing would be done on the master CPU, plus the slave's clock itself could be undetectably paused - the actual CPU clock line.

      I assume Intel and AMD must already have almost exactly this sort of hardware available for development work.

      I guess the virus could then try to look to peripheral hardware for timing information, like video cards and harddrives. On one hand it would be a major pain for an AV company to accurately virtualize the timing in peripherals, but on the other hand the virus writer is facing unknown peripherals connected to an unknown system with wildly variable timings.

      -

      --
      - - You can't take something off the Internet! That's like trying to take pee out of a swimming pool.
  36. Re:Hex it? by micromoog · · Score: 4, Informative
    It's hard, but not impossible. To go with your first analogy, a skilled auto engineer WOULD be able to tell you many things about the real-world performance, based only on reading the blueprint.

    Unless the writer has gone to great lengths to obfuscate, a disassembler combined with a skilled x86 assembly programmer should be able to tell you all about what it does. Maybe the AV companies don't have those skills . . . methinks they should.

  37. It's New Coke! by blueZhift · · Score: 2, Insightful

    This reminds me of the whole New Coke thing years ago. Was it pure genius that Coke managed to sap Pepsi sales with the sweeter more Pepsi-like New Coke while hanging on to loyal customers with the reintroduced Coka Cola Classic, or was it a colossal blunder that they were just lucky enough to escape and still get ahead? Who knows? Unless the virus writer is caught, we may never know. Right now, I guess he or she is saying, "Yeah, I meant to do that!"

    In any case, I guess when it comes to virus writing sloppy coding pays off. And perhaps sloppy != stupid, unless of course you get caught! I suppose the next trick is for someone to release a code obfuscator that produces sloppy looking code.

    1. Re:It's New Coke! by Raffaello · · Score: 2, Interesting

      Nice try, but Coca Cola Classic (as well as most sodas) are made with "sugar and/or corn sweeteners." This means that the manufacturers use a pretty common linear programming technique to determine what ratio of the two different sweeteners to use in production on any given day based on commodities futures markets (remember, these guys actually take delivery of the futures contracts they buy), and transport costs.

      Just because corn sweeteners are cheaper today, doesn't mean that Coca Cola won't be able to buy a vast quantity of sugar at an even lower price due to commodities futures market fluctuations. They leave the door open by printing their labels with the "and/or" bit.

      BTW, did you know that Hershey uses so much sugar and cocoa that they have their own commodities futures trading room in house that specializes in these contracts?

  38. DCMA Violation! by Anonymous Coward · · Score: 5, Insightful

    Hey... If they reverse engineer this thing, won't they be violating the DCMA? I say the virus writer should sue all the anti-virus companies.

    By copying parts of the virus into their virus scanning signatures, perhaps everyone running the anti virus software is also violating the DCMA, I say fire off a few hundred law suits and see what happens.

    (Maybe with thinking like this RIAA will hire me.) ;-)

    1. Re:DCMA Violation! by DavidTC · · Score: 3, Interesting
      EULAs don't have anything to do with it...I didn't agree to any EULA on DVDs. The DMCA applies regardless. (Although it would be funny as hell to have an EULA with a virus...just wait till they're installing another program, and pop up a window that looks like that specific installer program (There are only about five.) with an EULA for your virus. Spyware, of course, already figured this out.)

      And, yes, someone should write a short bit of copyrighted work (I suggest a hiaku or limerick...those are definately protected under copyright law, and fairly small.), and encrypt it into a virus. If they ever get caught, possibly they can sue antivirus companies, because the antivirus company would probably admit to decoding their virus before they realized it was a trick.

      An even funnier gag would be to store the poem, unencrypted, on the hard drive, and have the virus prevent you from accessing it. Ergo, removing the virus is circumventing a access control device, and all antivirus software that does so is illegal.

      Yes, yes, the software could delete the poem, also, but we all know that deleting a file doesn't make it go away. (If deleting a file does count, someone should write a program that decodes DVDs, rips the MPEGs, and then just deletes them, so you have to go and immediately undelete them.) You could always recover it from the hard drive using undelete tools. So basically, they'd have to secure erase the poem...and I'm willing to bet no antivirus software has that built in, so if they realized what was going, at the very least you'd have forced an upgrade.

      And it's entirely likely that no one will realize what's going on. So if the virus writer ever gets caught, he can take the antivirus companies down with him by suing their pants off for distributing an access control circumvention device for his stuff.

      God, I love the DMCA. It's so monumentally stupid.

      --
      If corporations are people, aren't stockholders guilty of slavery?
  39. Yeah, 'sloppy'. by Vengeance · · Score: 2, Interesting

    Uh huh, that's what it was, sloppy coding that leads to one's new virus being very difficult to analyze and fight...

    --
    It was a joke! When you give me that look it was a joke.
  40. How does this equate to sloppy? by Anonymous Coward · · Score: 5, Insightful

    I don't understand... Why are they saying the code is sloppy? It seems to me that what they are doing is intentional. So it's not sloppy in the sense that it is full of mistakes.

    I also don't understand how stopping execution if your product is being debugged equates to "sloppy". It seems to me that a large number of software companies would WANT their software to behave in this way to make reverse engineering and hacking harder?

    In fact, if it is so difficult for antivirus companeis to debug this, when why isn't more software using this technique to make piracy more difficult, and/or hacking network games harder?

    1. Re:How does this equate to sloppy? by Ytsejam-03 · · Score: 2, Insightful
      I don't understand... Why are they saying the code is sloppy? It seems to me that what they are doing is intentional.
      This is a very short article, and I don't think that the author thought this behavior was due to sloppy code. Note the first two paragraphs:
      "There's a new mass mailing virus in town, and it's built to make life for AV researchers even more difficult.

      Atak uses a variety of tactics in its attempts to escape antivirus analysis. Its main trick is to check to see if it's being run in a debugging environment. If so, it exits to avoid detection. The ploy prevents casual perusal of the code by researchers and (potentially) rival virus writers."
      The reference to sloppy code is only is only made in the following quote from the article:
      "I haven't seen such ruses used in a mass mailer in a long time. This piece of code is so sloppy, it's devious," said Mircea Ciubotariu, a researcher at Romanian AV firm BitDefender.
      As another poster suggested, perhaps something got lost in the translation.

      While this may make the virus a little harder to analyze, I don't see how it would slow the anti-virus companies down much. Anti-virus researchers would simply need to change the code, disabling the section that checks to see if a debugger is attached. This is likely a simple matter of disassembling the code and changing the appropriate jump statement.
  41. EULA by Fuzzums · · Score: 5, Funny

    A viruswriter should add an EULA to his/her virus.

    - You may execute this virus 'as is'.

    - We accept no claims of any kind of any or all damage done by this piece of software.

    - You are responsible for the consequences of executing this software.

    - You are NOT allowed to disassemble the code (DCMA).

    - etc, etc..

    --
    Privacy is terrorism.
    1. Re:EULA by maxwell+demon · · Score: 3, Interesting

      Well, if that virus comes with a click-through EULA, which even explicitly tells about all the damages the virus will do, and have the "user" agree, it would probably give an interesting legal situation: After all, the user explicitly agreed to every single damage the virus does, by clicking the "I agree" button.

      --
      The Tao of math: The numbers you can count are not the real numbers.
  42. Re:Okay...? by darkmeridian · · Score: 3, Funny
    Of course, given the accuracy I've come to expect from Slashdot summaries, it could be a new version of MS IE...

    ...or a dupe.


    --
    This sig is inoffensive.
    --
    A NYC lawyer blogs. http://www.chuangblog.com/
  43. Simpson's adaptation by dfj225 · · Score: 3, Funny

    AV Guy: Man you are really sloppy! Virus Writer: Sloppy like a fox!

    --
    SIGFAULT
  44. Dear me, how remarkably fucking stupid. by devphil · · Score: 4, Insightful
    This function allows an application to determine whether or not it is being debugged, so that it can modify its behavior.

    We call those heisenbugs and they are the bane of a programmer's existence. The whole damn point of a debugger is to replicate the same behavior as normal, not allow the program to choose to exhibit a different behavior.

    "I'm going to look at you more closely now. Please act normal. (But it's your call if you don't.)"

    Yeah, that "surprise inspection" works great everywhere else, why not in programming? Fucking morons...

    I was happier not knowing about this function. soundman32, I shake my fist at thee. :-)

    --
    You cannot apply a technological solution to a sociological problem. (Edwards' Law)
  45. Re:Okay...? by ePhil_One · · Score: 4, Interesting
    viruses embed themselves in other programs.

    You're right.

    This program doesn't infect other programs, it just runs as a separate program placed in your Windows\system directory.

    Wouldn't that qualify it as a "Trojan Horse" then? Generally a Trojan Horse is a program that tricks the user into running by appearing as something it is not (hence the double extension trick). Of course the classic Trojan Horse appears to be one thing (like a weather program, or an clock syncronizer) but while it does that thing it secretly does something else, like install keyloggers, adware, etc.

    Admittedly, the AV makers have been trying to pollute the definitions, calling these e-mail Trojans "worms" in a PC attempt to avoid assigning blame to the users, but I've always felt these three definitions to be pretty clear and well defined.

    --
    You are in a maze of twisted little posts, all alike.
  46. Re:Hex it? by frenetic3 · · Score: 4, Informative
    I'm guessing it's a standalone EXE, and it would require some advanced knowledge, but you could create the process with the CREATE_SUSPENDED flag and then inject code to replace in the import table any API calls the virus uses to detect the debugging environment (I'm guessing the one they use is the simple IsDebuggerPresent() Win32 API call)

    This used to be a pretty heinous hack but seems well documented now; googling for the keywords:
    SetThreadContext ebp eip CreateProcess CREATE_SUSPENDED WriteProcessMemory
    will get you some interesting results and tutorials.

    * http://codeproject.com/system/api_spying_hack.asp
    * http://tochna.technion.ac.il/project/Win32APIInter ceptor/doc/Win32APIInterceptorNew.pdf

    Pretty cool shit.. anyway, the point is after you put a dummy IsDebuggerPresent that always returns false, you can step through it normally.

    Or, heh, a method that would probably be a million times easier would to simply step through the code until it calls IsDebuggerPresent and change the value of EAX to 0 after it returns (since the return value of functions is placed in EAX after return).

    Anyway, just musing and putting up those links because I learned a lot about how Windows internals work through playing with things like that and figured others might want to learn.

    -fren
    --
    "Where are we going, and why am I in this handbasket?"
  47. I knew it! by Stevyn · · Score: 5, Funny

    There is still a way to blame microsoft for this!!! I was getting a little worried there.

  48. Explain for non-programmers? by TubeSteak · · Score: 2, Informative
    Its main trick is to check to see if it's being run in a debugging environment. If so, it exits to avoid detection...

    A possible bug, related to the way Atak checks its activation date, prevents it from being run in a "sandbox"... "I haven't seen such ruses used in a mass mailer in a long time. This piece of code is so sloppy, it's devious"

    Does anybody have a theory (that they can explain in fairly simple terms) as to why it won't run in a sandbox? Wouldn't a windows session in VirtualPc etc. be indistinguishable from the real thing?

    Someone, anyone, clue me in to what's going on.

    --
    [Fuck Beta]
    o0t!
  49. Nothing new by Anonymous Coward · · Score: 4, Informative

    Viruses which could detect that they are being run in a debugger were common 10 years ago when I used to work for an anti-virus company. For example, One-Half is such a virus.

  50. Bug/sandbox? by julesh · · Score: 4, Insightful

    A possible bug, related to the way Atak checks its activation date, prevents it from being run in a "sandbox"

    Sounds more like a bug in the sandbox to me. A sandbox should be indistinguishable from running on a real non-virtualised computer.

  51. Re:You're missing the point by magefile · · Score: 2, Insightful

    Look, I disagree with the GP too, but your counterargument is bogus. First, many file systems (HFS, ext2-3 spring to mind) don't need debugging. Second, the warranty is set to just under the MTBF for a reason, and there's no tin-foil hat their - the companies will admit it, because there's nothing illegit or sneaky about it.

    OTOH, you have a group of largely unknown people writing viruses, and a group of people who profit off of their bad behavior. Besides, even if the AV companies didn't have a symbiotic relationship with the writers, why spark an arms race?

  52. Counterexample by Ungrounded+Lightning · · Score: 3, Interesting

    Highly damaging viruses don't spread far.

    Unless the damage is delayed and/or random.

    Big counterexample is AIDS:

    - Attacks the immune (i.e. antivirus) system directly.
    - Goes dormant until the infected cell is activated for other purposes.
    - Mutates "rapidly" for a virus (though slowly on reproductive cycle time scales), resulting in mutiple strains from a single infection after a few years.
    - Infects slowly enough that it doesn't create a tight cluster of infected individuals.

    This enables it to spread widely before the occasional activation of the immune system cells carrying it expand its infection in an exponential cascade taking out the doomed host.

    Birthday viruses / easter eggs are a simple mechanism to allow wide spread of computer viruses before they take out their hosts - and the hosts that are down at that time provide a reinfection reservoir. But it's primitive compared to AIDS.

    A highly damaging virus could be made which makes random choices on when to utterly trash its host.

    They aim for control, not damage. It's about money, not vandalism.

    Unfortunately, while there are several criminal enterpises spreading worms/trojans/viruses whose intent is to create DDoS zombies, spam remailers, or keylogger/filters looking for bank account access or other sensitive information, there are still plenty of virus authors chasing other things - including those who will vandalize machines for the fun of it.

    And there are power groups with significant membership whose agendas would be advanced by taking out as much as possible of the IT infrastructure of the world - the more widespread and more lasting the damage, the better for their purposes. A family of worms with AIDS-like properites would serve their interests nicely.

    Finally - while diseases evolve to be relatively benign, they do so randomly (and designed programs often don't do quite what was intended, especially on first release). Sometimes you get one that strikes a balance between spread and damage that results in a massive, widespread dieoff among the host populatin before the combined evolution of the disease and hosts contain its remanents. Classic example: Bubonic Plague.

    So let's not be lulled by analogies to the common cold and childhood diseases. They're the result of a lot of death and misery before the diseases found a stable niche. And while computer viruses share much of the math of disease spread they are designed, not evolved, and can easily have properties rarely seen in nature.

    --
    Bantam Dominique roosters crow a four-note song. Once you've heard it as "Happy BIRTHday" you can't NOT hear it that way
  53. Sloppy code? by wvitXpert · · Score: 5, Funny
    Atak worm cannot be analyzed or debugged by antivirus companies without quite a bit of work, due to the author being sloppy with his or her code.
    Hmmm... let me guess, the virus is written in such sloppy code that it just blends right in with the Windows code? ;^)
  54. Any debugger exploits? by Arakonfap · · Score: 2, Interesting

    This could be a pain if it evolves further - and that the virus writers figure out ways of exploiting the debuggers that are running. I'm not aware of any exploits for any debuggers - so that's good atleast!

  55. Re:Undetectable debuggers by The+Conductor · · Score: 3, Interesting

    It is not easy to make a software emulation of hardware that is exact without taking a huge performance hit. The processor, yes, but all that peripheral hardware is where the real emulation work is. Early versions of the UAE Amiga emulator emulated the video scan in the Amiga custom chips pixel-by-pixel, and it was so slow that UAE stood for "Useless Amiga Emulator." They later settled on refeshing the video on the (emulated) horizontal scanline flyback, which broke some exotic plasma-screen demos (which manipulated the palette in the middle of a scanline...try doing that on a PC!) but at least made UAE useful.

    Of course some partisan wankers had to write sofware that detected the emulation evironment & refused to run, apparently in the belief that emulation would kill the Amiga hardware market (not admitting that it was already cold & dead).

    What you describe can be done in hardware though, consisting of an FPGA + CPU board that plugs into the CPU socket and a communication cable to a separate debuggging PC. They are called In-Circuit Emulators (ICE) and are expensive, but very powerful, tools popular for embedded development.

  56. not by Moderation+abuser · · Score: 4, Interesting

    Hmm, scan word docs looking for legalese adding and removing the word "not" at appropriate points.

    should/will/must should/will/must not

    Fairly simple but that alone could cause some interesting effects on contracts etc. I'm sure there are other simple and more effective ways of changing the meaning of sentences which would require the re-reading of them by the authors to guarantee that the meaning is correct.

    --
    Government of the people, by corporate executives, for corporate profits.
  57. Re:I'm waiting... by DragonTHC · · Score: 2, Informative

    those already exist. they have for quite some time.

    --
    They're using their grammar skills there.
  58. You're assuming people would fix it... by rsilvergun · · Score: 5, Insightful

    most people don't fix their computers until they no longer work at all. A virus like this would have little impact on the computer. If it was well hidden enough, it wouldn't get fixed when the person call tech support for other problems either. The key is being quite and unintrusive right up till the end, then you lay waste to the computer.

    Frankly, I'm with the first poster. I good 'ole fashion hard disk reformatter would light some fires out there. I'm tired of seeing people with 5 or 6 viruses, uncountable spyware programs and everthing on their computer broken wanting the damn things fixed without a clean install because they don't know what a file is and have no idea how to back things up.

    --
    Hi! I make Firefox Plug-ins. Check 'em out @ https://addons.mozilla.org/en-US/firefox/addon/youtube-mp3-podcaster/
  59. Remember the old days by Eudial · · Score: 4, Informative

    Remember the old days of self modifying assembly code?

    (ie:
    instruction purpose
    1-20 alter instruction 21-40
    21-40 alter instruction 1-20, jump to 1
    1-20 do something
    21-40 alter 50-70 and 1-20
    50-70 do something, jump to 1-20)

    All alteration naturally is done in the most tricky of ways.

    Ah, those were the days.

    --
    GAAH! MY PRINTER IS ON FIRE!!! PUT IT OUT! PUT IT OUT!
    1. Re:Remember the old days by Gunstick · · Score: 2, Interesting

      hehe, and what about this:

      analyze CPU speed timings.
      install Xor crpyting interrupt routines 1, 2, 3 and 4
      routines 1 & 2 decrypt current instruction+2
      routines 3 & 4 encrypt current instruction-2

      the program has to run at exactly the right speed to be in sync with timers.

      Oh and the main program of course runs in trace mode, doing some fancy things at each instruction, so a debugger can't run.

      oh yeah... good old days :-)

      --
      Atari rules... ermm... ruled.
  60. What a bizzare statement by autopr0n · · Score: 3, Insightful

    It would seem that making a virus hard to debug/analize would be the hallmark of a well-written virus, not a poorly made one.

    I realize that 'easy to exicute' is a design goal of most software writers, but I'd think virus writers would want to focus on other things.

    --
    autopr0n is like, down and stuff.
  61. vindication by sacrilicious · · Score: 4, Funny
    the new Atak worm cannot be analyzed or debugged by antivirus companies without quite a bit of work, due to the author being sloppy with his or her code.

    See, this is what I've been trying to tell my boss: I'm not writing sloppy code, I'm trying to prevent people from reverse engineering our product!

    We visionaries are always persecuted.

    --
    - First they ignore you, then they laugh at you, then ???, then profit.
  62. TurboTax like virus? by hardaker · · Score: 3, Funny

    Gee... a virus that does things different when in a debugger or emulator? Sounds an aweful lot like a certain version of Turbotax about 2 years back... Do we have a prime suspect yet?

    --
    The next site to slashdot will be ready soon, but subscribers can beat the rush and start slashdotting it early!
  63. Re:Mailers? (Too much flash) by someone247356 · · Score: 3, Interesting

    Too much flash. Why go for Ebola when Mad Cow would be much more deadly and likely to be mistaken for Alzheimer's.

    That's the problem with viruses these days, too much flash. Either it saturates a network spreading itself, or it quickly kills the host. Either way it brings way too much attention to itself to be truly scary.

    How's this for a thought experiment;

    Write a small, stealthy piece of code that would randomly change a single digit in a single number found in a random Word or Excel etc. file by some small random amount once a day. It propagates by attaching portions of itself to no more than 1 email message/irc chat/telnet/ftp/video conference or other communication application a day. Until all of the pieces are present in memory, all the code does is attach itself to some systems process and look for the rest of itself. When all of it has been received it adds itself to some innocuous systems level process and begins changing values and slowly sending itself out around the world.

    So what good would that do? Well it doesn't draw attention to itself, neither in its mode of operation nor the way it spreads itself. Therefore while it would propagate slowly, no one would ever be looking for it. It's payload could cause great amounts of harm without ever giving the user any reason to think that his computer might be infected. What happens if it's on a pharmacy/hospital computer and it changes the dose of a prescription? Most pharmacies these days use numbers as a prescription ID. 20034978 might be a beneficial prescription while 20034879 could be deadly. We lost a Mars probe because someone didn't convert between feet and meters correctly. What if they did and a virus like this deftly changed it behind their back? A million widgets at $1.24 each is a lot different that a million widgets at $1.98. Building a bridge with a support beam that's 84.539 meters long isn't the same as one of 84.639 meters. You see where this is going don't you. Taken by themselves they look like simple user errors.

    The computer, or user, is diagnosed with Alzheimer's when it's actually infected with Creutzfeldt-Jakob. Machine's get rebuilt, people loose money, or get killed, and no one ever suspects that a very stealthy virus is the root cause of it all.

    That my friends is what I would call truly scary.

    someone247356

    --
    Just my $0.02 (Canadian, before taxes)