Cacher, hide, process, application, xp

cs_Den Messages postés 18 Date d'inscription mardi 23 janvier 2001 Statut Membre Dernière intervention 20 août 2007 - 30 juil. 2003 à 10:09
ziuu Messages postés 1 Date d'inscription dimanche 1 avril 2007 Statut Membre Dernière intervention 10 avril 2007 - 10 avril 2007 à 01:16
voici un code trouvé sur le web, il devrait permettre de cacher le processus du gestionnaire des taches de XP, je ne sait pas l'utiliser
et j'ai déposé ce code sur ce site. Il à été supprimé le lendemain sans
me donner d'explication logique... ???

Si l'un de vous sait utiliser ce code merci de me fournir un exemple.

code en delphi
Here is Delphi example of hook dll. To install hook - call from .EXE SetHook function.
When DLL is injected into process - it is examine command line to find - "am i injected
onto taskmanager process?" If so -
seek "SysListView32" controls ( Task and Process listviews).

library HookLib;

uses
SysUtils,
Classes, Windows;

var hHook: integer;
hMod: THANDLE;
CurL: integer;
L: array[0..1] of integer;
EnabledIt: Boolean;

procedure DOUT(s:String);
begin
OutputDebugString(PChar(s+#10#13));
end;

function ResetWindowProc(hwnd:integer; NewProc:DWORD):DWORD;
begin
Result := SetWindowLong(hwnd,GWL_WNDPROC, NewProc);
end;

function FindListView(hwnd, prev: integer): boolean;
var wText: PChar;
begin
wText := AllocMem(250);
Result := FALSE;
if (CurL = 2) or (hwnd=0) then Exit;;
if(GetClassName(hwnd, wText, 250) <> 0) then
if wText = 'SysListView32' then
begin
L[CurL] := hwnd;
inc(CurL);
GetWindowText(hwnd, wText, 250);
DOUT(wText + ' ' + 'Found!');
end;
FindListView(GetWindow(hwnd, GW_CHILD), hwnd);
FindListView(GetWindow(hwnd, GW_HWNDNEXT), hwnd);
Result := TRUE;
end;

function HookProc(Code, wParam, lParam: integer): Integer; stdcall;
begin
if (Code = HSHELL_WINDOWCREATED) and (EnabledIt) then
begin
FindListView(wParam, 0);
end;
Result := CallNextHookEx(hHook, Code, wParam, lParam);
end;

function SetHook: DWORD;stdcall;
begin
hHook := SetWindowsHookEx(WH_SHELL, @HookProc, hMod, 0 );
Result := 0;
end;

function ResetHook: DWORD;stdcall;
begin
UnhookWindowsHookEx(hHook);
Result := 0;
end;

procedure InitDLL;
begin
EnabledIt := FALSE;
DOUT(GetCommandLine());
If Pos('taskmgr', GetCommandLine()) <> 0 Then EnabledIt := TRUE;
hMod := GetModuleHandle('HookLib.dll');
end;

exports SetHook, ResetHook;

begin
InitDLL;
end.

2 réponses

chechex Messages postés 1 Date d'inscription vendredi 21 juillet 2006 Statut Membre Dernière intervention 21 juillet 2006
21 juil. 2006 à 08:43
:(
0
ziuu Messages postés 1 Date d'inscription dimanche 1 avril 2007 Statut Membre Dernière intervention 10 avril 2007
10 avril 2007 à 01:16
naum entendi

coloca ai source do projeto pra usar essa dll
0
Rejoignez-nous