unit Unit1; interface uses Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics, Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls, madCodeHook, madStrings; const BS1HOOK_IPCMESSAGE_STRING = 'ipcBs1MhCtrl'; BS1HOOK_DRIVERTAG = 'bs1HookDriver'; BS1HOOK_DRIVERNAME32 = 'bsonex32.sys'; BS1HOOK_DRIVERNAME64 = 'bsonex64.sys'; type TForm1 = class(TForm) btnStop: TButton; procedure btnStopClick(Sender: TObject); private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} procedure TForm1.btnStopClick(Sender: TObject); begin DestroyIpcQueue(PAnsiChar(BS1HOOK_IPCMESSAGE_STRING)); UninjectLibrary(BS1HOOK_DRIVERTAG, BS1HOOK_DRIVERNAME64, ALL_SESSIONS, INJECT_METRO_APPS, nil, nil); // 32 bit UninjectLibrary(BS1HOOK_DRIVERTAG, BS1HOOK_DRIVERNAME32, ALL_SESSIONS, INJECT_METRO_APPS, nil, nil); if not StopInjectionDriver(BS1HOOK_DRIVERTAG) then MessageBox(Handle, 'stopping driver failed', 'error...', MB_ICONERROR); ShowMessage('ÁßÁö µÇ¾ú½À´Ï´Ù'); end; end.