security execption

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

Guest

I have an asp.net (C#) web form that needs to run an exe off of a network
drive and when i load the page i'm getting the following error message:
The application attempted to perform an operation not allowed by the
security policy. To grant this application the required permission please
contact your system administrator or change the application’s trust level in
the configuration file.

Now, I'm running IIS 5 and I've tried on this says:
http://support.microsoft.com/?kbid=555466&SD=tech
but IIS 5 doesnt have application pools, and I tried it on my test box
which is running IIS 6 but i still got the error message.

how can i run an exe from a network share via an asp.net web form?
 
CsharpGuy,

I haven't done this myself, but what little I've come across has always been
about using PInvoke in order to run the application via a specified user
account that will have the proper permissions.

This blog post may help:
http://west-wind.com/weblog/posts/1572.aspx

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche
 
thanks, i'll check that out. but what is going on is this:
I have a DLL created in c# and it calls a exe on a network shared drive. The
DLL is then referenced on my web page and my web pages calls the DLL and when
i load my page i get the security error message. BUT, i created a windows
tester app and called the same DLL the same way,. etc and the windows apps
works fine, so what is different between windows security and a web app
security?
 
CsharpGuy,

The big difference there would be that the windows application is running as
you. When the .dll is called the application is using the same network
permissions you have.

The web app runs as (If you didn't change it) IUSR_[MachineName]. You could
look into user impersonation from a web application in order to load the
..dll by creating a network account to run the website as.

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche
 
Back
Top