Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Security Exception Following Installation of .Net v 4.5Security Exception Following Installation of .Net v 4.5
Previous
 
Next
New Post
8/31/2012 9:55 PM
 

I just installed VS 2012 RTM which also installs the in-place upgrade of .Net framework v 4.0 to v 4.5.  All of my DNN module development sites (DNN v 5.6.7, v 6.1.5 and v 6.2.2) running on IIS 7.5 that are associated with ASP.Net 4.0 application pools (integrated pipeline) now throw the following unhandled server 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.SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.

Stack Trace:

[SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.]
   Telerik.Web.UI.RadUploadHttpModule.CaptureWorkerRequest(Object sender, EventArgs e) +0
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +80
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +165

--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.17929

If I change the Trust Level set in web.config from "Medium" to "Full" the error does not occur and each site appears to fuction as it did prior to the .Net 4.5 upgrade.

I've done extensive Google searches and checked the Telerik forums but have found no other mention of this requirement of elevating trust level for the Telerik RadUploadHttpModule following upgrade to ASP.Net 4.5.

Has anyone else run across this issue?


Bill, WESNet Designs
Team Lead - DotNetNuke Gallery Module Project (Not Actively Being Developed)
Extensions Forge Projects . . .
Current: UserExport, ContentDeJour, ePrayer, DNN NewsTicker, By Invitation
Coming Soon: FRBO-For Rent By Owner
 
New Post
9/1/2012 5:38 PM
 

Yes. I am seeing the same issue under a customized medium trust. Not sure of a fix at this point though unfortunately...

-Mike

 
New Post
9/1/2012 10:10 PM
 

So far all I can tell is that it seems to be something in ASP .NET 4.5 pipeline is throwing an exception whenever instantiating an object that inherits from HttpWorkerRequest. In the stacktrace you'll see the reference to Telerik.Web.UI.RadUploadHttpModule.CaptureWorkerRequest. This creates their "ProgressWorkerRequest" which inherits from System.Web.HttpWorkerRequest. Simply creating the object seems to trigger the exception, but still not sure why.

I was able to recreate the behavior via a simple implementation of IHttpModule and then in a simple ASP .NET web forms app. You can create your own type that inherits from HttpWorkerRequest have it implement the abstract class, then in your app simply create that type and you'll get the SecurityException. I also validated that this behavior does ~not~ occur pre-4.5.

-Mike

 
New Post
9/2/2012 4:26 PM
 

Adding UnmanagedCode flag to the SecurityPermission's IPermission flags seems to help.

Mike

 
New Post
9/5/2012 9:21 PM
 

Thanks, Mike, for your work in investigating this and reproducing the same error.

I just upgraded my DNN v 6.2.2 module development install to DNN v 6.2.3 which also updates Telerik.Web.UI.dll to v 2012.2.724.35. After changing the trust level from "Full" back to "Medium" in web.config the same security exception re-occurs. So, the Telerik.Web.UI assembly upgrade is of no help.

And, there's still no mention of this issue in the Telerik forums.


Bill, WESNet Designs
Team Lead - DotNetNuke Gallery Module Project (Not Actively Being Developed)
Extensions Forge Projects . . .
Current: UserExport, ContentDeJour, ePrayer, DNN NewsTicker, By Invitation
Coming Soon: FRBO-For Rent By Owner
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Security Exception Following Installation of .Net v 4.5Security Exception Following Installation of .Net v 4.5


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out