Leaked source code of windows server 2003
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
#include <windows.h>
#include <stdlib.h>
int _cdecl main( int argc, char *argv[] ) { FARPROC lpProc; HMODULE hLib = NULL; BOOL Result = FALSE;
//
// load the client-side user-mode PnP manager DLL
//
hLib = LoadLibrary(TEXT("cfgmgr32.dll")); if (hLib != NULL) { lpProc = GetProcAddress( hLib, "CMP_Report_LogOn" ); if (lpProc != NULL) { //
// Ping the user-mode pnp manager -
// pass the private id as a parameter
//
Result = (lpProc)(0x07020420, GetCurrentProcessId()) ? TRUE : FALSE; }
FreeLibrary( hLib ); }
if (Result) return 0; else return 1 ; }
|