Tuesday 24 July 2007

Calling the DOS Format command without prompting the user to confirm

NOTE: This is only for experienced users. This disk formatting method does not prompt a confirmation before the data is wiped out on your drive. USE WITH CAUTION!!!

While writing some Perl test scripts at work, which need drives and partitions to be created and formatted, I hit a road block. When I issued the format command to format a partition, the console running the script kept hanging. After some pondering, I realised that the format command had a safety mechanism, which warned the user that data could be lost and required a user confirmation to proceed with the format. This is a problem while developing automation scripts because the user cannot be expected to be sitting at the console waiting for each and every confirmation prompt by format command. Even so, there was no optional flag which could be specified together with the format command, which would allow it to run without requiring the user to confirm to proceed with the format. This was a problem which I had never faced before. Now, how would I be able to provide the confirmation input without the script hanging?

An idea came to my mind. Now, this idea was neither a stroke of luck, nor was it my experinece in programming. Instead, it was my knowledge in DOS batch file programming. All I had to do was pipe the format command with an echo command. Sounds jibberish? Not at all... Here is how it can be done.

echo y ¦ format :

The "y" is a YES to confirm that the format should proceed. This way

Simple eh? Absolutely! But my brain was chewing on this for over 6 hours, before it even dawned to me that it was not for the script to resolve, but instead the console command which the script had to issue.

Monday 23 July 2007

QuickTime player displays purple/green screen when playing videos

For the past 8 months now, I have been trying to use my QuickTime player to view the trailers that I download from "Dave's Trailer Pages". However, when I open the downloaded .mov file, I only get a purple screen (sometimes flickering purple and green). I was on the verge of giving up on the QuickTime player, when I decided to Google my problem for the last time yesterday.

I found an article that addressed a similar problem. I just thought to myself, "Well, what the heck, I have come so far, it would not hurt to try this out, before actually throwing the QuickTime player out of my system". Lo and behold, it worked. WOOOO HOOOOO!!! Three cheers to the guy who provided the solution. It was simple, yet, not obvious.

Here is how the problem was resolved.

1. On the QuickTime player menu, click "Edit" -> "Player Preferences..."
2. On the "Advanced" tab, in the "Video" section, UN-CHECK the box for "Enable Direct3D video acceleration"
3. Then just shutdown the player and re-start it.
4. If that does not work, try disabling DirectX in QuickTime by selecting "Safe mode (GDI only)"

I stopped at Step 3 and did not have to perform Step 4. Now, finally, QuickTime player is back up and running for me.

Sunday 22 July 2007

Damn virus... Infected by BackDoor-CVT trojan

This is the second virus attack I have had in 2 months. The first was the Vundo trojan, which was an absolute nightmare to clean.

Today, out of the blues, my McAfee virus scan caught the BackDoor-CVT trojan. A message sprang up stating that the "C:\Windows\system32\winmmt32.dll" file contained the BackDoor-CVT virus. I clicked the "Clean", "Delete" and "Quarantine" buttons, but McAfee displayed a message that the file was locked and that it could not clean it. Within me, I just thought, "Not another freaking virus that I have to suffer to get rid of". I literally felt like smashing my PC with a sledge hammer. Then the thought of buying a new hard disk and re-installing XP flew through my thouught, which seemed to be a more possible solution, costly but possible.

Patiently I waded through the almighty Google using various search string... "BackDoor-CVT", "winmmt32.dll", "how to clean winmmt32.dll BackDoor-CVT". I came across many articles, all with multiple ways to kill this damn thing. One guy even said "Why do idiots have to make these things ? What a pain.", and another guy responded, "I'm afraid its human nature". How true... bloody @r$e.

Fortunately, I managed to clean the BackDoor-CVT trojan much faster than the damned Vundo trojan. Bless the souls out there who have shared their problems and also bless the folks who have guided, advised and showed us the way to get rid of these pests.

I feel that it is important to share what I learn with others who might be (some day in the future) going through the similar problem. Well, here's how I managed to kill this muther funster of a trojan.
1. Run HijackThis
2. Put a check next to this entry:
O20 - Winlogon Notify: winmmt32 - C:\WINDOWS\SYSTEM32\winmmt32.dll
3. Click "Fix Checked"
4. Then download
Killbox
5. Select the "Delete on Reboot" option.
6. Enter the file name below:
C:\WINDOWS\SYSTEM32\winmmt32.dll
7. Click the red-and-white X button, which is the "Delete File" button.

8. Click "Yes" at the "Delete on Reboot" prompt.
9. Click "No" at the Pending Operations prompt.
NOTE: If the computer doesn't restart, just restart manually.

Monday 16 July 2007

IE7 crashes when a drop-down menu is clicked

Microsoft in action again!!! Some websites use pull down menus as a means of navigation/selection of options. However, when using IE7, some drop-down menus, when clicked, will result in the application shutting down.

You could find the problem in the link below.
http://jtbworld.blogspot.com/2007/05/ie7-crashes-when-clicking-on-drop-down.html

I have been struggling with this problem 'cos whenever I access my bank account, and click on the drop-down menu to select the account to view, IE7 shuts down abruptly. ARGHHHH!!!! I would end up using FireFox to actually perform the banking transaction. I know, I know... I could have just used FireFox from the start. But... ahhh, nevermind, I am not going to be explaining myself.

Finally, after 3 months, I have found the fix, which was not really obvious. Thanks to Microsoft for the fix, but at the same time, no thanks to them either because the title for the fix on their support page does not describe the problem. I suppose, the title addresses the fix for a different issue, which is related to the drop-down menu selection issue.

If any of you are facing the same problem, here is how you can fix it.

DISCLAIMER: I am in no way responsible if the instructions below screw-up your machine. Even though the instructions below rectified the problem I was facing, follow the steps at your own risk.

WORKAROUND
Warning Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall the operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

To work around this problem, use the windowed SELECT control. To do this, follow these steps:
1. Click Start, click Run, type regedit in the Open box, and then click OK.
2. Locate the following registry subkey, and then click the following registry subkey:
HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_USE_WINDOWEDSELECTCONTROL
Note: If you cannot locate the FEATURE_USE_WINDOWEDSELECTCONTROL key, create the FEATURE_USE_WINDOWEDSELECTCONTROL key under the FeatureControl key.
3. On the Edit menu, point to New, and then click DWORD Value.
4. Type Iexplore.exe, and then press ENTER.
5. Right-click Iexplore.exe, and then click Modify.
6. In the Value data box, type 1, and then click OK.
7. Exit Registry Editor.

Here's the Microsoft support page containing the full article, including the steps above.
http://support.microsoft.com/default.aspx/kb/936953

There you have it... Now, fix and ENJOY!!!

Saturday 9 June 2007

When one is struck down with a persistent, annoying virus

Oh, let me say it out loud... Trojan.Vundo IS A BLOODY ANNOYING VIRUS!!!

My PC was infected with this damned virus last week, and only after a long and hard process was I able to fix it. The fix, as I discovered the hard way, was simple. But the process of finding the fix was torturous.

Thanks to a kind soul who has made a post on a public forum, I managed to get this annoying virus out of my system.

What does Trojan.Vundo do? The moment an internet connection is established, it keeps popping up ads on the web browser.

I'm sure you are asking what so difficult about cleaning this, it is a mere adware that needs something like AdAware or Spybot to clean. It is not that simple, my friend. The virus adds some entries to the registry, and also copies some files (usually some DLLs, but I have found other extensions as well), which are randomly named, into the PC (mainly into the C:\windows\system32 directory). Once it is there, it loads itself up. The anti-virus software is able to detect the virus when it decides to show itself, but the dll is not able to be deleted because the file is locked (since it is a running process).

Your immediate reaction would be to clean the registry of the offending entries and stop the process and delete the dll. Once again, it is easier said that done. If you have file sharing on, this is the breeding ground of this virus. Before starting any cleaning attempt, my suggestion to any of you would be to disable the following:

  1. System Restore (sorry, it just has to be done cos restoring the system to an earlier snapshot will not kill off this virus)
  2. Stop all forms of file and printer sharing (2 primary steps for this need to be done)


Once you are done with the steps above, proceed to fix it using the link below.

If any of you are affected with the Trojan.Vundo or Trojan.Vundo.B virus, the cleaning process can be found here:
http://www.bleepingcomputer.com/forums/topic18610.html


Well, at least, I can enjoy the weekend surfing and downloading all the crap I want without having the annoying pop-ups streaming in. ;)