Locking down IE6
WSHShell.RegWrite "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2\1201", 0, "REG_DWORD"
WSHShell.RegWrite "HKLM\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\sagir.qc\implantation\https", 2, "REG_DWORD"
WSHShell.RegWrite "HKLM\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\sagir.qc\production\https", 2, "REG_DWORD"
WSHShell.RegWrite "HKLM\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\sagir.qc\gsprod\http", 2, "REG_DWORD"
0 Comments
[ + ] Show comments
Answers (1)
Please log in to answer
Posted by:
anonymous_9363
16 years ago
Francois, it looks OK to me. Why not use a lightweight snapshot tool (I use Ziff-Davis' In Control) to capture the changes on a workstation, to make sure? Alternatively, there's always the horse's mouth http://www.microsoft.com/technet/scriptcenter/resources/qanda/may05/hey0502.mspx
On a style note, you should get into the habit of using 'With/End With' and of "variable-ising" your code:
On a style note, you should get into the habit of using 'With/End With' and of "variable-ising" your code:
Const intTrustedZone = 2
Const strRegKey = "HKLM\Software\Microsoft\Windows\CurrentVersion\Internet Settings"
Const strDomainName = "sagir.qc"
With WSHShell
.RegWrite "HKLM\Software\Policies\Microsoft\Windows\CurrentVersion\Internet Settings\Security_HKLM_only", 1, "REG_DWORD"
.RegWrite strRegKey & "\Zones\" & intTrustedZone & "\1201", 0, "REG_DWORD"
.RegWrite strRegKey & "\ZoneMap\Domains\" & strDomainName & "\formation\https", intTrustedZone, "REG_DWORD"
.RegWrite strRegKey & "\ZoneMap\Domains\" & strDomainName & "\implantation\https", intTrustedZone, "REG_DWORD"
.RegWrite strRegKey & "\ZoneMap\Domains\" & strDomainName & "\production\https", intTrustedZone, "REG_DWORD"
.RegWrite strRegKey & "\ZoneMap\Domains\" & strDomainName & "\gsprod\http", intTrustedZone, "REG_DWORD"
End With
I know which I find easier to read.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.