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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T12:23:17+00:00 2026-05-31T12:23:17+00:00

I use DNOA for authentication + authorization with google in my website. http://ugi-2.apphb.com/Authentication.htm When

  • 0

I use DNOA for authentication + authorization with google in my website.

http://ugi-2.apphb.com/Authentication.htm

When I run on local host I get this error

return_to 'http://localhost:8976/Register/Login' not under realm 'http://anonymous/'.

from this piece of code:

 private void HandleAuthNullResponse(IAuthenticationResponse authResponse)
        {
            // Google requires that the realm and consumer key be equal,
            // so we constrain the realm to match the realm in the web.config file.
            // This does mean that the return_to URL must also fall under the key,
            // which means this sample will only work on a public web site
            // that is properly registered with Google.
            // We will customize the realm to use http or https based on what the
            // return_to URL will be (which will be this page).

            var consumer = new WebConsumer(GoogleConsumerHelper.ServiceDescription, mConsumerTokenManager);

            //Realm realm = "http://localhost:8976/";
            Realm realm = System.Web.HttpContext.Current.Request.Url.Scheme + Uri.SchemeDelimiter + consumer.ConsumerKey + "/";
            IAuthenticationRequest authReq = GoogleConsumerHelper.RelyingParty.CreateRequest(GoogleConsumerHelper.GoogleOPIdentifier, realm);

the error fits somehow what is commented by DNOA

It was strange as I saw other code that works for localhost but is much less structured.

I then turned to google site and saw:

Registering your web application

There are three levels of registration:

  1. Unregistered: Application is not recognized by Google. The Access
    Request page, which prompts your users to either grant or deny access
    for your application, displays this caution highlighted in yellow:
    “This website has not registered with Google. We recommend that you
    continue the process only if you trust this destination.”

  2. Registered: …

  3. Registered with enhanced security: …

Registration is optional but recommended. …

I even tried to publish on appHarbor and that didn’t help (don’t have logs there yet)

How can I work this out?

  • 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-31T12:23:18+00:00Added an answer on May 31, 2026 at 12:23 pm

    The error message your seeing is because the OpenID spec requires that the return_to URL be a derivative of the realm URL, and obviously in your case it isn’t. http://localhost/ doesn’t fall anywhere under http://anonymous/. If you set your realm to your site’s actual root URL so that return_to is under it, this error should go away.

    I’d be interested in seeing the documentation from Google that says it accepts a realm of http://anonymous/ and a return_to any something other than anonymous.

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

Sidebar

Related Questions

Use http://jobs.sitesixteen.com/ for reference. I'm using YQL for the city, state auto-complete. IF you
use LWP::Simple; use Parallel::ForkManager; @links=( [http://prdownloads.sourceforge.net/sweethome3d/SweetHome3D-2.1-windows.exe,SweetHome3D-2.1-windows.exe], [http://prdownloads.sourceforge.net/sweethome3d/SweetHome3D-2.1-macosx.dmg,SweetHome3D-2.1-macosx.dmg], [http://prdownloads.sourceforge.net/sweethome3d/SweetHome3DViewer-2.1.zip,SweetHome3DViewer-2.1.zip], ); # Max 30 processes for
use this website a lot but first time posting. My program creates a number
use Rack::Static, :urls => ['/stylesheets', '/images'], :root => 'public' run proc { |env| [200,
Use Case When a user goes to my website, they will be confronted with
use Control::CLI; $cli = new Control::CLI('SSH'); $cli->connect(Host=>'10.10.10.10',Username=>'user',Password=>'pwd'); $cli->waitfor('>'); $cli->print('Show XXXXXXXXXXXXXXXXXXXX| grep Active'); @f=$cli->waitfor('>'); print
use WWW::Mechanize; my $mech = WWW::Mechanize->new; $mech->get( $url ); say $mech->text; How could I
Use case: User launches app The user enters google password The app lets the
use pthread_create to create limited number of threads running concurrently Successfully compile and run
Use of Unassigned local variable 'model'. Is what error message I'm getting. Its right

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.