Home > Security Tips > Threat Monitor > How to remove the Blaster registry key through scripting
Security Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

THREAT MONITOR

How to remove the Blaster registry key through scripting


Joel Johnson, SearchSecurity.com Expert
08.18.2003
Rating: -4.55- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


This handy WMI script can be called from your login scripts to clean up the Blaster registry key. Of course, you may want to add a Reg backup line to backup the registry first.

The basics behind this script are pretty simple. The first five lines lay out the standard Windows registry tree. The next five lines define what we are looking for. The "." stands for local computer. If you want to target a single computer you can add that computer name instead of the ".". The "SMethod" means we are using the "Delete Value" command. The next two lines lay out the location of the value we are looking for. And finally the "SValue" is the value that nasty Blaster added to user registries. The rest of the script calls the variables we just defined.

You can run this within netlogon and save yourself valuable cleanup time.


Const HKEY_CLASSES_ROOT  = &H80000000
Const HKEY_CURRENT_USER  = &H80000001
Const HKEY_Local_Machine  = &H80000002
Const HKEY_Users   = &H80000003
Const HKEY_Current_Config  = &H80000005

sComputer  = "."
sMethod  = "DeleteValue"
hTree   = HKEY_Local_Machine
sKey   = "SoftwareMicrosoftWindowsCurrentVersionRun"
sValueName  = "windows auto update"

Set oRegistry  = GetObject("winmgmts:{impersonationLevel=impersonate}//" & _
   sComputer & "/root/default:StdRegProv")

Set oMethod  = oRegistry.Methods_(sMethod)
Set oInParam  = oMethod.inParameters.SpawnInstance_()

oInParam.hDefKey = hTree
oInParam.sSubKeyName = sKey
oInParam.sValueName = sValueName

Set oOutParam = oRegistry.ExecMethod_(sMethod, oInParam)


Rate this Tip
To rate tips, you must be a member of SearchSecurity.com.
Register now to start rating these tips. Log in if you are already a member.




Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


RELATED CONTENT
Tech Tips
Video: The foundation of an email security strategy
Biometric authentication know-how: Devices, systems and implementation
The 5 A's of functional SAN security
Effective storage security policies
Smart options for safeguarding stored data
Outfox SOX: How to make regulations work for you
Thwarting Hacker Techniques: Signs of a compromised system
Thwarting Hacker Techniques: Wireless security basics
Thwarting Hacker Techniques: Internet data manipulation
Thwarting Hacker Techniques: Securing remote access points

Threat Monitor
How to prevent clickjacking attacks with security policy, not technology
How to stop malware in a 'Flash'
How to detect system management mode (SMM) rootkits
Windows registry forensics: Investigating system-wide settings
Weaponizing Kaminsky's DNS discovery
Debian: A niche OS with a not-so-niche security flaw
Web advertising exploits: Protecting Web browsers and servers
Ransomware: How to deal with advanced encryption algorithms
Hidden endpoints: Mitigating the threat of non-traditional network devices
Protecting exposed servers from Google hacks (and Google 'dorks')

Common Vulnerabilities and Prevention Tips
What's your infosec IQ?
IE update clears up spoofing issue
Countdown begins for Mydoom DDoS attacks
Microsoft to disable spoofing syntax in IE
IE flaw could fool users in illicit downloads
Mydoom variant targets security features, Microsoft
Hackers scanning for ports opened by Mydoom
Dangerous, familiar application vulnerabilities top list
Potent Mydoom worm flooding inboxes
Worm opens two backdoors, logs keystrokes

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary

DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



Research Solutions for Network Security, Access Control and Security Threats
More Security Resources for Resellers, VARs and OEMs
TechTarget Security Media
Information Security View this month\\'s issue and subscribe today.
Information Security Decisions Apply online for free conference admission.
SearchSecurity.com
HomeNewsMagazineMultimediaWhite PapersLearningAdviceTopicsEventsAbout Us

About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
TechTarget provides enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 2003 - 2009, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts