john pfeiffer
  • Home
  • Categories
  • Tags
  • Archives

Ie trust sites.vbs

REM John Pfeiffer 06feb08 adapted from MS website
REM add trusted sites: http://wesbsite1, http://website2
REM to registry of current user (whole computer?)

REM On Error Resume Next
REM const HKEY_LOCAL_MACHINE = &H80000002
Const HKEY_CURRENT_USER = &H80000001

strComputer = "."
Set objReg = GetObject("winmgmts:" _
    & "{impersonationLevel=impersonate}\\" & strComputer & _
        "\root\default:StdRegProv")

REM Add a website to the Special Domains list (trusted?)
strKeyPath = "Software\Microsoft\Windows\CurrentVersion\Internet Settings\" _
    & "ZoneMap\Domains\website1"
objReg.CreateKey HKEY_CURRENT_USER,strKeyPath
strValueName = "http"
dwValue = 2
objReg.SetDWORDValue HKEY_CURRENT_USER,strKeyPath,strValueName,dwValue

REM ActiveX controls & plugins: Download signed (permitted)
strKeyPath = "Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2"
strValueName="1001"
dwValue = 0  
objReg.SetDWORDValue HKEY_CURRENT_USER, strKeyPath, strValueNAme, dwValue

REM ActiveX controls & plugins: Download unsigned (permitted)
strKeyPath = "Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2"
strValueName="1004"
dwValue = 0  
objReg.SetDWORDValue HKEY_CURRENT_USER, strKeyPath, strValueNAme, dwValue

REM User Authentication: Logon (prompt)
strKeyPath = "Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2"
strValueName="1A00"
dwValue = 0
objReg.SetDWORDValue HKEY_CURRENT_USER, strKeyPath, strValueNAme, dwValue


REM oReg.DeleteKey HKEY_LOCAL_MACHINE, strKeyPath
REM objReg.CreateKey HKEY_CURRENT_USER,strKeyPath


REM http://support.microsoft.com/kb/q182569/
REM http://www.activexperts.com/activmonitor/windowsmanagement/adminscripts/registry/

REM ZONES   
REM 0        My Computer
REM 1        Local Intranet Zone
REM 2        Trusted sites Zone  
REM 3        Internet Zone
REM 4        Restricted Sites Zone

REM each DWORD value is equal to 0 (permitted), 1 (prompt), 3 (denied).

REM What values for Minlevel, RecommendedLevel, and CurrentLevel mean the following: 
REM Value (Hexadecimal)        Setting
REM ----------------------------------
REM 0x00010000         Low Security
REM 0x00010500         Medium Low Security
REM 0x00011000         Medium Security
REM 0x00012000         High Security

REM 1A00    User Authentication: Logon          
REM 0x30000 196608 Anonymous Logon    
REM 0x20000 131072 Automatic logon only in Intranet Zone
REM 0x00000 Automatic logon with current username and password
REM 0x10000 65536 Prompt for username and password

  • « Input box sleep.vbs
  • Filter.vbs »

Published

Feb 6, 2010

Category

bat-vbs-perl

~233 words

Tags

  • bat-vbs-perl 51
  • ie 2
  • sites.vbs 1
  • trust 2