Create eicar.com with notepad, by pasting (file should be 68 bytes)
X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*
Enable Avast
Run cmd.exe, go to eicar folder, type eicar.com
Eicar runs! Why is that?
You can try copying the file around also, but nothing happens (no warning, no copying, nor deleting the original file)
Did the exact same test on Avira free (in which is possible to pause on access scanning) and got an warning when trying to run eicar.com on command prompt
Well, it’s certainly not right - but it’s also not how avast! behaves on other computers.
Did you fully uninstall Avira before doing this, for example?
Only Avast was running when I did this tests. I uninstalled all antivirus software and installed a clean Avast Free (unless it remembers previous settings, but I don’t remember messing the settings before).
Now, I’ve just booted the PC, waited for everything to be started, and I was able to run eicar.com (in my desktop) with no warnings.
Then I decided to check the settings. File System Shield options were:
“Scan when executing” screen: all checked
“Scan when opening” screen: just “Scan Documents when opening” checked
Now, if I check “Scan all files” in the last screen, voilà: I receive an warning from Avast and eicar.com doesn’t run. But if I disable this option, I can run eicar.com again (I left half a dozen in my desktop for testing).
Is this the expected Avast free behaviour? It appears Avast free thinks eicar.com is a document, not a program (and a document type it shouldn’t verify). What are the default settings?
can’t really test that here, downloading the eicar file with fdm gives an Avast file system shield alert (and no need to turn on the “all files” setting), but turning the shields off, and downloading eicar.com, then run it from the command prompt or just clicking on it is a no go as it’s not recognized a valid extension on 64 bit Windows.
This may be completely unrelated but I’ll mention it anyways:
I went and tried out the eicar.com test (I’d never heard of it)
After double-clicking the file, avast! moved it to the virus chest.
I restored the file, clicked it again, same thing.
After restoring and running a third time, avast! and the command prompt kinda formed some sort of endless loop.
The command prompt will not go away, no matter what I do, and I cannot move the file to the chest or delete it.
If I clicked move to chest or delete, the threat warning would pop up again and again.
Though selecting block worked.
When I try this, without ‘Scan All files’ checked, I get an alert on the eicar file, but with the process ntvdm.exe (the Windows NT Virtual DOS Machine, the exectuable that runs 16 bit programs: http://en.wikipedia.org/wiki/Virtual_DOS_machine)
Possibly something relating to XP? (im using Vista for this)
Once eicar.com is successfully created (with avast disabled), I don’t have any alert when executing eicar.com.
However, when I copy eicar.com to other place, alert appears.
Did that. Then if I try to run eicar.com from cmd window I receive “Access is denied” and eicar is deleted. If I try running eicar from the desktop, the eicar file simply disappears. Either case there are no warning messages from Avast (though it is shown in shield traffic screen as the “last file infected”).
Ok, eicar.com prevented from running, but it feels somewhat strange…
- COM is not scanned on-open by default
- the execution of COM files is somewhat special (not really execution in the classical sense of Windows).
But don’t you think this could be exploited by an attacker? I mean, if you somehow manage to create a .com file in the target computer’s filesystem, you could run malicious code without any warning from Avast. (as long as it is a 32-bit OS)
If it were a normal (Windows) executable it would get scanned on-exec not matter what the filename extension is.
The problem is caused by the fact that Eicar is not a Windows executable file.
Unfortunately, the eicar test is the only one I know it’s safe to try :-\ If I were to test with real infected files, I should do it in a controlled environment.
Besides that, Avira free passed this exact same test.