RemCom
RemCom copied to clipboard
Remcom service permissions
I noticed that while running remcom. the service is installed as it should but it is installed with service permissions which prevents many things because of the "Restrictive" permissions that windows puts on services. Some examples are: running installers, installing other services, and changing user permissions. This can be fixed by changing the permissions before remcom starts running or using the win32 api calls to include a security authentication token for the CreateProcess command; modifying create process is probably the best option. Otherwise, the process will be started as the $System user which is only bound to create headaches..
I found a function that might better suite what we need... http://msdn.microsoft.com/en-us/library/windows/desktop/ms682429%28v=vs.85%29.aspx BOOL WINAPI CreateProcessAsUser( In_opt HANDLE hToken, In_opt LPCTSTR lpApplicationName, Inout_opt LPTSTR lpCommandLine, In_opt LPSECURITY_ATTRIBUTES lpProcessAttributes, In_opt LPSECURITY_ATTRIBUTES lpThreadAttributes, In BOOL bInheritHandles, In DWORD dwCreationFlags, In_opt LPVOID lpEnvironment, In_opt LPCTSTR lpCurrentDirectory, In LPSTARTUPINFO lpStartupInfo, Out LPPROCESS_INFORMATION lpProcessInformation );