Only undocumented solutions. MS don't provide us with documented solutions to this kind of "advanced" programming. My "best guess" is that you'd have to hook CreateProcess. Check out e.g. winternals for possible solutions (you won't like the effort needed).