如果您无法下载资料,请参考说明:
1、部分资料下载需要金币,请确保您的账户上有足够的金币
2、已购买过的文档,再次下载不重复扣费
3、资料包下载后请先用软件解压,在使用对应软件打开
PAGE\*MERGEFORMAT81/*============================================*DLLMain.cpp**DefinestheentrypointfortheGINADLL.*============================================*/#include"stdafx.h"//thisistheoneandonlyglobalvariableweuse,andit'simplementedtoberead-onlystaticHANDLE_hModule;HMODULEGetMyModuleHandle(){return(HMODULE)_hModule;}HINSTANCEGetMyInstance(){return(HINSTANCE)_hModule;}BOOLAPIENTRYDllMain(HANDLEhModule,DWORDreason,LPVOIDlpReserved){if(DLL_PROCESS_ATTACH==reason){_hModule=hModule;DisableThreadLibraryCalls(GetMyModuleHandle());}returnTRUE;}/*====================*DynGina.cpp*====================*/////AllfunctionsexportedfromourcustomGINAcanbefoundhere,//althoughallmostofthemdoisdelegatetotheGinaclass.//#include"stdafx.h"#include"Gina.h"BOOLWINAPIWlxNegotiate(DWORDdwWinlogonVersion,PDWORDpdwDllVersion){LDB1(L"-->WlxNegotiate(wlv=0x%08X",dwWinlogonVersion);BOOLresult=Gina::Negotiate(dwWinlogonVersion,pdwDllVersion);LDB(L"<--WlxNegotiate");returnresult;}BOOLWINAPIWlxInitialize(LPWSTRlpWinsta,HANDLEhWlx,PVOIDpvReserved,PVOIDpWinlogonFunctions,PVOID*pWlxContext){LDB(L"-->WlxInitialize");BOOLresult=Gina::Initialize(hWlx,pWinlogonFunctions,(Gina**)pWlxContext);LDB(L"<--WlxInitialize");returnresult;}VOIDWINAPIWlxDisplaySASNotice(PVOIDpWlxContext){LDB(L"-->WlxDisplaySASNotice");((Gina*)pWlxContext)->DisplaySASNotice();LDB(L"<--WlxDisplaySASNotice");}intWINAPIWlxLoggedOutSAS(PVOIDpWlxContext,DWORDdwSasType,PLUIDpAuthenticationId,PSIDpLogonSid,PDWORDpdwOptions,PHANDLEphToken,PWLX_MPR_NOTIFY_INFOpNprNotifyInfo,PVOID*pProfile){LDB(L"-->WlxLoggedOutSAS");return((Gina*)pWlxContext)->LoggedOutSAS(dwSasType,pAuthenticationId,pLogonSid,pdwOptions,phToken,pNprNotifyInfo,pProfile);/*constwchar_t*msg=L"";switch(result){caseWLX_SAS_ACTION_NONE:msg=L"WLX_SAS_ACTION_NONE";break;caseWLX_SAS_ACTION_LOGON:msg=L"WLX_SAS_ACTION_LOGON";break;}LDB1(L"<--WlxLoggedOutSAS(%s)",msg);returnr