标题: [注册表类] 批处理如何批量添加列表域名或IP到指定键值(导入导出黑白名单)? [打印本页]
作者: Nano 时间: 2010-9-30 08:02 标题: 批处理如何批量添加列表域名或IP到指定键值(导入导出黑白名单)?
- rem -----------------------------for Internet Settings begin ---------------------------
- Rem Internet常规设置每次访问此页时检查(E)
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /v SyncMode5 /t REG_DWORD /d 0x00000003 /f
-
- rem -----------------------------for Internet Settings end -----------------------------
-
- rem -----------------------------for Cache begin ---------------------------
- Rem 关闭IE时清空 Internet 临时文件夹
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Cache" /v Persistent /t REG_DWORD /d 0x00000000 /f
-
- rem -----------------------------for Cache end -----------------------------
-
- rem -----------------------------for Domains begin ---------------------------
- Rem 添加可信站点域名中国移动NGCRM系统xg.boss.hb.cmcc
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\hb.cmcc\xg.boss" /v http /t REG_DWORD /d 0x00000002 /f
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\hb.cmcc\xg.boss" /v https /t REG_DWORD /d 0x00000002 /f
- Rem 添加可信站点域名农行95599.cn
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\95599.cn" /v http /t REG_DWORD /d 0x00000002 /f
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\95599.cn" /v https /t REG_DWORD /d 0x00000002 /f
- Rem 添加可信站点域名农行abchina.com
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\abchina.com" /v http /t REG_DWORD /d 0x00000002 /f
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\abchina.com" /v https /t REG_DWORD /d 0x00000002 /f
-
- rem -----------------------------for Domains end -----------------------------
-
- rem -----------------------------for Ranges begin ---------------------------
- Rem 添加可信站点IP中国移动NGCRM系统DNS
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges\Range100" /v * /t REG_DWORD /d 0x00000002 /f
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges\Range100" /v :Range /t REG_SZ /d 10.25.*.* /f
-
- rem -----------------------------for Ranges end -----------------------------
-
- rem -----------------------------for Zones begin ---------------------------
- Rem IE安全设置提示下载未签名的 ActiveX 控件
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2" /v 1004 /t REG_DWORD /d 0x00000001 /f
- Rem IE安全设置启用未标记为安全的 ActiveX 控件
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2" /v 1201 /t REG_DWORD /d 0x00000000 /f
-
- rem -----------------------------for Zones end -----------------------------
复制代码
求助:如何批量添加如下域名到注册表
www.google.com.hk
www.sina.com.cn
http://ccclub.cmbchina.com等等
Domains\hb.cmcc\xg.boss也就是想把红色字段用变量替换。
Domains\google.com.hk\www
Domains\sina.com.cn\www
Domains\cmbchina.com\ccclub
[ 本帖最后由 Nano 于 2010-9-30 16:49 编辑 ]
作者: Nano 时间: 2010-9-30 16:44
- rem -----------------------------for Internet Explorer begin ---------------------------
-
- rem -----------------------------for Main begin ---------------------------
- Rem IE常规设置-更改主页
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main" /v "Start Page" /d "http://xg.boss.hb.cmcc:8080/ngcrm/bsf/index.action" /f
- rem -----------------------------for Main end -----------------------------
-
- rem -----------------------------for New Windows begin ---------------------------
- Rem IE阻止弹出窗口(B)
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows" /v PopupMgr /d yes /f
- Rem IE阻止弹出窗口时不播放声音(P)
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows" /v PlaySound /t REG_DWORD /d 0x00000000 /f
- Rem IE阻止弹出窗口时不显示信息栏(I)
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows" /v UseSecBand /t REG_DWORD /d 0x00000000 /f
- Rem IE阻止弹出窗口筛选级别(F):高:阻止所有弹出窗口(使用 Ctrl 替代)
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows" /v BlockUserInit /t REG_DWORD /d 0x00000001 /f
- Rem IE阻止弹出窗口筛选级别(F):中:阻止大多数自动弹出窗口
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows" /v UseHooks /t REG_DWORD /d 0x00000001 /f
- Rem IE阻止弹出窗口筛选级别(F):低:允许来自安全站点的弹出窗口
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows" /v UseTimerMethod /t REG_DWORD /d 0x00000001 /f
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\New Windows" /v AllowHTTPS /t REG_DWORD /d 0x00000001 /f
- rem -----------------------------for New Windows end -----------------------------
-
- rem -----------------------------for Internet Explorer end -----------------------------
-
- rem -----------------------------for Internet Settings begin ---------------------------
- Rem IE常规设置-每次访问此页时检查(E)
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /v SyncMode5 /t REG_DWORD /d 0x00000003 /f
-
- rem -----------------------------for Cache begin ---------------------------
- Rem IE关闭时清空 Internet 临时文件夹
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Cache" /v Persistent /t REG_DWORD /d 0x00000000 /f
- rem -----------------------------for Cache end -----------------------------
-
- rem -----------------------------for Domains begin ---------------------------
- Rem 添加可信站点域名:中国移动NGCRM系统xg.boss.hb.cmcc
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\hb.cmcc\xg.boss" /v http /t REG_DWORD /d 0x00000002 /f
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\hb.cmcc\xg.boss" /v https /t REG_DWORD /d 0x00000002 /f
- rem -----------------------------for Domains end -----------------------------
-
- rem -----------------------------for Ranges begin ---------------------------
- Rem 添加可信站点IP:中国移动NGCRM系统DNS
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges\Range100" /v * /t REG_DWORD /d 0x00000002 /f
- reg add "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Ranges\Range100" /v :Range /t REG_SZ /d 10.25.*.* /f
- rem -----------------------------for Ranges end -----------------------------
-
- rem -----------------------------for Zones begin ---------------------------
- Rem IE安全设置-提示下载未签名的 ActiveX 控件
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2" /v 1004 /t REG_DWORD /d 0x00000001 /f
- Rem IE安全设置-启用未标记为安全的 ActiveX 控件
- reg add "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones\2" /v 1201 /t REG_DWORD /d 0x00000000 /f
- rem -----------------------------for Zones end -----------------------------
-
- rem -----------------------------for Internet Settings end -----------------------------
- Pause
复制代码
欢迎光临 批处理之家 (http://bathome.net./) |
Powered by Discuz! 7.2 |