This project is read-only.

Unable to obtain public key for StrongNameKeyPair

Topics: Installing Orchard
Mar 3, 2011 at 3:19 AM

This is a first-time-ever installation of Orchard via Web Platform Installer, on Win Vista.  Installation apparently went OK, but launching yields the error as shown in the subject.

I've included the Source Error, but I suppose that most of the stack trace is likely TMI so have excluded it.  Any ideas on what the problem is?

Unable to obtain public key for StrongNameKeyPair

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.ArgumentException: Unable to obtain public key for StrongNameKeyPair.

Source Error:

Line 13: @Display(Model.Messages)
Line 14: <div id="main">
Line 15: @Display(Model.Content)
Line 16: </div>

Source File: c:\Users\Owner\Documents\My Web Sites\orchard\Themes\SafeMode\Views\Layout.cshtml    Line: 15

Stack Trace:

[ArgumentException: Unable to obtain public key for StrongNameKeyPair.]
   System.Reflection.StrongNameKeyPair.ComputePublicKey() +201
   System.Reflection.StrongNameKeyPair.get_PublicKey() +20
Mar 15, 2011 at 5:18 AM

First, please check that your web server is configured to run .NET 4.0

Mar 20, 2011 at 5:12 PM
Edited Mar 20, 2011 at 5:13 PM

I had the same issue.
The error is related to ACL on folder C:\ProgramData\Microsoft\Crypto\RSA; I solved it binding Orchard WebSite to an AppPool running as LocalService.
I know it's not so good for security, so you can also use a specific user with full permissions on RSA folder.

Hope this helps,


Jul 20, 2011 at 12:42 AM

Is this issue resolved now for you cyberherbalist?

Aug 30, 2011 at 5:59 AM

A duplicate thread for this one ...