找回密码
 加入
搜索
查看: 2463|回复: 7

如何卸载生成的免疫文件

[复制链接]
发表于 2008-6-19 03:53:24 | 显示全部楼层 |阅读模式
这是安装免疫(测试成功)

#NoTrayIcon
#include <Process.au3>
$exe = @ScriptDir & "\jinzhi.txt"
$file = FileOpen($exe, 0)
If $file = -1 Then
    MsgBox(0, "错误", "无法打开文本,请检查相关设置!")
    Exit
EndIf
While 1
    $line = FileReadLine($file)
    If @error = -1 Then ExitLoop
    If $line <> "" Then
        DirCreate("" & $line & "")
        FileSetAttrib("" & $line & "", '+R+H+S+A')
        _RunDOS("echo Y|cacls " & $line & " /P Everyone:n")
    EndIf
WEnd

下面是jinzhi.txt
C:\0.ExE
C:\1.ExE
C:\12.ExE
C:\14.ExE
C:\2.ExE
C:\3.ExE
C:\315.ExE
C:\4.ExE
C:\42102BD8.ExE


这是我搞的 卸载.au3 (测试失败)

#NoTrayIcon
#include <Process.au3>
$exe = @ScriptDir & "\jinzhi.txt"
$file = FileOpen($exe, 0)
If $file = -1 Then
    MsgBox(0, "错误", "无法打开文本,请检查相关设置!")
    Exit
EndIf
While 1
    $line = FileReadLine($file)
    If @error = -1 Then ExitLoop
    If $line <> "" Then
        _RunDOS("echo Y|cacls " & $line & " /P Everyone:y")
         FileSetAttrib("" & $line & "", '-R-H-S-A')
        FileRecycle("" & $line & "")
    EndIf
WEnd


请问如何 搞定去属性和删除免疫文件?


         FileSetAttrib("" & $line & "", '-R-H-S-A')
        FileRecycle("" & $line & "")

这两个怎么试都不去属性和删除文件.

[ 本帖最后由 cj4025 于 2008-6-25 01:17 编辑 ]
 楼主| 发表于 2008-6-19 19:12:10 | 显示全部楼层
怎么没有人给解答啊.着急啊,,
 楼主| 发表于 2008-6-20 18:05:22 | 显示全部楼层
眼看贴子沉下去了,也没有人给解答下,郁闷 啊.
发表于 2008-6-21 01:13:29 | 显示全部楼层
去掉权限,去掉隐藏,去掉只读,再删除。
 楼主| 发表于 2008-6-21 06:01:59 | 显示全部楼层
大哥啊,我试了,不可以啊
 楼主| 发表于 2008-6-22 00:34:20 | 显示全部楼层
论坛的高手都到那去了
 楼主| 发表于 2008-6-23 21:58:02 | 显示全部楼层
_RunDOS("echo Y|cacls " & $line & " /P Everyone:y")
     FileSetAttrib("" & $line & "", '-R-H-S-A')
        FileRecycle("" & $line & "")

那你看看我这个有错误吗?
 楼主| 发表于 2008-6-25 01:14:16 | 显示全部楼层
非常感谢,已经解决 已经给你加分。


不过你告诉我的有点小错误
        FileSetAttrib("" & $line & "", '-RHSA)
应该是
        FileSetAttrib("" & $line & "", '-RHSA')
少个引号。

非常感谢


#NoTrayIcon
#include <Process.au3>
$exe = @ScriptDir & "\jinzhi.txt"
$file = FileOpen($exe, 0)
If $file = -1 Then
    MsgBox(0, "错误", "无法打开文本,请检查相关设置!")
    Exit
EndIf
While 1
    $line = FileReadLine($file)
    If @error = -1 Then ExitLoop
    If $line <> "" Then
        _RunDOS("echo Y|cacls " & $line & " /g Everyone:f")
        FileSetAttrib("" & $line & "", '-RHSA')
        if fileexists ($line) then DirRemove ($line)
        if fileexists ($line) then FileDelete ($line)
    EndIf
WEnd


[ 本帖最后由 cj4025 于 2008-6-25 01:16 编辑 ]
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-4-20 22:26 , Processed in 0.072222 second(s), 19 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表