myLittleTools Community Forum

Welcome Guest Search | Active Topics | Members | Log In | Register

System.Web.AspNetHostingPermission error with IIS7 Options · View
elian
Posted: Friday, March 12, 2010 2:36:59 PM

Rank: Administration
Groups: Administration

Joined: 9/11/2006
Posts: 605
Points: 649
Location: Enghien Les Bains, France
If you're getting this error when installing myLittleAdmin on IIS7:

Code:
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.


Change your application pool setting "Load User Profile" to true.

Check this great article
http://dbvt.com/blog/post/AspNetHostingPermission-Security-Exception-Fix-with-Ajax-in-IIS7.aspx

Explanations about Application Pool Identities can be found here:
http://learn.iis.net/page.aspx/624/application-pool-identities/

elian
Posted: Tuesday, April 06, 2010 2:44:03 PM

Rank: Administration
Groups: Administration

Joined: 9/11/2006
Posts: 605
Points: 649
Location: Enghien Les Bains, France
Here is another explanation, when the virtual directory points to a remote share in ASP.NET

http://support.microsoft.com/?id=320268

elian
Posted: Wednesday, April 07, 2010 7:59:52 AM

Rank: Administration
Groups: Administration

Joined: 9/11/2006
Posts: 605
Points: 649
Location: Enghien Les Bains, France
For those of you using myLittleAdmin from Plesk Install :
"Load user profile" must be true for "Plesk (Defaul)t (2.0) (Pool)"





cyberhostpro
Posted: Monday, August 29, 2011 1:24:08 AM
Rank: Newbie
Groups: Member

Joined: 10/1/2010
Posts: 3
Points: 9
Location: UK
Hi

I've got 32bit = true and load user profile to true but i still get an error.

we use SAN for cloud hosting so the files are on a network share. i executed this command to allow permissions to the san:

c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\caspol.exe -m -ag 1 -url "file:////\\enkompass-san\san*" FullTrust -exclusive on


the error from event viewer:

Code:
Event code: 3008
Event message: A configuration error has occurred.
Event time: 29/08/2011 01:15:43
Event time (UTC): 29/08/2011 00:15:43
Event ID: 0abe754ef7904f8ea9e4c5b75d437216
Event sequence: 25
Event occurrence: 24
Event detail code: 0

Application information:
    Application domain: /LM/W3SVC/61/ROOT-1-129590504435481211
    Trust level: Full
    Application Virtual Path: /
    Application Path: \\enkompass-san\san\Users\cPanel\chrisd85\public_html\mlb\
    Machine name: ENKOMPASS-WEB1

Process information:
    Process ID: 3936
    Process name: w3wp.exe
    Account name: ENKOMPASSAD1\chrisd85

Exception information:
    Exception type: ConfigurationErrorsException
    Exception message: Request for the permission of type 'System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed. (\\enkompass-san\san\Users\cPanel\chrisd85\public_html\mlb\web.config line 21) (\\enkompass-san\san\Users\cPanel\chrisd85\public_html\mlb\web.config line 21)

Request information:
    Request URL: http://mlb.myenkompass.com/default.aspx
    Request path: /default.aspx
   
    User: 
    Is authenticated: False
    Authentication Type: 
    Thread account name: ENKOMPASSAD1\chrisd85

Thread information:
    Thread ID: 4
    Thread account name: ENKOMPASSAD1\chrisd85
    Is impersonating: False
    Stack trace:    at System.Web.Configuration.HttpModuleAction.get_Entry()
   at System.Web.Configuration.HttpModulesSection.CreateModules()
   at System.Web.HttpApplication.InitModules()
   at System.Web.HttpApplication.InitInternal(HttpContext context, HttpApplicationState state, MethodInfo[] handlers)
   at System.Web.HttpApplicationFactory.GetNormalApplicationInstance(HttpContext context)
   at System.Web.HttpApplicationFactory.GetApplicationInstance(HttpContext context)
   at System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)



I tried emailing support a few days ago but did not get a response.

I have this error on both MLA and MLB that i am trying to move to new servers, it works on old 2003 hosting server, new server is 2008 R2.



Chris Danks
Cyber Host Pro Ltd - UK Hosting Solutions
elian
Posted: Tuesday, August 30, 2011 1:29:24 PM

Rank: Administration
Groups: Administration

Joined: 9/11/2006
Posts: 605
Points: 649
Location: Enghien Les Bains, France
Hi Chris
Could you please send your email again at support [@] mylittletools.net

Remote-accessing your server could be interesting

Users browsing this topic
Guest


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Main Forum RSS : RSS

Theme created by myLittleTools
Powered by Yet Another Forum.net version 1.9.1.8 (NET v2.0) - 3/29/2008
Copyright © 2003-2008 Yet Another Forum.net. All rights reserved.