Job Object Insanity

Job Objects were introduced to Windows in Windows XP/Windows Server 2003 to allow an application to manage a group of processes. One of the limitations of Job Objects is that a process can only belong to a single Job object.  This becomes an issue when you are attempting to manipulate a process which is already associated with…

1

RunAs Verb (Process.Start) doesn’t work from a LocalSystem .NET Service

The Process.Start method in System.Diagnostics is equivalent to CreateProcess() in Win32. If you want to  launch a process as a different user, in Win32 you either need to call CreateProcessAsUser,  CreateProcessWithLogonW or CreateProcessWithTokenW. In .NET using Process.Start, you can use the  “runas” verb to the same thing. If you have a .NET Service configured with the LocalSystem…

0

Launching a process as a normal user from an elevated user.

A frequent question from our customers is the ability to launch a non-elevated user from an elevated user.  This can typically happen from an installer application which is elevated and you want to launch an application as a non-elevated user. It turns out you can use CreateProcessWithTokenW() to launch a non-elevated process from an elevated…

0

Launching an interactive process from Windows Service in Windows Vista and later

The first thing you should do about it is that, don’t do it. There are many limitations, bad implications and restrictions involved into it. In case, you are in a state that you cannot avoid launching an interactive process from Windows Service then you might want to read this article. Launching an interactive application from…