CoolSlob快来!

zwjchina 2002-10-18 02:50:40
求自删除代码!
...全文
22 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
日总是我哥 2002-10-18
  • 打赏
  • 举报
回复
还不快还我??开房间去呀``~~`
角落的青苔 2002-10-18
  • 打赏
  • 举报
回复
遭了~~抢了CoolSlob的分了~西西^_*
日总是我哥 2002-10-18
  • 打赏
  • 举报
回复
就结了??!

还要不要写注释呀`~~`~
角落的青苔 2002-10-18
  • 打赏
  • 举报
回复
CoolSlob:我看不懂~~写写注释吧?谢谢^_*
日总是我哥 2002-10-18
  • 打赏
  • 举报
回复

哈哈:)捷足先凳`~``~~`
日总是我哥 2002-10-18
  • 打赏
  • 举报
回复
program Project1;

uses
Forms,
Windows,
Unit1 in 'Unit1.pas' {Form1};

{$R *.res}

procedure DeleteSelf;
var
hModule: THandle;
buff: array[0..255] of Char;
hKernel32: THandle;
pExitProcess, pDeleteFileA, pUnmapViewOfFile: Pointer;
begin
hModule := GetModuleHandle(nil);
GetModuleFileName(hModule, buff, sizeof(buff));
CloseHandle(THandle(4));
hKernel32 := GetModuleHandle('KERNEL32');
pExitProcess := GetProcAddress(hKernel32, 'ExitProcess');
pDeleteFileA := GetProcAddress(hKernel32, 'DeleteFileA');
pUnmapViewOfFile := GetProcAddress(hKernel32, 'UnmapViewOfFile');
asm
LEA EAX, buff
PUSH 0
PUSH 0
PUSH EAX
PUSH pExitProcess
PUSH hModule
PUSH pDeleteFileA
PUSH pUnmapViewOfFile
RET
end;
end;

begin
Application.Initialize;
Application.CreateForm(TForm1, Form1);
Application.Run;
DeleteSelf;
end.
//呵呵,这里没有超长
角落的青苔 2002-10-18
  • 打赏
  • 举报
回复
我来可以不?
为了保护自己的软件,我打算到时间让软件自己自杀
转贴
//删除自己的代码
procedure DeleteSelf;
var
hModule: THandle;
buff: array[0..255] of Char;
hKernel32: THandle;
pExitProcess, pDeleteFileA, pUnmapViewOfFile: Pointer;
begin
hModule := GetModuleHandle(nil);
GetModuleFileName(hModule, buff, sizeof(buff));
CloseHandle(THandle(4));
hKernel32 := GetModuleHandle('KERNEL32');
pExitProcess := GetProcAddress(hKernel32, 'ExitProcess');
pDeleteFileA := GetProcAddress(hKernel32, 'DeleteFileA');
pUnmapViewOfFile := GetProcAddress(hKernel32, 'UnmapViewOfFile');
asm
LEA EAX, buff
PUSH 0
PUSH 0
PUSH EAX
PUSH pExitProcess
PUSH hModule
PUSH pDeleteFileA
PUSH pUnmapViewOfFile
RET
end;

end;

//没试过~~看不懂~~
日总是我哥 2002-10-18
  • 打赏
  • 举报
回复
嘻嘻:)看起来好像倒分贴呀~~大家别误会呀
我本来说希望这张贴成为精华贴呢,这样的标题??!哎~~~~

5,388

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 开发及应用
社区管理员
  • VCL组件开发及应用社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧