Run app with elevated privliges

G

Guest

I am writing an app to remotly stop and start windows services. I have the
app working fine as long as you have Admin rights to the remote box (where
I'm stoping services). I want to allow a user (who is not a admin) to run
this script with some sort of elivated privliges. So is there a way I can
make my script run with admin privlidges without telling the user the admin
userid and password.
 
J

John Timney \( MVP \)

As a quick guess, you can try using impersonation and use a named admin
account which is listed in the web.config (whihc your user cannot see),
revoke access in the location tags in web.config to anyone but the named
user in the authorisation section and you should have a workable solution.

Some links to help you.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vsent7/html/vxconImpersonation.asp
http://samples.gotdotnet.com/quickstart/aspplus/doc/configformat.aspx
http://support.microsoft.com/default.aspx?scid=kb;EN-US;Q316871
 
J

John Timney \( MVP \)

this might help you..............

http://blogs.parivedasolutions.com/borrell/archive/2005/09/23/Impersonation.aspx

--
Regards

John Timney
Microsoft MVP

John Timney ( MVP ) said:
As a quick guess, you can try using impersonation and use a named admin
account which is listed in the web.config (whihc your user cannot see),
revoke access in the location tags in web.config to anyone but the named
user in the authorisation section and you should have a workable solution.

Some links to help you.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vsent7/html/vxconImpersonation.asp
http://samples.gotdotnet.com/quickstart/aspplus/doc/configformat.aspx
http://support.microsoft.com/default.aspx?scid=kb;EN-US;Q316871
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top