Join the forum, it's quick and easy

Would you like to react to this message? Create an account in a few clicks or log in to continue.
Log in

I forgot my password

Alumni of BSU INFORMATION TECHNOLOGY

BSU INFO-TECH

FB COMMENT

simple Visual Basic Script to Re enable Registry Editing

Go down

simple Visual Basic Script to Re enable Registry Editing Empty simple Visual Basic Script to Re enable Registry Editing

Post by Generym Thu 09 Sep 2010, 6:55 am

A simple Visual Basic Script to Re enable Registry Editing after a trojan/worm had broken into your system. Just double click it and it will enable regeditor again. To disable, double click it again. Parang On and Off switch lang sya.

Here is the script. just copy and paste on a notepad then save as .vbs


'Enable/Disable Registry Editing tools

Option Explicit
'Declare variables
Dim WSHShell, rr, rr2, MyBox, val, val2, ttl, toggle
Dim jobfunc, itemtype

On Error Resume Next

Set WSHShell = WScript.CreateObject("WScript.Shell")
val = "HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\System\DisableRegistryTools"
val2 = "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System\DisableRegistryTools"
itemtype = "REG_DWORD"
jobfunc = "Registry Editing Tools are now "
ttl = "Result"

'reads the registry key value.
rr = WSHShell.RegRead (val)
rr2 = WSHShell.RegRead (val2)

toggle=1
If (rr=1 or rr2=1) Then toggle=0

If toggle = 1 Then
WSHShell.RegWrite val, 1, itemtype
WSHShell.RegWrite val2, 1, itemtype
Mybox = MsgBox(jobfunc & "disabled.", 4096, ttl)
Else
WSHShell.RegDelete val
WSHShell.RegDelete val2
Mybox = MsgBox(jobfunc & "enabled.", 4096, ttl)
End If
Generym
Generym
Admin
Admin

Male
Number of posts : 260
Reputation : 1
Registration date : 2008-11-12

https://bsu-infotech.forumotion.com

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum