最近公司发展蛮快,网络不断扩容,经常要安装服务器,使得我好多时间花在了配置服务器上.对于重复劳动,我一向不太喜欢的,所以就想到了写个脚本,让服务器自己去配置.以下脚本在2003上已经试验过,没有问题,希望大家能用得上;
文件auto-conf.bat的内容:
@echo off
echo "请确认您要对系统进行安全配置(只能用于windows server 2003!)"
choice /c YN /m "确认请按 y开始配置,否请按 n退出"
if errorlevel 2 goto no
if errorlevel 1 goto yes
:yes
secedit /configure /db typhoon.sdb /cfg typhoon.inf /overwrite /areas securitypolicy /log typhoon.log /quiet
cacls c: /r Everyone /e
regedit /s /c typhoon.reg
sc stop appmgmt
sc config appmgmt start= disabled
sc stop clipsrv
sc config clipsrv start= disabled
sc stop dh-cp
sc config dh-cp start= disabled
sc stop dfs
sc config dfs start= disabled
sc stop trkwks
sc config trkwks start= disabled
sc stop trksvr
sc config trksvr start= disabled
sc stop dnscache
sc config dnscache start= disabled
sc stop ersvc
sc config ersvc start= disabled
sc stop ntfrs
sc config ntfrs start= disabled
sc stop helpsvc
sc config helpsvc start= disabled
sc stop hidserv
sc config hidserv start= disabled
sc stop imapiservice
sc config imapiservice start= disabled
sc stop cisvc
sc config cisvc start= disabled
sc stop ismserv
sc config ismserv start= disabled
sc stop kdc
sc config kdc start= disabled
sc stop licenseservice
sc config licenseservice start= disabled
sc stop mnmsrvc
sc config mnmsrvc start= disabled
sc stop netdde
sc config netdde start= disabled
sc stop netddedsdm
sc config netddedsdm start= disabled
sc stop spooler
sc config spooler start= disabled
sc stop remoteregistry
sc config remoteregistry start= disabled
sc stop remoteaccess
sc config remoteaccess start= disabled
sc stop lmhosts
sc config lmhosts start= disabled
sc stop termservice
sc config termservice start= disabled
sc stop tssdis
sc config tssdis start= disabled
sc stop themes
sc config themes start= disabled
sc stop webclient
sc config webclient start= disabled
sc stop audiosrv
sc config audiosrv start= disabled
sc stop sharedaccess
sc config sharedaccess start= disabled
sc stop stisvc
sc config stisvc start= disabled
sc stop winhttpautoproxysvc
sc config winhttpautoproxysvc start= disabled
sc stop wzcsvc
sc config wzcsvc start= disabled
net localgroup guests nobody /del
net user nobody !@10AsD*we%e
echo "目前还没配置的项目:1.本地连接属性"
echo " 2.根据需要清除桌面,开始菜单,管理工具中不用的图标"
echo " 3.添加/删除程序中的组件"
echo " 4.我的电脑的属性"
echo " 5.根据需要删除不用的用户,设置管理员复杂密码"
goto end
:no
echo "no"
goto end
:end
pause
exit
文件typhoon.sdb由mmc的安全配置和分析生成,typhoon.inf是自己配置的安全模板,typhoon.reg是需要修改的注册表项.
自动配置windows server 2003 的安全
精选 转载
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
windows 2003 安全配置
一、开启防火墙先关闭不必要的端口网上邻居--属性--本地连接--属性--高级--设置--启用防火墙然后在例外那边添加所需要的端口。常用端口号详解:端口号21,说明:FTP服务所开放的端口,用于上传,下载。端口号25,说明:SMTP服务所开放的端口,用于发送邮件。端口号53,说明:DNS服务所开放的端口,入侵者可能是试图进行区域传递(TCP),欺骗DNS(UDP)或隐藏其他的通信。因此防火墙常常过滤
服务 Windows2003安全 Windows2003策略 sql2000安全 Windows2003防火墙 -
windows server 2003 安全设置
windows server 2003 安全设置
职场 组策略 安全设置 休闲 -
Windows 2003 Server安全配置完整篇(转)
学习
服务器 ftp服务器 sql 存储过程 应用程序