此脚本使用McAfee的SupperDat,进行计算机上病毒的查杀。使用FLASHGET检查SupperDat更新,参考:http://blog.csdn.net/scz123/archive/2006/11/02/1362573.aspx
20061215: 修改scan.exe运行参数,增加 /PROGRAM (扫描恶意软件)、/NORENAME (不更改文件名)。
MCAFEE命令行参考手册:http://scz123.googlepages.com/Mcafee5100wpg.pdf
1、使用本地的MCAFEE SUPERDAT来运行的脚本
2、使用局域网上共享的MCAFEE SUPERDAT来运行的脚本
--------------------------------------------------------------------------------
1、使用本地的MCAFEE SUPERDAT来运行的脚本
--------------------------------------------------------------------------------
@echo off
echo McAfee手动杀毒脚本
echo created by scz 20061101
echo =================================================
echo 建议在管理员环境下运行此脚本,以便能成功杀除病毒
echo =================================================
rem 此脚本运行需要McAfee的SupperDat,下载地址:http://www.mcafee.com/apps/downloads/security_updates/superdat.asp?region=cn&segment=enterprise
rem SupperDat下载后,请重命名为Mcafee*.exe(*为任意字符)
if not exist mcafee*.exe (echo 病毒码不存在,无法执行下步操作,请按任意键退出... &goto error)
echo 正在释放病毒码...
for /f "skip=1" %%i in ('dir mcafee*.exe /o-d /b 2^>nul') do (del %%i)
for /f %%i in ('dir mcafee*.exe /b /o-d') do (%%i /e c:\Mcafee & goto start)
:start
echo 启动扫描...
echo @echo off >c:\mcafee\杀毒.bat
echo echo. c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo echo McAfee手动杀毒脚本,扫描结束后会自动打开报表 c:\mcafee\杀毒.bat
echo echo created by scz 20061031 c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo set filename=%%date:-=%%.%%time::=%%.html c:\mcafee\杀毒.bat
echo cd /d c:\mcafee c:\mcafee\杀毒.bat
echo REM 保留最近10个报表 c:\mcafee\杀毒.bat
echo for /f "skip=10" %%%%i in ('dir *.html /o-d /b 2^^^>nul') do (del %%%%i) c:\mcafee\杀毒.bat
echo scan /ADL /ANALYZE /PROGRAM /CLEAN /NORENAME /TIMEOUT 15 /WINMEM /HTML "%%filename%%" c:\mcafee\杀毒.bat
echo echo 病毒扫描完毕,请按任意键打开报表... c:\mcafee\杀毒.bat
echo if exist "%%filename%%" start "" "%%filename%%" c:\mcafee\杀毒.bat
cd /d c:\mcafee
start "McAfee VirusScan" cmd /c 杀毒.bat
goto end
:error
pause >nul
:end
--------------------------------------------------------------------------------
2、使用局域网上共享的MCAFEE SUPERDAT来运行的脚本
--------------------------------------------------------------------------------
@echo off
echo McAfee手动杀毒脚本
echo created by scz 20061101
echo =================================================
echo 建议在管理员环境下运行此脚本,以便能成功杀除病毒
echo =================================================
rem 此脚本运行需要McAfee的SupperDat,下载地址:http://www.mcafee.com/apps/downloads/security_updates/superdat.asp?region=cn&segment=enterprise
rem SupperDat下载后,请重命名为Mcafee*.exe(*为任意字符)
echo 正在连接远程计算机(scz)...
net use \\10.1.103.10 /user:scz\sczscz sczscz >nul 2>&1
net use x: /del /y >nul 2>&1
net use x: \\10.1.103.10\update >nul 2>&1 || (echo 网络异常,无法执行下步操作,请按任意键退出... &goto error)
cd /d x:\
if not exist mcafee*.exe (echo 病毒码不存在,无法执行下步操作,请按任意键退出... &goto error)
echo 正在释放病毒码...
for /f %%i in ('dir mcafee*.exe /b /o-d 2^>nul') do (%%i /e c:\Mcafee & goto start)
:start
net use x: /del /y >nul 2>&1
net use \\10.1.103.10 /del /y >nul 2>&1
echo 启动扫描...
echo @echo off >c:\mcafee\杀毒.bat
echo echo. c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo echo McAfee手动杀毒脚本,扫描结束后会自动打开报表 c:\mcafee\杀毒.bat
echo echo created by scz 20061031 c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo set filename=%%date:-=%%.%%time::=%%.html c:\mcafee\杀毒.bat
echo cd /d c:\mcafee c:\mcafee\杀毒.bat
echo REM 保留最近10个报表 c:\mcafee\杀毒.bat
echo for /f "skip=10" %%%%i in ('dir *.html /o-d /b 2^^^>nul') do (del %%%%i) c:\mcafee\杀毒.bat
echo scan /ADL /ANALYZE /CLEAN /TIMEOUT 15 /WINMEM /HTML "%%filename%%" c:\mcafee\杀毒.bat
echo echo 病毒扫描完毕,请按任意键打开报表... c:\mcafee\杀毒.bat
rem echo pause ^>nul c:\mcafee\杀毒.bat
echo if exist "%%filename%%" start "" "%%filename%%" c:\mcafee\杀毒.bat
cd /d c:\mcafee
start "McAfee VirusScan" cmd /c 杀毒.bat
goto end
:error
pause >nul
:end
20061215: 修改scan.exe运行参数,增加 /PROGRAM (扫描恶意软件)、/NORENAME (不更改文件名)。
MCAFEE命令行参考手册:http://scz123.googlepages.com/Mcafee5100wpg.pdf
1、使用本地的MCAFEE SUPERDAT来运行的脚本
2、使用局域网上共享的MCAFEE SUPERDAT来运行的脚本
--------------------------------------------------------------------------------
1、使用本地的MCAFEE SUPERDAT来运行的脚本
--------------------------------------------------------------------------------
@echo off
echo McAfee手动杀毒脚本
echo created by scz 20061101
echo =================================================
echo 建议在管理员环境下运行此脚本,以便能成功杀除病毒
echo =================================================
rem 此脚本运行需要McAfee的SupperDat,下载地址:http://www.mcafee.com/apps/downloads/security_updates/superdat.asp?region=cn&segment=enterprise
rem SupperDat下载后,请重命名为Mcafee*.exe(*为任意字符)
if not exist mcafee*.exe (echo 病毒码不存在,无法执行下步操作,请按任意键退出... &goto error)
echo 正在释放病毒码...
for /f "skip=1" %%i in ('dir mcafee*.exe /o-d /b 2^>nul') do (del %%i)
for /f %%i in ('dir mcafee*.exe /b /o-d') do (%%i /e c:\Mcafee & goto start)
:start
echo 启动扫描...
echo @echo off >c:\mcafee\杀毒.bat
echo echo. c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo echo McAfee手动杀毒脚本,扫描结束后会自动打开报表 c:\mcafee\杀毒.bat
echo echo created by scz 20061031 c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo set filename=%%date:-=%%.%%time::=%%.html c:\mcafee\杀毒.bat
echo cd /d c:\mcafee c:\mcafee\杀毒.bat
echo REM 保留最近10个报表 c:\mcafee\杀毒.bat
echo for /f "skip=10" %%%%i in ('dir *.html /o-d /b 2^^^>nul') do (del %%%%i) c:\mcafee\杀毒.bat
echo scan /ADL /ANALYZE /PROGRAM /CLEAN /NORENAME /TIMEOUT 15 /WINMEM /HTML "%%filename%%" c:\mcafee\杀毒.bat
echo echo 病毒扫描完毕,请按任意键打开报表... c:\mcafee\杀毒.bat
echo if exist "%%filename%%" start "" "%%filename%%" c:\mcafee\杀毒.bat
cd /d c:\mcafee
start "McAfee VirusScan" cmd /c 杀毒.bat
goto end
:error
pause >nul
:end
--------------------------------------------------------------------------------
2、使用局域网上共享的MCAFEE SUPERDAT来运行的脚本
--------------------------------------------------------------------------------
@echo off
echo McAfee手动杀毒脚本
echo created by scz 20061101
echo =================================================
echo 建议在管理员环境下运行此脚本,以便能成功杀除病毒
echo =================================================
rem 此脚本运行需要McAfee的SupperDat,下载地址:http://www.mcafee.com/apps/downloads/security_updates/superdat.asp?region=cn&segment=enterprise
rem SupperDat下载后,请重命名为Mcafee*.exe(*为任意字符)
echo 正在连接远程计算机(scz)...
net use \\10.1.103.10 /user:scz\sczscz sczscz >nul 2>&1
net use x: /del /y >nul 2>&1
net use x: \\10.1.103.10\update >nul 2>&1 || (echo 网络异常,无法执行下步操作,请按任意键退出... &goto error)
cd /d x:\
if not exist mcafee*.exe (echo 病毒码不存在,无法执行下步操作,请按任意键退出... &goto error)
echo 正在释放病毒码...
for /f %%i in ('dir mcafee*.exe /b /o-d 2^>nul') do (%%i /e c:\Mcafee & goto start)
:start
net use x: /del /y >nul 2>&1
net use \\10.1.103.10 /del /y >nul 2>&1
echo 启动扫描...
echo @echo off >c:\mcafee\杀毒.bat
echo echo. c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo echo McAfee手动杀毒脚本,扫描结束后会自动打开报表 c:\mcafee\杀毒.bat
echo echo created by scz 20061031 c:\mcafee\杀毒.bat
echo echo ============================================ c:\mcafee\杀毒.bat
echo set filename=%%date:-=%%.%%time::=%%.html c:\mcafee\杀毒.bat
echo cd /d c:\mcafee c:\mcafee\杀毒.bat
echo REM 保留最近10个报表 c:\mcafee\杀毒.bat
echo for /f "skip=10" %%%%i in ('dir *.html /o-d /b 2^^^>nul') do (del %%%%i) c:\mcafee\杀毒.bat
echo scan /ADL /ANALYZE /CLEAN /TIMEOUT 15 /WINMEM /HTML "%%filename%%" c:\mcafee\杀毒.bat
echo echo 病毒扫描完毕,请按任意键打开报表... c:\mcafee\杀毒.bat
rem echo pause ^>nul c:\mcafee\杀毒.bat
echo if exist "%%filename%%" start "" "%%filename%%" c:\mcafee\杀毒.bat
cd /d c:\mcafee
start "McAfee VirusScan" cmd /c 杀毒.bat
goto end
:error
pause >nul
:end