Jump to content
escalation666

anti xp firewall vbs script

Recommended Posts

Posted

'******************************************************************************

'FwDisable.vbs

'Author: Peter Costantini, The Microsoft Scripting Guys

'Date: 9/2/04

'Version: 1.0

'Disables Windows Firewall, which is enabled by default on XP SP2.

'******************************************************************************

On Error Resume Next

'Create the firewall manager object.

Set objFwMgr = CreateObject("HNetCfg.FwMgr")

If Err <> 0 Then

WScript.Echo "Unable to connect to Windows Firewall."

WScript.Quit

End If

'Get the current profile for the local firewall policy.

Set objProfile = objFwMgr.LocalPolicy.CurrentProfile

'Is firewall enabled?

If objProfile.FirewallEnabled = True Then

'Disable it.

objProfile.FirewallEnabled = False

End If

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...