Batch application: Restore the McAfee renamed suspect virus file name extension _dos/bat

Source: Internet
Author: User
McAfee identifies the suspect virus file, but the virus definition is not available in the library, and the file name extension is named Vir or VXE, which establishes the batch file and uses the restored EXE file

McAfee renaming principle:
Original renamed Description
not V?? V?? File Extensions that does not start with v are renamed with v as
The initial letter of the file extension. For example,
MYFILE. DOC becomes MYFILE. VOC.
V?? VIR Font face= "Jenabn+universltstd-light" > File extensions that start with v are renamed as . VIR . For
example, MYFILE. VBs becomes MYFILE. VIR.
VIR ,

V01 - V99

These files are are recognized as already infected, and are not
Renamed again.
VIR Files with no extensions are given the extension, . VIR .




@echo off

echo on Error Resume Next >%temp%\filesystem.vbs
echo Const wbemflagreturnimmediately = ^&h10 >>%temp%\filesystem.vbs
echo Const wbemflagforwardonly = ^&h20 >>%temp%\filesystem.vbs

echo for each strComputer in Arrcomputers >>%temp%\filesystem.vbs

echo Set objWMIService = GetObject ("winmgmts:\\.\root\cimv2") >>%temp%\filesystem.vbs >>%temp%\ Filesystem.vbs
echo Set colitems = objWMIService.ExecQuery ("SELECT * from Win32_LogicalDisk", "WQL", _ >>%temp%\filesystem.vbs
echo wbemflagreturnimmediately + wbemflagforwardonly) >>%temp%\filesystem.vbs

echo for each objitem in colitems >>%temp%\filesystem.vbs
echo If objitem.drivertype=3 Then wscript.echo objitem.caption ^& "\" End If >>%temp%\filesystem.vbs
Echo Next >>%temp%\filesystem.vbs
Echo Next >>%temp%\filesystem.vbs

for/f%%i in (' cscript//nologo%temp%\filesystem.vbs ') do Call:change%%i

Goto END

: Change
Cd/d%1
for/f "delims=|"%%i in (' dir *.vxe/b/s/a ') does (cacls "%%i"/e/g everyone:f & Ren "%%i" *.exe)

: End
Del%temp%\filesystem.vbs

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.