Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6051671
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T07:50:39+00:00 2026-05-23T07:50:39+00:00

I’m attempting to get OpenID authentication to work in my Azure ASP.NET MVC 3

  • 0

I’m attempting to get OpenID authentication to work in my Azure ASP.NET MVC 3 application and have followed the steps in the MVC 3 Custom Login Sample to do so. Everything works fine in the development environment but not when deployed to the Azure platform.

The first issue started with authentication causing the error “Key not valid for use in specified state”. The discussion here states that the application needs to be configured to use RsaEncryptionCookieTransform instead of DPAPI which is the default. To try and solve this I added the code for OnServiceConfigurationCreated described on Alik Levin’s blog but didn’t go any further as it describes setting up a self-signed certificate in development (which as mentioned hasn’t been necessary), not in Azure.

Instead of that approach, I tried to use the X.509 certificate already in Azure. I found the thumbprint under Windows Azure Management > Access Control Service > Relying Party Applications > (My Application Name) > Token Signing Certificates > Used for Service Namespace (X.509 Certificate). I then added this reference to the web.config:

<serviceCertificate>
    <certificateReference x509FindType="FindByThumbprint" findValue="8A417..." />
</serviceCertificate>

Now I receive a configuration error on application startup:

ID1024: The configuration property value is not valid.
Property name: 'certificateReference'
Error: 'ID1025: Cannot find a unique certificate that matches the criteria.
StoreName: 'My'
StoreLocation: 'LocalMachine'
X509FindType: 'FindByThumbprint'
FindValue: '8A417...''

Do I actually need to change the encryption method to resolve the “Key not valid for use in specified state” error? If so, how can I use the X.509 certificate already in Azure to encrypt cookies?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T07:50:39+00:00Added an answer on May 23, 2026 at 7:50 am

    Eventually I found (again) the article Securing Windows Azure Web Role ASP.NET Web Application Using Access Control Service v2.0. After reconfiguring the web.config and the “Relying Party Applications” section of the ACS Management Portal according to this article, I was able to get everything to work. Specifically I wanted only those controller actions decorated with RequireAuthentication, as shown in the ACS 2.0 sample for this tutorial, to require the user to be logged in. This now works.

    The only downside is that the entire app has to run in SSL for the user experience to be seamless. Otherwise the user is prompted for auth when running in HTTP, authenticated, and then dumped back to HTTP apparently not authenticated. However, switching over to the SSL endpoint, the user has been authenticated!

    In development fabric this was working as I wanted, Stack Overflow style, where I was able to run everything in standard HTTP without using a certificate and authentication happened over SSL. However because of the RSA cookie requirement in Azure and need for a certificate this won’t work in the cloud. (It would be great if dev fabric warned about this and other common gotchas.) I hope to revisit this at some point in the future.

    In summary, I recommend you understand Windows Identity Foundation and how it applies to Azure before attempting anything beyond the provided samples. Some resources available at time of writing:

    • TechNet Wiki for Azure (specifically articles about ACS and WIF)
    • ClaimsID (CodePlex)
    • ACS (CodePlex)
    • Programming Windows Identity Foundation (book)
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I have an MVC Razor view @{ ViewBag.Title = Index; var c = (char)146;
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have just tried to save a simple *.rtf file with some websites and
I have a jquery bug and I've been looking for hours now, I can't
this is what i have right now Drawing an RSS feed into the php,
I have this code to decode numeric html entities to the UTF8 equivalent character.
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.