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 6255057
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T14:17:40+00:00 2026-05-24T14:17:40+00:00

I have extended DotNetOpenAuth ASP.NET MVC Login sample while trying to get at least

  • 0

I have extended DotNetOpenAuth ASP.NET MVC Login sample while trying to get at least an email from the OpenID provider. No matter which provider I use to log in, I get null for ClaimsResponse. Here is the code.

var request = openid.CreateRequest(Request.Form["OpenID"]);
// Require some additional data
request.AddExtension(new ClaimsRequest
                            {
                                Email = DemandLevel.Require,
                            });
return request.RedirectingResponse.AsActionResult();

And this is the snippet to get the ClaimsResponse:

switch (response.Status)
{
    case AuthenticationStatus.Authenticated:
        var claimsResponse = response.GetExtension<ClaimsResponse>();
        // This is null!
        break;
}

Before trying this on the MVC sample, I have done the same on WebForms sample and got back the requested email! But this is really hard to get wrong as OpenID related code is virtually the same.

I have noticed that generated OpenID URLs differ in the following: openid.ns.alias3=http://openid.net/srv/ax/1.0&openid.alias3.required=alias1,alias2,alias3,alias4&openid.alias3.mode=fetch_request&openid.alias3.type.alias1=http://axschema.org/contact/email&openid.alias3.count.alias1=1&openid.alias3.type.alias2=http://axschema.org/namePerson&openid.alias3.count.alias2=1&openid.alias3.type.alias3=http://schema.openid.net/contact/email&openid.alias3.count.alias3=1&openid.alias3.type.alias4=http://schema.openid.net/namePerson&openid.alias3.count.alias4=1. Basically, the WebForms version generates an URL with all of that appended while the MVC URL lacks this. The net effect is that email is presented to WebForms while there is none for a MVC app.

One last thing I noticed is that e.g. Google shows as if request comes from localhost for a WebForms app and 127.0.0.1 for a MVC app. Maybe that makes all the difference. Still, I am not sure if I am in control here.

The thing that bothers me is that the code is the same for both projects. Still the URLs generated are different and MVC gets no email.

  • 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-24T14:17:41+00:00Added an answer on May 24, 2026 at 2:17 pm

    It sounds like your web forms site has the AXFetchAsSreg behavior activated but your MVC one does not. Activate it for your MVC site and you should be good.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have extended the ASP.NET MVC Html Helper to include my own ValidationImage that
I have an extended GridView class, GridViewEx, which inherits from the basic ASP.NET gridview.
I have an existing site build in c# 3.5 using asp.net mvc 1. There
I am trying to draw an animation. To do so I have extended View
I have to open a page from class extended from javax.swing.AbstractAction class... Is that
I have extended an mxml component with an actionscript class. I'm trying to access
I have an ASP.NET 3.5 application (on IIS 6.0) which uses ASP.NET forms authentication.
I have setup an ASP.NET MVC3 website using Windows Authentication and am getting a
I have extended regexes enabled in my Bash by shopt -s extglob They may
I have extended my entities to implement specific interfaces for its type. I am

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.