"run as" possibility

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi there,

I wrote an application which use WMI and get infos from Active Directory.
Now we wan't to implement a that the programm can run with "run as"
possibility. When we tried it was not possible to run the programm correctly.
With an administrative privileg there is no trouble.
How can I do that?

Many thanks
Timo
 
Timo said:
I wrote an application which use WMI and get infos from Active Directory.
Now we wan't to implement a that the programm can run with "run as"
possibility. When we tried it was not possible to run the programm
correctly.
With an administrative privileg there is no trouble.
How can I do that?

If you are using WMI from within a program, check the docs for
CreateProcessAsUser()

http://msdn.microsoft.com/library/d...ry/en-us/dllproc/base/createprocessasuser.asp

or CreateProcessWithLogonW()

http://msdn.microsoft.com/library/d...n-us/dllproc/base/createprocesswithlogonw.asp

which could launch the program that does the WMI stuff.

If you are using a scripting language, your script would have launch an
executable which would call one of the functions above to run the script.

Regards,
Will
 
Back
Top