批处理添加信任网站 启用ActiveX 关闭弹窗阻止
批处理添加信任网站启用ActiveX 关闭弹窗阻止
rem 将以下保存到添加信任网站.bat 文件
rem 创建自解压文件,将此添加信任网站.bat文件解压到%USERPROFILE%\Favorites\办公网站\ 下(C盘根目录有时不可写)
rem 受信站点配置开始
rem datong
reg add
"HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\https://www.360docs.net/doc/ef10571269.html," /v http /t REG_DWORD /d
0x00000002 /f
rem 受信站点配置结束
rem 主页
reg add "HKCU\Software\Microsoft\Internet Explorer\Main" /v "Start Page" /t REG_SZ /d https://www.360docs.net/doc/ef10571269.html, /f
reg add "HKCU\Software\Microsoft\Internet Explorer\Main" /v "Secondary Start Pages" /t REG_SZ /d https://www.360docs.net/doc/ef10571269.html,//f
del fosoft.reg
echo Windows Registry Editor Version 5.00 >> fosoft.reg
rem Activex配置开始
echo [hkey_current_user\software\microsoft\windows\currentversion\internet settings\Zones\2] >> fosoft.reg
echo "1001"=dword:00000000 >> fosoft.reg
echo [hkey_current_user\software\microsoft\windows\currentversion\internet settings\Zones\2] >> fosoft.reg
echo "1004"=dword:00000000 >> fosoft.reg
echo [hkey_current_user\software\microsoft\windows\currentversion\internet settings\Zones\2] >> fosoft.reg
echo "1200"=dword:00000000 >> fosoft.reg
echo [hkey_current_user\software\microsoft\windows\currentversion\internet settings\Zones\2] >> fosoft.reg
echo "1201"=dword:00000000 >> fosoft.reg
echo [hkey_current_user\software\microsoft\windows\currentversion\internet settings\Zones\2] >> fosoft.reg
echo "1405"=dword:00000000 >> fosoft.reg
echo [hkey_current_user\software\microsoft\windows\currentversion\internet settings\Zones\2]
echo "1206"=dword:00000000
echo [hkey_current_user\software\microsoft\windows\currentversion\internet settings\Zones\2] >> fosoft.reg
echo "2201"=dword:00000000 >> fosoft.reg
rem Activex配置结束
rem 受信站点配置开始
@rem echo
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\56.789 ] >> fosoft.reg
@rem echo
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\56.789\192.168] >> fosoft.reg
@rem echo "http"=dword:00000002 >> fosoft.reg
@rem 受信站点配置结束
rem 弹出窗口配置开始
echo [HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows] >>fosoft.reg
echo "PopupMgr"="no" >>fosoft.reg
rem 弹出窗口配置结束
regedit /s %USERPROFILE%\Favorites\办公网站\fosoft.reg
rem regedit %USERPROFILE%\Favorites\办公网站\fosoft.reg
del fosoft.reg
del 添加信任网站.bat
参考资料:
有没有一个批处理将指定的网址设为主页?谢谢!
@echo off
reg add "HKCU\Software\Microsoft\Internet Explorer\Main" /v "Start Page" /t REG_SZ /d https://www.360docs.net/doc/ef10571269.html, /f
pause
设置为百度的,具体网纸你自己改下就行了。楼主是想学习批处理改注册表吧。
这样也可以
@echo off
set /p name=请输入你要设置为主页的网址:
reg add "HKCU\Software\Microsoft\Internet Explorer\Main" /v "Start Page" /t REG_SZ /d %name% /f
pause
来源:
利用批处理添加受信任站点
(2008-12-17 13:18:30)
转载▼
标签:
杂谈
比如说我们要把https://www.360docs.net/doc/ef10571269.html, https://www.360docs.net/doc/ef10571269.html, *https://www.360docs.net/doc/ef10571269.html,添加到客户的受信任站点蓝色部分后面有www(https://www.360docs.net/doc/ef10571269.html,\www)的为https://www.360docs.net/doc/ef10571269.html, 不加的话默认为* 例:*https://www.360docs.net/doc/ef10571269.html,
"红色部分为可修改的协议:
例如:"http","ftp"等其它名称。
代码如下:
reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\https://www.360docs.net/doc/ef10571269.html,"
reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\https://www.360docs.net/doc/ef10571269.html,\www" /v http /t REG_DWORD /d 0x00000002 /f
reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\https://www.360docs.net/doc/ef10571269.html,\picasaweb" /v http /t REG_DWORD /d 0x00000002 /f reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\https://www.360docs.net/doc/ef10571269.html,\" /v https /t REG_DWORD /d 0x00000002 /f
以上代码保存为*.bat文件。
来源:
利用批处理修改注册表,实现加入到可信任站点,ActiveX相关设置均改成“启用”
Windows Registry Editor Version 5.00
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap]
@=""
"proxybypass"=dword:00000001
"intranetname"=dword:00000001
"uncasintranet"=dword:00000001
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\domains]
@=""
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\EscDomains\https://www.360docs.net/doc/ef10571269.html,]
注:https://www.360docs.net/doc/ef10571269.html,为你要加入可信任站点里的某网站域名,去掉前面的主机头如www,oa.....等[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\EscDomains\https://www.360docs.net/doc/ef10571269.html,\www]
注:把主机头加入进去,如www.xxxcom中,把www加入;如果是https://www.360docs.net/doc/ef10571269.html,,则上面变成[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\EscDomains\https://www.360docs.net/doc/ef10571269.html,\oa]
"http"=dword:00000002
注:加入http头进去
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\EscRanges\range9]
":Range"="222.222.222.222"
"http"=dword:00000002
注:如果没有域名的话,把IP地址加入信任站点,信息存储在
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\EscRanges下,它是以range1,range2......依次递增。如果不知道目前排多少位,则直接加入一个比较大的数据,如示例中加入…range9?
":Range"="222.222.222.222" 其中222.222.222.222为要加入的IP地址
"http"=dword:00000002
上面就是如何把一个网站的域名或者IP地址加入到可信任站点中
下面是介绍如何把一个信任站点的自定义级别中,关于ActiveX相关设置均改成…启用?
====================================================== =========
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"1001"=dword:00000000
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"1004"=dword:00000000
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"1200"=dword:00000000
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"1201"=dword:00000000
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"1206"=dword:00000000
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"1405"=dword:00000000
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"1406"=dword:00000000
其中,dword的值为00000000 为…启用?; 00000001 为…提示?; 00000000为…禁用?
下面是对可信站点是否启用…对该区域中的所有站点要求服务器验证(https)(s)进行设置====================================================== ============
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\Zones\2]
"flags"=dword:00000043
其中,dword:00000043 表示启用,即勾选上
dword:00000047 表示不启用,去掉复选项里面的对勾
--------------------------------------------------------------------------------------------------------------------
************************************************************************ *****
注:上面是在win2003 Server操作系统上实现!
在WinXP系统上,
把网址域名加入信任站点
[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\EscDomains\https://www.360docs.net/doc/ef10571269.html,] 把EscDomains改为Domains
把IP地址加入注册表实现方法是这样(示例IP:000.123.456.789)
[[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\Domains\456.789 最后两位数字
[[hkey_current_user\software\microsoft\windows\currentversion\internet
settings\zonemap\Domains\456.789\000.123 前两位数字
"http"=dword:00000002
来源:
修改注册表添加信任站点及启用Activex控件(转载)
////////////////////////////////////////////////////////////////////////
//
// 添加信息站点及将指定IP添加到本地Intranet中,
// "*"=dword:00000002 表示受信任的站点区域
// "*"=dword:00000001 表示本地Intranet 区域
//
////////////////////////////////////////////////////////////////////////
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges]
@=""
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges\Range100]
"*"=dword:00000002
":Range"="192.168.10.121"
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges\Range101]
"*"=dword:00000001
":Range"="192.168.10.121"
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2]
@=""
"DisplayName"="可信站点"
"CurrentLevel"=dword:00001000
"Flags"=dword:00000043
"1004"=dword:00000000
"1201"=dword:00000000
"1402"=dword:00000000
"2201"=dword:00000000
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\1]
@=""
"DisplayName"="本地Intranet"
"CurrentLevel"=dword:00000000
"1001"=dword:00000000
"1004"=dword:00000000
"1201"=dword:00000000
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\3]
@=""
"DisplayName"="Internet"
"CurrentLevel"=dword:00000000
"1001"=dword:00000000
"1004"=dword:00000000
"1201"=dword:00000000
/////////////////////////////////////////////////////////////////////////////
//
// 通过网页修改activex安全设置,添加信任站点,禁用弹出窗口阻止程序
//
/////////////////////////////////////////////////////////////////////////////
信任站点的注册表项
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges\Range[*]
ActiveX的注册表项
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\[0-4]\[*]
[0-4]
值设置
------------------------------
0 我的电脑
1 本地Intranet 区域
2 受信任的站点区域
3 Internet 区域
4 受限制的站点区域
[*]
1001 下载已签名的ActiveX 控件
1004 下载未签名的ActiveX 控件
1200 运行ActiveX 控件和插件
1201 对没有标记为安全的ActiveX 控件进行初始化和脚本运行
1405 对标记为可安全执行脚本的ActiveX 控件执行脚本
2201 ActiveX 控件自动提示**
弹出窗口阻止程序的注册表项
HKEY_CURRENT_USERHKCU\Software\Microsoft\Internet Explorer\New Windows\PopupMgr
具体脚本如下:
net Settings\\ZoneMap\\Ranges\\Range101\\:Range","192.168.0.2");
//修改IE ActiveX安全设置
WshShell.RegWrite("HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Inter net Settings\\Zones\\3\\1001","0","REG_DWORD");
WshShell.RegWrite("HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Inter net Settings\\Zones\\3\\1004","0","REG_DWORD");
WshShell.RegWrite("HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Inter net Settings\\Zones\\3\\1200","0","REG_DWORD");
WshShell.RegWrite("HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Inter net Settings\\Zones\\3\\1201","0","REG_DWORD");
WshShell.RegWrite("HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Inter net Settings\\Zones\\3\\1405","0","REG_DWORD");
WshShell.RegWrite("HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Inter net Settings\\Zones\\3\\2201","0","REG_DWORD");
//禁用xinxp弹出窗口阻止程序
WshShell.RegWrite("HKCU\\Software\\Microsoft\\Internet Explorer\\New Windows\\PopupMgr","no");
alert("active控件安全设置,弹出窗口设置,信任站点设置成功");
//-->
来源: