Submitted By: Ron Czapala

Lists Internet Explorer Security Zone settings.

Visual Basic
Option Explicit
  Const HKEY_CURRENT_USER = &H80000001
  Dim strComputer, oReg, strKeyPath, strValue, WSHShell, fso, ts, tmp, fname, result, TB, arrZone(44, 4), i, j, status
  status = array("Enable", "Prompt", "", "Disable")
  strComputer = "."
  strKeyPath = "Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\"
  Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\default:StdRegProv")

  Set WSHShell = WScript.CreateObject("WScript.Shell")
  Set fso = CreateObject("Scripting.FileSystemObject")
  tmp = fso.GetSpecialFolder(2)
  fname = fso.Buildpath(tmp, "IEZones.htm")
  fso.CreateTextFile fname, True, True
  Set result = fso.GetFile(fname)
  Set ts = result.OpenAsTextStream(2) 
  ts.write "<HTML><HEAD><TITLE>IE Zone Settings</TITLE></HEAD><BODY><TABLE border='1' style='FONT-SIZE: 12px; COLOR: #0000ff; FONT-FAMILY: verdana' width='100%'>"
  ts.write "<THEAD><TR><TH>Setting</TH><TH>MyComp</TH><TH>Intranet</TH><TH>Trusted</TH>" & _
  TB = loaddesc
  for i = 0 to 4
    for j = 0 to ubound(TB,1)
       oReg.GetDWORDValue HKEY_CURRENT_USER, strKeyPath &  i, TB(j,0), arrZone(j, i)  
  for j = 0 to ubound(TB,1)
    ts.write "<TR><TD>" & TB(j, 1) & "</TD>"  
    for i = 0 to 4
       tmp = arrZone(j, i)
       if instr("1A00 1C00 1E05", TB(j,0)) = 0 then
         if tmp < 4 then 
           tmp = status( tmp)
         end if
       end if
       ts.write "<TD>" &  tmp &  "&nbsp;</TD>" 
    ts.write "</TR>"
  ts.write "</TBODY></TABLE></BODY></HTML>"

WshShell.Run "iexplore.exe " & fname, 1, False

Function LoadDesc() 
  Dim TB(44, 1) 
  TB(0, 0)="2201"
  TB(0, 1)="Automatic prompting for ActiveX controls"
  TB(1, 0)="2000"
  TB(1, 1)="Binary and script behaviors"
  TB(2, 0)="1001"
  TB(2, 1)="Download signed ActiveX controls"
  TB(3, 0)="1004"
  TB(3, 1)="Download unsigned ActiveX controls"
  TB(4, 0)="1201"
  TB(4, 1)="Initialize and script ActiveX controls not marked as safe"
  TB(5, 0)="1200"
  TB(5, 1)="Run ActiveX controls and plug-ins"
  TB(6, 0)="1405"
  TB(6, 1)="Script ActiveX controls marked as safe for scripting"
  TB(7, 0)="2200"
  TB(7, 1)="Automatic prompting for file downloads"
  TB(8, 0)="1803"
  TB(8, 1)="File Download"
  TB(9, 0)="1604"
  TB(9, 1)="Font Download"
  TB(10, 0)="1C00"
  TB(10, 1)="Java permissions"
  TB(11, 0)="1406"
  TB(11, 1)="Access data sources across domains"
  TB(12, 0)="1608"
  TB(12, 1)="Allow META REFRESH"
  TB(13, 0)="1206"
  TB(13, 1)="Allow scripting of Internet Explorer Webbrowser control"
  TB(14, 0)="2102"
  TB(14, 1)="Allow script initiated windows without size or position constraints"
  TB(15, 0)="2300"
  TB(15, 1)="Allow web pages to use restricted protocols for active content"
  TB(16, 0)="1609"
  TB(16, 1)="Display mixed content"
  TB(17, 0)="1A04"
  TB(17, 1)="Don't prompt for client certificate selection when no certificates or only one certificate exists"
  TB(18, 0)="1802"
  TB(18, 1)="Drag and drop or copy and paste files"
  TB(19, 0)="1800"
  TB(19, 1)="Installation of desktop items"
  TB(20, 0)="1804"
  TB(20, 1)="Launching programs and files in an IFRAME"
  TB(21, 0)="1607"
  TB(21, 1)="Navigate sub-frames across different domains"
  TB(22, 0)="2100"
  TB(22, 1)="Open files based on content, not file extension"
  TB(23, 0)="1E05"
  TB(23, 1)="Software channel permissions"
  TB(24, 0)="1601"
  TB(24, 1)="Submit non-encrypted form data"
  TB(25, 0)="1809"
  TB(25, 1)="Use Pop-up Blocker"
  TB(26, 0)="1606"
  TB(26, 1)="Userdata persistence"
  TB(27, 0)="2101"
  TB(27, 1)="Web sites in less priveleged web content zone can navigate into this zone"
  TB(28, 0)="1400"
  TB(28, 1)="Active Scripting"
  TB(29, 0)="1407"
  TB(29, 1)="Allow paste operations via script"
  TB(30, 0)="1402"
  TB(30, 1)="Scripting of Java applets"
  TB(31, 0)="1A00"
  TB(31, 1)="Logon"
  TB(32, 0)="1A02"
  TB(32, 1)="Allow persistent cookies that are stored on your computer"
  TB(33, 0)="1A03"
  TB(33, 1)="Allow per-session cookies (not stored)"
  TB(34, 0)="1A05"
  TB(34, 1)="Allow 3rd party persistent cookies"
  TB(35, 0)="1A06"
  TB(35, 1)="Allow 3rd party session cookies"
  TB(36, 0)="1605"
  TB(36, 1)="Run Java"
  TB(37, 0)="1805"
  TB(37, 1)="Launching programs and files in webview"
  TB(38, 0)="1806"
  TB(38, 1)="Launching applications and unsafe files"
  TB(39, 0)="1A10"
  TB(39, 1)="Privacy Settings"
  TB(40, 0)="2001"
  TB(40, 1)="Run .NET components signed with Authenticode"
  TB(41, 0)="2004"
  TB(41, 1)="Run .NET components not signed with Authenticode"
  TB(42, 0)="1807"
  TB(42, 1)="Reserved - 1807"
  TB(43, 0)="1808"
  TB(43, 1)="Reserved - 1808"
  TB(44, 0)="1F00"
  TB(44, 1)="Reserved - 1F00"
  LoadDesc = TB
End Function