TechWandering random header image
TechWandering
TechWandering
wandering the world of technology
wandering the world of technology
 

 

Log into OpenID sites using your own URL

October 19th, 2007 · 37 Comments

In a previous post I talked about the benefits of OpenID-enabled web sites. In a nutshell, OpenID promises to let you use the same logon credentials across multiple sites rather than having to create a new username and password at each site you visit. If you manage your own web site (or even a page on a web site) you can use your site’s URL instead of your OpenID provider’s URL. That means that you can log to OpenID-enabled sites using a “friendly” OpenID name (something like “techwandering.com”) instead of your OpenID provider’s name (like “techwandering.myopenid.com”). Here’s how.

An OpenID Refresher

OpenID is a distributed system which allows users to log into an OpenID-enabled web site using an OpenID URL instead of the traditional username/password combination. The idea is that a user can choose their OpenID provider and use that provider to log into any OpenID-enabled site. Think of it as a way to allow a web site to outsource its login procedure to a third party.

Using your own web page

The way we’re able to use our own web page URL instead of our OpenID provider’s URL is by adding an extra “hop” to the whole OpenID authentication process. You’ll remember from the original post about how OpenID works that the normal flow of an OpenID logon goes like this:

  • The user navigates to an OpenID-enabled web site (like http://wikitravel.org)
  • Instead of entering a normal username/password combination, the user enters his OpenID username (like techwandering.myopenid.com)
  • The web site parses the OpenID username and redirects the user to their OpenID provider (in this case, to http://myopenid.com)
  • The user logs into his account at the OpenID provider
  • After successfully logging in the user gets bounced back to the original web site (http://wikitravel.org)
  • The user is now logged in

An Example

Using the example above, let’s say that I have an OpenID account named “techwandering” at the OpenID provider myopenid.com. That would make my OpenID login “techwandering.myopenid.com”. I could go to any OpenID-enabled web site (like WikiTravel.org) and use that URL to log into the site. Although that URL works, it’s a bit “wordy”. Since I can edit pages on the TechWandering web site I can set make a change to the main page which will allow me to use the URL “techwandering.com” to log into my “techwandering.myopenid.com” OpenID account using an OpenID feature called delegate.

To do that we’ll have to add a bit of code into the HTML of the main page of TechWandering. The code goes into the <head> section of the page, and it looks like this:

<link rel=”openid.server” href=”http://www.myopenid.com/server” />
<link rel=”openid.delegate” href=”http://techwandering.myopenid.com” />

Here’s the flow of our OpenID login now (the additional steps are in bold):

  • The user navigates to an OpenID-enabled web site (like http://wikitravel.org)
  • Instead of entering a normal username/password combination, the user enters his OpenID username. In this case I’ll enter the URL “techwandering.com”.
  • The web site parses the OpenID username and redirects the user to their OpenID provider (in this case, to http://techwandering.com)
  • The web site at techwandering.com does not indicate that it’s an OpenID provider. At this point the OpenID processor at WikiTravel looks for the two <link> tags listed above. The first <link> tag tells the WikiTravel server what OpenID server to use to process the login. The second <link> tag tells the OpenID server what username “techwandering.com” actually translates to at that provider.
  • The user is redirected to the “real” OpenID provider (myopenid.com)
  • The user logs into his account at the OpenID provider
  • After successfully logging in the user gets bounced back to the original web site (http://wikitravel.org)
  • The user is now logged in.

Use any page

The nice thing about this approach is that I’m not limited to using the root page of my web site. Instead of using “techwandering.com” as my OpenID login I can use a subdirectory under that root — for instance, I can use “techwandering.com/frank” or “techwandering.com/ralph”, or even “techwandering.com/george/myopenidpage.html”. As long as you can edit the HTML of a page you can use that page as your OpenID username.

Change OpenID providers without changing your OpenID login

Using this OpenID redirection approach also gives me additional flexibility when it comes to choosing my OpenID provider. In our example I’ve logged into WikiTravel using the OpenID “techwandering.com”, which actually translates to the OpenID “techwandering.myopenid.com”. The WikiTravel web site knows me by my “techwandering.com” name, and any preferences I set at that site are linked to that username. Let’s say that, at some point in the future, the folks at myopenid.com decide that they’re no longer going to be OpenID providers. If I had an account at WikiTravel tied directly to my techwandering.myopenid.com account I wouldn’t be able to log into my WikiTravel account any more. But since I used techwandering.com as my OpenID name I can just create another OpenID account at another OpenID provider and change the code in the <link> tags on my web page to point to that new provider instead of to myopenid.com. The next time I log into WikiTavel it bounces me through my new provider instead of through the old provider. From WikiTravel’s perspective I’m still logged in as techwandering.com, regardless of what my underlying OpenID provider turned out to be.

Some Examples

Remember, the values in the <link> tags of our example tell the OpenID processor two things:

<link rel=”openid.server” href=”http://www.myopenid.com/server” />
<link rel=”openid.delegate” href=”http://techwandering.myopenid.com” />

The first link above tells the OpenID processor where to go to find the OpenID provider. The second link tells the processor what the full OpenID username is going to be when the user gets to that OpenID provider. Here are two examples using other OpenID providers:

using Verisign Labs (http://pip.verisignlabs.com) as an OpenID provider:

<link rel=”openid.server” href=”https://pip.verisignlabs.com/server” />
<link rel=”openid.delegate” href=”http://techwandering.pip.verisignlabs.com” />

using SignOn (http://signon.com) as an OpenID provider:

<link rel=”openid.server” href=”https://www.signon.com/openidProcessing.action” />
<link rel=”openid.delegate” href=”https://techwandering.signon.com” />

Conclusion

If you’re a user of OpenID and you own some sort of web page go ahead and try out using that page as your OpenID identifier — it makes remembering your OpenID easier and it insulates you from being bound to a specific OpenID provider. And that makes an already open system even more “open”.

Related Posts

  • OpenID — a unified identity management system for the internet
  • Watch streaming internet video channels on your TV with PlayOn
  • Shadows, Flickr, and Flock – Oh My!
  • Surf the web faster and safer with OpenDNS
  • SandboxIE – a Little Write-of-Hand
  •  

    Tags: Internet

    37 responses so far ↓

    • 1 Chris // Feb 11, 2008 at 8:39 pm

      Are there any dependents on making this work other than the entries in the head section? I have tried to get this to work on my blog using your instructions but haven’t had any luck. Any help would be appreciated!

    • 2 Ed // Feb 13, 2008 at 11:12 am

      Hey, Chris,

      You really shouldn’t need anything other than those entries in your “head” section. Here’s a web page which you can use to check out your configuration:

      http://www.openidenabled.com/resources/openid-test/

      Click on the “Test your server” link and type in the name of the website you’re trying to use. At the very least is should show you whether or not it’s able to find and interpret your OpenID entries and should also be able to tell you what OpenID provider you’re trying to use.

    • 3 David Waite // May 8, 2008 at 12:46 pm

      Thanks for listing information about us at SignOn.com!

      Note that as of May 2008, our site structure has changed. The new header information (where techwandering should changed for your readers to their own account name) is supplied below.

    • 4 David Waite // May 8, 2008 at 12:49 pm

      Lets try posting that again, HTML-escaped:

      <link rel=”openid.server” href=”https://www.signon.com/partner/openid” />
      <link rel=”openid2.provider” href=”https://www.signon.com/partner/openid” />
      <link rel=”openid.delegate” href=”https://techwandering.signon.com” />
      <link rel=”openid.local_id” href=”https://techwandering.signon.com” />

    • 5 Dave // Mar 10, 2009 at 10:04 pm

      Hey there. Nice post but I’m having problems getting this to work with myopenid.com. I created an account as you said and in my wordpress theme’s header.php file I inputted the following just before the tag:

      But I am getting authentication errors when I try to log in with my website address. Any ideas why this could be?

    • 6 sandrar // Sep 10, 2009 at 4:32 pm

      Hi! I was surfing and found your blog post… nice! I love your blog. :) Cheers! Sandra. R.

    • 7 himublog // Jan 24, 2011 at 12:39 pm

      I donot know much about open id. can you provide some links where i can use my open id to log in.

    • 8 babyproductsreviews.org // Dec 4, 2012 at 4:50 am

      Τhis pоѕt is invaluablе. Hοw can I find
      оut mοrе?

      Herе is my blog – babyproductsreviews.org

    • 9 american love psychic // Dec 5, 2012 at 8:08 pm

      Hi there, i read your blog occasionally and i own a similar one and i was just curious if you get a lot of spam comments?
      If so how do you reduce it, any plugin or anything you can suggest?

      I get so much lately it’s driving me mad so any support is very much appreciated.

      Review my blog post :: american love psychic

    • 10 payday loans // Dec 9, 2012 at 6:44 pm

      What’s up, I desire to subscribe for this web site to obtain most recent updates, thus where can i do it please help out.

    • 11 oriflame // Jan 2, 2013 at 9:55 am

      Excellent, what a weblog it is! This blog provides useful
      facts to us, keep it up.

    • 12 women's Timberland boots // Jan 3, 2013 at 6:04 am

      I drop a comment whenever I appreciate a post on a site or I have something to add to
      the discussion. It’s triggered by the fire communicated in the post I read. And after this article Log into OpenID sites using your own URL | TechWandering. I was actually excited enough to write a thought :-) I actually do have 2 questions for you if you don’t mind.
      Could it be just me or does it look as if like a few of the comments come across as if they are left by
      brain dead individuals? :-P And, if you are posting on other online
      sites, I would like to follow you. Could you make a list all of your communal
      pages like your linkedin profile, Facebook page or
      twitter feed?

      my website – women’s Timberland boots

    • 13 check this out. more info // Jan 3, 2013 at 6:56 pm

      Good day I am so happy I found your webpage, I really found you by accident,
      while I was browsing on Bing for something else, Nonetheless I am
      here now and would just like to say many thanks for a remarkable
      post and a all round interesting blog (I also love the theme/design), I don’t have time to read it all at the moment but I have bookmarked it and also included your RSS feeds, so when I have time I will be back to read a great deal more, Please do keep up the fantastic job.

    • 14 Loyd // Jan 6, 2013 at 6:52 pm

      When you receive a pay day loan for the wrong reason, you’re using your credit rating. To find out about how to find your business cash advance, look at this article. Apply for some cash, get help, and pay the money back over a few weeks with same day payday cash advances.

    • 15 Mittie // Jan 6, 2013 at 11:04 pm

      Image 23. Phuket is undoubtedly the best gift by the Mother Nature to the
      mankind. Lessen your Carbon Impact: Travel, Purchasing & Holiday Cards – Minimizing the co2 presence is probably the
      very best actions during the holidays –especially with
      all the current vacation along with time you generally devote within vehicles, educates or aircraft.

    • 16 Madonna // Jan 9, 2013 at 9:00 pm

      I just could not depart your web site before suggesting that I really
      enjoyed the standard info a person supply for your guests?
      Is gonna be again frequently to check up on new posts

    • 17 Francine // Jan 17, 2013 at 4:41 am

      Hiya very nice web site!! Guy .. Beautiful .. Amazing
      .. I’ll bookmark your web site and take the feeds additionally? I am happy to find so many useful information here within the submit, we need develop more techniques in this regard, thanks for sharing. . . . . .

    • 18 elite pain // Jan 21, 2013 at 12:35 am

      Awesome blog! Do you have any suggestions for aspiring writers?
      I’m hoping to start my own website soon but I’m a little lost on
      everything. Would you suggest starting with a free
      platform like WordPress or go for a paid option? There are so many options out
      there that I’m totally overwhelmed .. Any recommendations? Thanks a lot!

    • 19 яࡱ // Jan 23, 2013 at 10:32 pm

      I like the valuable information you provide in your articles.
      I’ll bookmark your blog and check again here frequently. I’m quite sure I will learn plenty of new
      stuff right here! Best of luck for the next!

    • 20 how to hack facebook accounts for free // Jan 24, 2013 at 7:05 pm

      There’s definately a great deal to find out about this subject. I really like all the points you’ve made.

      Viѕіt my page how to hack facebook accounts for free

    • 21 Monetizing techniques // Feb 6, 2013 at 6:01 pm

      IF YOUR LOOKING TO MAKE SOME MONEY ONLINE IN HUNDREDS
      OF DIFFERENT WAYS OR SEO YOUR WEBSITE/BLOG CHECK OUT http://onlinemonetizingtechniques.

      blogspot.com

    • 22 turbulence fear // Feb 8, 2013 at 3:11 am

      I’m really enjoying the theme/design of your site. Do you ever run into any internet browser compatibility issues? A small number of my blog audience have complained about my site not working correctly in Explorer but looks great in Opera. Do you have any advice to help fix this issue?

    • 23 free directory list // Feb 10, 2013 at 4:04 am

      I was suggested this blog by my cousin. I’m not sure whether this post is written by him as no one else know such detailed about my trouble. You’re wonderful!
      Thanks!

    • 24 Get Free Facebook Credits // Feb 11, 2013 at 4:54 am

      What’s up, this weekend is nice for me, because this point in time i am reading this wonderful informative paragraph here at my home.

    • 25 iimeeting.com // Feb 12, 2013 at 12:31 am

      Hi there would you mind stating which blog platform you’re working with? I’m going to start
      my own blog in the near future but I’m having a difficult time choosing between BlogEngine/Wordpress/B2evolution and Drupal. The reason I ask is because your design and style seems different then most blogs and I’m looking for something completely unique.

      P.S My apologies for being off-topic but I had to ask!

    • 26 make rosary // Mar 22, 2013 at 2:33 pm

      Hi mates, how is all, and what you desire to say about this post, in
      my view its genuinely amazing in favor of me.

    • 27 netseriale.pl // Apr 6, 2013 at 12:09 pm

      Yes! Finally something about series 7 exam courses.

    • 28 Garry // Apr 9, 2013 at 11:52 pm

      This post gives clear idea in favor of the new viewers of
      blogging, that actually how to do blogging.

    • 29 Kevin // Apr 13, 2013 at 11:36 am

      Because the admin of this website is working, no hesitation very shortly it
      will be renowned, due to its quality contents.

    • 30 Omar // Apr 13, 2013 at 5:55 pm

      Nice respond in return of this difficulty with real arguments and describing everything about that.

    • 31 seprince review // Apr 14, 2013 at 3:09 pm

      Hi just wanted to give you a quick heads up and let you know a few of the pictures aren’t loading properly. I’m not sure why but I think its a linking issue.
      I’ve tried it in two different internet browsers and both show the same results.

    • 32 Jens // Apr 15, 2013 at 4:45 am

      I love your blog.. very nice colors & theme.
      Did you design this website yourself or did
      you hire someone to do it for you? Plz respond as I’m looking to create my own blog and would like to know where u got this from. thank you

    • 33 how i met your mother season 9 episode 20 // Apr 15, 2013 at 5:00 am

      Having read this I thought it was extremely enlightening.
      I appreciate you spending some time and energy to put this informative article together.
      I once again find myself personally spending way too much time both reading and commenting.
      But so what, it was still worth it!

    • 34 Geraldine // Apr 15, 2013 at 5:13 am

      Unquestionably consider that that you stated. Your favourite justification appeared to be on the net the simplest factor
      to be aware of. I say to you, I certainly get annoyed at the same time as
      other folks consider worries that they plainly do not know
      about. You managed to hit the nail upon the highest and also defined
      out the whole thing with no need side-effects , other people can take a signal.
      Will probably be back to get more. Thanks

    • 35 Kumar oyna // Apr 18, 2013 at 8:17 am

      I do not know if it’s just me or if perhaps everyone else experiencing problems with your site. It appears as though some of the text within your posts are running off the screen. Can somebody else please provide feedback and let me know if this is happening to them as well? This could be a problem with my web browser because I’ve had this
      happen before. Cheers

    • 36 Kumar oyna // Apr 19, 2013 at 7:22 am

      It’s a pity you don’t have a donate button! I’d certainly donate to this excellent blog! I guess for now i’ll
      settle for book-marking and adding your RSS feed
      to my Google account. I look forward to new updates
      and will share this website with my Facebook group.
      Chat soon!

    • 37 personal shopper // Apr 26, 2013 at 3:52 am

      Several very good specifics listed here and definitely didn’t have a idea regarding almost any of this formerly so cheers for the perception

    Leave a Comment