Hi, everybody!
I need help!
How to make such system-hook: when you start some programm you make something operations..
I mean I want to hook event, when programm starts, and, for example, try to forbid running this programm.
Hm.. May be you know another way to forbid running some applications. The application may not have registry settings - just .EXE. I want to forbid running some EXE-files from my own programm..
Can you help me?
Hook running programm..
Moderatoren: crack, Krüsty, Marwin
hm, here is some code to take a snapshot of all runnig progs:
i think you can search for names too (at the moment i dont have any WINAPI-References)
see msdn specially CreateToolhelp32Snapshot
PS: you can make a timer-procedure or thread so you check all 0.5-1 seconds for the "false" program
Code: Alles auswählen
invoke CreateToolhelp32Snapshot, TH32CS_SNAPPROCESS, 0
mov hSnapshot,eax
.if eax!=-1
mov uProcess.dwSize, sizeof uProcess
invoke Process32First, eax, ADDR uProcess
.while eax
lea edi,[uProcess.szExeFile]
invoke SendDlgItemMessage,hWin,ID_PROGRAM_LIST,LB_ADDSTRING,0,edi
invoke SendDlgItemMessage,hWin,ID_PROGRAM_LIST,LB_SETITEMDATA,eax,uProcess.th32ProcessID
invoke Process32Next, [hSnapshot], ADDR uProcess
.endw
see msdn specially CreateToolhelp32Snapshot
PS: you can make a timer-procedure or thread so you check all 0.5-1 seconds for the "false" program