Security Exception Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42

W

wenning

Hello,

I am struggling with a website on a W2K3 server which has the actual
content on a NAS server (also W2K3 based). The servers doesn't run in a
domain and arent intended to.

I did make the web space on the W2K3 IIS Server and pointed it to the
NAS server via an UNC path (no virtual directory).

When I place the content on the IIS, everything works fine, but when I
want to use the content on the NAS, I get the following error message
in my IE :

Server Error in '/' Application.
--------------------------------------------------------------------------------

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.SecurityException: Request for the
permission of type 'System.Web.AspNetHostingPermission, System,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
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.


Stack Trace:


[SecurityException: Request for the permission of type
'System.Web.AspNetHostingPermission, System, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
System.Reflection.Assembly.GetType(String name, Boolean
throwOnError, Boolean ignoreCase) +0
System.Web.UI.Util.GetTypeFromAssemblies(ICollection assemblies,
String typeName, Boolean ignoreCase) +140
System.Web.UI.TemplateParser.GetType(String typeName, Boolean
ignoreCase, Boolean throwOnError) +295
System.Web.UI.TemplateParser.ProcessInheritsAttribute(String
baseTypeName, String codeFileBaseTypeName, String src, Assembly
assembly) +163

System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary
parseData) +192




--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42;
ASP.NET Version:2.0.50727.42

My Event Log tells me :

Event code: 4010
Event message: An unhandled security exception has occurred.
Event time: 8/18/2006 4:47:59 PM
Event time (UTC): 8/18/2006 2:47:59 PM
Event ID: 39b77da5032a40a4ae4f3490228b47c6
Event sequence: 1
Event occurrence: 1
Event detail code: 0

Application information:
Application domain: /LM/W3SVC/1542597267/Root-4-128003860780000000
Trust level: Full
Application Virtual Path: /
Application Path: \\bullseye\Websites\www.digitalnews.nl\
Machine name: SEASPIKE

Process information:
Process ID: 608
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE

Request information:
Request URL: http://www.digitalnews.nl/Default.aspx
Request path: /Default.aspx
User host address: 192.168.150.20
User:
Is authenticated: False
Authentication Type:
Thread account name: SEASPIKE\IIS_Server

Custom event details:

For more information, see Help and Support Center at

Anyone an idea what could be wrong and how I can solve it ?
Help would be very much appreciated ! Thank you !

Regards,

Ferry Wenning
(e-mail address removed)
 
B

bruce barker \(sqlwork.com\)

by default the asp.net system account does not have network access, so unc
shares are not allowed. yu need to change the machine account to one that
has network access. also because you code will be runing from a share, it
run in a sandbox with restricted access. you will probably need to make the
share trusted.

-- bruce (sqlwork.com)


Hello,

I am struggling with a website on a W2K3 server which has the actual
content on a NAS server (also W2K3 based). The servers doesn't run in a
domain and arent intended to.

I did make the web space on the W2K3 IIS Server and pointed it to the
NAS server via an UNC path (no virtual directory).

When I place the content on the IIS, everything works fine, but when I
want to use the content on the NAS, I get the following error message
in my IE :

Server Error in '/' Application.
--------------------------------------------------------------------------------

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.SecurityException: Request for the
permission of type 'System.Web.AspNetHostingPermission, System,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
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.


Stack Trace:


[SecurityException: Request for the permission of type
'System.Web.AspNetHostingPermission, System, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
System.Reflection.Assembly.GetType(String name, Boolean
throwOnError, Boolean ignoreCase) +0
System.Web.UI.Util.GetTypeFromAssemblies(ICollection assemblies,
String typeName, Boolean ignoreCase) +140
System.Web.UI.TemplateParser.GetType(String typeName, Boolean
ignoreCase, Boolean throwOnError) +295
System.Web.UI.TemplateParser.ProcessInheritsAttribute(String
baseTypeName, String codeFileBaseTypeName, String src, Assembly
assembly) +163

System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary
parseData) +192




--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42;
ASP.NET Version:2.0.50727.42

My Event Log tells me :

Event code: 4010
Event message: An unhandled security exception has occurred.
Event time: 8/18/2006 4:47:59 PM
Event time (UTC): 8/18/2006 2:47:59 PM
Event ID: 39b77da5032a40a4ae4f3490228b47c6
Event sequence: 1
Event occurrence: 1
Event detail code: 0

Application information:
Application domain: /LM/W3SVC/1542597267/Root-4-128003860780000000
Trust level: Full
Application Virtual Path: /
Application Path: \\bullseye\Websites\www.digitalnews.nl\
Machine name: SEASPIKE

Process information:
Process ID: 608
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE

Request information:
Request URL: http://www.digitalnews.nl/Default.aspx
Request path: /Default.aspx
User host address: 192.168.150.20
User:
Is authenticated: False
Authentication Type:
Thread account name: SEASPIKE\IIS_Server

Custom event details:

For more information, see Help and Support Center at

Anyone an idea what could be wrong and how I can solve it ?
Help would be very much appreciated ! Thank you !

Regards,

Ferry Wenning
(e-mail address removed)
 
R

robbiesmith79

After fighting and reading for two hours, Here's my fix.

On IIS 6.0 , the website in question, the Home Directory needs to be a
directory located on this computer, not a UNC name ( or a share located
on another comptuer). Yes, it can still be a shared folder, but the
location needs to be drive:\folder

With half my hair missing,

Rob
 
R

robbiesmith79

After fighting and reading for two hours, Here's my fix.

On IIS 6.0 , the website in question, the Home Directory needs to be a
directory located on this computer, not a UNC name ( or a share located
on another comptuer). Yes, it can still be a shared folder, but the
location needs to be drive:\folder

With half my hair missing,

Rob
 
R

robbiesmith79

After fighting and reading for two hours, Here's my fix.

On IIS 6.0 , the website in question, the Home Directory needs to be a
directory located on this computer, not a UNC name ( or a share located
on another comptuer). Yes, it can still be a shared folder, but the
location needs to be drive:\folder

With half my hair missing,

Rob
 
W

wenning

Hi,

Thank you for submitting your tips and tricks.
It did the job, everything is working properly now !

Regards,

Ferry Wenning
 

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