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 ...Unverifiable Code Failed Policy CheckUnverifiable Code Failed Policy Check
Previous
 
Next
New Post
3/27/2013 2:52 PM
 
I just migrated my hosting solution to a new 64 bit server. Once I figured out the process I didn't really have to do anything special other than assign permissions to the correct web user to the files and confirm that I was using the same app pool .NET 2 Classic as on the other server.

Now I am trying to migrate an application with a bunch of custom DNN modules that is in DNN 5 to a new server and can't get it to work. I have the original module developer trying to help with this, but we cannot figure it out.

When I do the simple migration using the existing app pool and assign the correct permissions I initially get this error related to the ABCPDF tool we use to merge a group of reports into a single report.


Required permissions cannot be acquired.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

[PolicyException: Required permissions cannot be acquired.]
System.Security.SecurityManager.ResolvePolicy(Evidence evidence, PermissionSet reqdPset, PermissionSet optPset, PermissionSet denyPset, PermissionSet& denied, Boolean checkExecutionPermission) +7608739
System.Security.SecurityManager.ResolvePolicy(Evidence evidence, PermissionSet reqdPset, PermissionSet optPset, PermissionSet denyPset, PermissionSet& denied, Int32& securitySpecialFlags, Boolean checkExecutionPermission) +57 [FileLoadException: Could not load file or assembly 'ABCpdf, Version=6.1.0.7, Culture=neutral, PublicKeyToken=a7a0b3f5184f2169' or one of its dependencies. Failed to grant minimum permission requests.

So I did some research and found that the ABCPDF version 6 that we used doesn't work on 64-bit. We built this several years ago. Now there is a version 8 of ABCPDF that is 64-bit compliant. If I just try to copy the ABCPDF version 8 DLL that works with 64-bit into the bin folder I get this error below. I also get the same error if I just try to remove the ABCPDF.DLL from the bin folder.


Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.IO.FileLoadException: Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)

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:

[FileLoadException: Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)]
System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +0
System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +43
System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +127
System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +142
System.Reflection.Assembly.Load(String assemblyString) +28
System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +46

[Configurati sException: Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)]
System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +613
System.Web.Configuration.CompilationSection.LoadAllAssembliesFromAppDomainBinDirectory() +203
System.Web.Configuration.CompilationSection.LoadAssembly(AssemblyInfo ai) +105
System.Web.Compilation.BuildManager.GetReferencedAssemblies(CompilationSection compConfig) +178
System.Web.Compilation.BuildProvidersCompiler..ctor(VirtualPath configPath, Boolean supportLocalization, String outputAssemblyName) +54
System.Web.Compilation.CodeDirectoryCompiler.GetCodeDirectoryAssembly(VirtualPath virtualDir, CodeDirectoryType dirType, String assemblyName, StringSet excludedSubdirectories, Boolean isDirectoryAllowed) +600
System.Web.Compilation.BuildManager.CompileCodeDirectory(VirtualPath virtualDir, CodeDirectoryType dirType, String assemblyName, StringSet excludedSubdirectories) +125
System.Web.Compilation.BuildManager.CompileResourcesDirectory() +31
System.Web.Compilation.BuildManager.EnsureTopLevelFilesCompiled() +304

[HttpException (0x80004005): Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)]
System.Web.Compilation.BuildManager.ReportTopLevelCompilationException() +58
System.Web.Compilation.BuildManager.EnsureTopLevelFilesCompiled() +512
System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters) +729

[HttpException (0x80004005): Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +8921835
System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +85
System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr) +259

Version Information: Microsoft .NET Framework Version:2.0.50727.5466; ASP.NET Version:2.0.50727.5456

So I am not sure if the Unverifiable code failed policy check is totally unrelated to the ABCPDF DLL, or if it has to do with setting a reference in the VS solution or something else. If just copying in the new DLL is resolving the ABCPDF issue and this is something totally unrelated, do you have any idea what it is? I looked at a ton of related posts in Google but nothing specific is jumping out at me. It seems like it might have something to do with moving from a 32-bit server to a 64-bit server. But I am not sure.

I also did a DNN 6 upgrade on this site and tried to migrate that version but I got the exact same errors.

Thanks for any ideas you might have.

Forerunner Communications, LLC
DotNetNuke Integration Specialists

 
New Post
3/29/2013 6:30 AM
 

On IIS you can make things work in 32-bit mode:

https://help.webcontrolcenter.com/KB/...


Regards,
Christopher Koeber
 
New Post
3/29/2013 5:16 PM
 
When I contacted Websupergoo about the ABCPDF tool they suggested that it would not run on Win 2008. They didn't necessarily specify that it wouldn't run on 2008 64-bit mode. I have asked for some clarification. But I can say that for my first attempt to install this application I did set the App Pool to enable 32-bit applications. That had no impact and I had the same "Required permissions cannot be acquired. " error for ABCPDF. If I just totally remove the ABCPDF DLL OR if I replace it with a newer version, either 32 or 64-bit I get the "Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)" error. I have gone through dozens of posts in Google related to the Unverifiable code error and tried so many things but nothing is working.

I even tried a DNN 6 conversion on the old server which went ok. But when I migrated it over to the new server I am getting the exact same errors.

A little piece of additional information is that we used PinPDF to create PDF reports on the application and then used ABCPDF to merge all the individual PDFs into a single big report. I thought I should check to see if the PinPDF has any notices about not working on Win 2008 and I see this message on their site.

pinPDF is no longer sold from Pintexx.
pinPDF is a wrapper for the product ABCPDF from webSupergoo.
The wrapper source code for ActiveX and .Net version is available here:

pinPDF Source Code .Net
pinPDF Source Code ActiveX

So this might prove to be a bigger challenge than expected and we may have to totally rip out our current PDF solutions. If anyone knows of any better PDF solutions please let me know.

Thanks for any additional guidance anyone might have.

Forerunner Communications, LLC
DotNetNuke Integration Specialists

 
New Post
3/29/2013 5:17 PM
 
This double post occurred because I got a critical error when I first posted. So I hit the back button and did a reSubmit. Now I have two posts.

When I contacted Websupergoo about the ABCPDF tool they suggested that it would not run on Win 2008. They didn't necessarily specify that it wouldn't run on 2008 64-bit mode. I have asked for some clarification. But I can say that for my first attempt to install this application I did set the App Pool to enable 32-bit applications. That had no impact and I had the same "Required permissions cannot be acquired. " error for ABCPDF. If I just totally remove the ABCPDF DLL OR if I replace it with a newer version, either 32 or 64-bit I get the "Unverifiable code failed policy check. (Exception from HRESULT: 0x80131402)" error. I have gone through dozens of posts in Google related to the Unverifiable code error and tried so many things but nothing is working.

I even tried a DNN 6 conversion on the old server which went ok. But when I migrated it over to the new server I am getting the exact same errors.

A little piece of additional information is that we used PinPDF to create PDF reports on the application and then used ABCPDF to merge all the individual PDFs into a single big report. I thought I should check to see if the PinPDF has any notices about not working on Win 2008 and I see this message on their site.

pinPDF is no longer sold from Pintexx.
pinPDF is a wrapper for the product ABCPDF from webSupergoo.
The wrapper source code for ActiveX and .Net version is available here:

pinPDF Source Code .Net
pinPDF Source Code ActiveX

So this might prove to be a bigger challenge than expected and we may have to totally rip out our current PDF solutions. If anyone knows of any better PDF solutions please let me know.

Thanks for any additional guidance anyone might have.

Forerunner Communications, LLC
DotNetNuke Integration Specialists

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Unverifiable Code Failed Policy CheckUnverifiable Code Failed Policy Check


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