Hello-
Platform:
- web server using IIS 6 connecting to UNC share on separate file
server
- Both servers are Windows 2003 with dotNetFramework 2.0
General:
- basic ASP.NET pages work fine in this situation
- However, if I'm calling a DLL (located in the bin directory), I get
the following error:
Error:
Security Exception
Description: 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.
Exception Details: System.Security .SecurityExcept ion: Request for the
permission of type 'System.Web.Asp NetHostingPermi ssion, System,
Version=2.0.0.0 , Culture=neutral , PublicKeyToken= b77a5c561934e08 9'
failed.
Source Error:
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace
below.
_________
The Event Log shows the following:
Source: ASP.NET 2.0.50727.0
Event Id: 1310
Event code: 3008
Event message: A configuration error has occurred.
Event sequence: 11
Event occurrence: 5
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/2908527797/Root/
forms-6-128231063458178 510
Trust level: Full
Application Virtual Path: /forms
Application Path: \\servername\sh are\webapp\fold er\
Process information:
Process ID: 2752
Process name: w3wp.exe
Account name: domain\IWAM_WEB
Exception information:
Exception type: ConfigurationEr rorsException
Exception message: Request for the permission of type
'System.Web.Asp NetHostingPermi ssion, System, Version=2.0.0.0 ,
Culture=neutral , PublicKeyToken= b77a5c561934e08 9' failed. (\\servername
\share\webapp\f older\web.confi g line 18)
Request information:
Request URL: http://www.domain.com/folder/filename.aspx
Request path: /folder/filename.aspx
User:
Is authenticated: False
Authentication Type:
Thread account name: domain\IWAM_WEB
_________
Appropriate code (and source of error) in web.config:
<httpHandlers >
<add verb="GET" path="filename. aspx"
type="WebContro lCaptcha.Captch aImageHandler, WebControlCaptc ha"/>
</httpHandlers>
_________
The Event Log seems to confirm I have a full trust to the UNC on the
file server. However, I'm not using impersonation. (Is this needed?)
This application works fine in a single-server testing environment,
(with no UNC share). Your help is greatly appreciated.
Steve