MCPcopy Create free account
hub / github.com/bobranten/Ext4Fsd / Ext2StartPipeSrv

Function Ext2StartPipeSrv

Ext2Mgr/Ext2Pipe.cpp:826–855  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

824}
825
826BOOL Ext2StartPipeSrv()
827{
828 HMODULE hAdvapi32;
829 BOOL rc = FALSE;
830
831 if (CanDoLocalMount()) {
832 return TRUE;
833 }
834
835 /* query advapi32!CreateProcessWithToken */
836 hAdvapi32 = GetModuleHandle("Advapi32.DLL");
837 g_CreateProcessWithTokenW = (lpfnCreateProcessWithTokenW)
838 GetProcAddress(hAdvapi32, "CreateProcessWithTokenW");
839
840 if (!g_CreateProcessWithTokenW) {
841 rc = FALSE;
842 goto errorout;
843 }
844
845 /* add more privilege for toke duplication */
846 Ext2EnablePrivilege(SE_INCREASE_QUOTA_NAME);
847 Ext2EnablePrivilege(SE_TCB_NAME);
848
849 /* start Ext2Srv.exe */
850 rc = Ext2StartSrv();
851
852errorout:
853
854 return rc;
855}
856
857VOID Ext2StopPipeSrv()
858{

Callers

nothing calls this directly

Calls 3

CanDoLocalMountFunction · 0.85
Ext2StartSrvFunction · 0.85
Ext2EnablePrivilegeFunction · 0.70

Tested by

no test coverage detected