Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
RunAs utility
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Title:
RunAs utility
Miscellaneous
Thread ID:
00902240
Message ID:
00902240
Views:
64
Hi All,

I'd like to execute a particular .exe (third party utility, not COM, not written in VFP) from VFP under a user security context other than the one the VFP app (which is a COM server) is running under. In short, I don't trust this .exe as much as I trust my app <s>, so I want to give it a very restricted security context in which to run. In short, I want to use the "Run As..." feature in Windows progammatically.

Currently, I'm just running the .exe via CreateProcess() and killing it with TerminateProcess() in the event of a timeout. I'd like to tighen this down a bit. I've looked at the various API calls required to get a user context tolken etc, and don't relish the idea of porting it all to VFP. Here's to hoping someone already has, or as wrapped it all up in a .dll for me <s>.

Also, the VFP app runs as a COM service (WWWC web app), so not sure if this impacts what I can/can't do.

Here is an example of what I'm looking for, but this tool requires another service to be running which I'd like to avoid.
http://www.codeguru.com/Cpp/W-P/system/article.php/c5755/

Thanks!
-lc
Next
Reply
Map
View

Click here to load this message in the networking platform