<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Dr Nic &#187; SocialOS</title>
	<atom:link href="http://drnicwilliams.com/category/socialos/feed/" rel="self" type="application/rss+xml" />
	<link>http://drnicwilliams.com</link>
	<description>Ruby makes Rails, Javascript makes Ajax, Dr Nic makes Magic</description>
	<lastBuildDate>Mon, 21 May 2012 03:31:50 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.3</generator>
		<item>
		<title>One App, One User Account and Multiple OpenIDs</title>
		<link>http://drnicwilliams.com/2007/07/20/one-app-one-user-account-and-multiple-openids/</link>
		<comments>http://drnicwilliams.com/2007/07/20/one-app-one-user-account-and-multiple-openids/#comments</comments>
		<pubDate>Fri, 20 Jul 2007 20:49:54 +0000</pubDate>
		<dc:creator>Dr Nic</dc:creator>
				<category><![CDATA[Essay]]></category>
		<category><![CDATA[OpenID]]></category>
		<category><![CDATA[SocialOS]]></category>

		<guid isPermaLink="false">http://drnicwilliams.com/2007/07/20/one-app-one-user-account-and-multiple-openids/</guid>
		<description><![CDATA[Summary: Its the future, and its not Facebook. Learn it. I&#8217;ve just implemented OpenID sign-ons for a client site, as a compliment for the standard signup/login process, and I choose the following association: 1 x User account &#8212;> 0 or 1 x OpenID The OpenID value is a field on my User model/table. So I [...]


Related posts:<ol><li><a href='http://drnicwilliams.com/2008/02/22/zero-sign-on-with-client-certificates/' rel='bookmark' title='Permanent Link: Zero Sign On &#8211; 1 better or Infinitely better than Single Sign On?'>Zero Sign On &#8211; 1 better or Infinitely better than Single Sign On?</a> <small>This article has no code in it. There are no...</small></li><li><a href='http://drnicwilliams.com/2007/09/11/myopenid-goes-down-multiple-openids-useful/' rel='bookmark' title='Permanent Link: Why supporting multiple OpenIDs per User is useful for users&#8230;'>Why supporting multiple OpenIDs per User is useful for users&#8230;</a> <small>Web apps/services go down for maintenance (expected or erroneously) all...</small></li><li><a href='http://drnicwilliams.com/2007/09/11/railsrumble-hates-openid/' rel='bookmark' title='Permanent Link: RailsRumble hates OpenID'>RailsRumble hates OpenID</a> <small>There are 146 RailsRumble entrants. %w[rubygems hpricot open-uri].each { |l|...</small></li></ol>]]></description>
			<content:encoded><![CDATA[<p><strong>Summary:</strong> Its the future, and its not Facebook. Learn it.</p>
<p>I&#8217;ve just implemented OpenID sign-ons for a client site, as a compliment for the standard signup/login process, and I choose the following association:</p>
<p>1 x User account &#8212;> 0 or 1 x OpenID</p>
<p>The OpenID value is a field on my User model/table.</p>
<p>So I login with my OpenID and I get one application account. </p>
<p>Or similarly, if the User already has an account, there is a field on their User settings page for their OpenID. They can put in their LiveJournal or AOL OpenID URL (or from one of 3000+ OpenID providers) there, and they can now log into that account using either normal login, or OpenID login.</p>
<p>Great.</p>
<p>But then I was watching a <a href="http://video.google.com/videoplay?docid=2288395847791059857">GoogleTechTalk video</a> by <a href="http://simonwillison.net/">Simon Willison</a> and he gave the following Bonus Use of OpenID:</p>
<ol>
<li>User logs into a site using an AOL OpenID</li>
<li>The site can now send AOL IM messages to that user</li>
</ol>
<p>This is cool for two reasons:</p>
<ol>
<li>The site automagically derived information about the User &#8211; they are an AOL member, and their AOL username.</li>
<li>More importantly, it KNOWS the user is the owner of that AOL account. </li>
</ol>
<p>The site gets authentication of this information for free through the OpenID sign-in process &#8211; the user is redirected back to AOL&#8217;s OpenID page at which time the user has to prove they own the account thru AOL signin (or cookies).</p>
<p>So, back to my story.</p>
<p>My users can sign into my site with an AOL OpenID and prove they own an AOL IM account name.</p>
<p>What if they also have a LiveJournal account? LiveJournal URLs are all OpenID URLs too [<a href="#1-lj">1</a>]</p>
<p>If they signed in with LiveJournal OpenID then they could prove they have such an account and my site could do funky LiveJournal specific things&#8230; like&#8230; read the user&#8217;s blog for them&#8230; ok, this example is going nowhere.</p>
<p>But! What is your MSN/Live account had an OpenID associated with it? Or Google Account? Or Yahoo Account? All have IMs associated with them. OpenID login could prove ownership of that information.</p>
<p>But&#8230;</p>
<p>My user has already logged in with AOL OpenID.</p>
<p>Stupid 1-to-1 data model of User and OpenID. Bah!</p>
<p><strong>Solution</strong>: allow Users to have 0+ OpenIDs. Some quick refactoring and you&#8217;re done.</p>
<p>Your controller code (the standard Rails solutions for OpenID support use a <code>sessions</code> controller to manage the OpenID provider interactions will now have to do a small amount of extra work.</p>
<p>Small.</p>
<p>Like, you&#8217;ll need a table of known OpenIDs and a <code>belongs_to</code> foreign key to the User model/table.</p>
<p>Small.</p>
<p>But perhaps you are already doing this and I&#8217;m the only silly sausage around here.</p>
<p>Even if you don&#8217;t see the benefit of these use cases &#8211; trusting the information from the OpenID profile &#8211; here&#8217;s a more common use case I think we&#8217;ll find:</p>
<p>Users will want to sign-in with whichever OpenID makes them feel the happiest at the time.</p>
<blockquote><p>I&#8217;m feeling some AOL love today, I&#8217;ll use http://openid.aol.com/iamawesome</p></blockquote>
<blockquote><p>I&#8217;ll use iamawesome.myopenid.com here as its got my Age and Country setup already.</p></blockquote>
<p>And the poor user will instantly get 2 accounts with your application &#8211; on top of the account they already had. That&#8217;s 3 accounts.</p>
<p>Unless we do the following:</p>
<ul>
<li>Allow &#8220;new&#8221; OpenID sign-ins to select an existing application User account to connect to &#8211; don&#8217;t make the poor user feel stupid for using OpenID &#8211; help them connect it to their existing information.</li>
<li>As above, allow multiple OpenIDs to be connected to each User account</li>
</ul>
<p>OpenID allows its Providers to return additional information beyond [name, email, etc] [<a href="#2-openid">2</a>]. So different OpenID profiles might store different bonus information.</p>
<p>AOL might expose my AOL buddies list.</p>
<p>LiveJournal might expose my LiveJournal buddies.</p>
<p>A user could login to your app with both OpenIDs, connect it to one User account, and re-use all their buddies within your app.</p>
<p>Its awesome, and its the &#8220;Social OS&#8221; that everyone&#8217;s harping on about. </p>
<p>Its the future. And its not Facebook.</p>
<p><a name="1-lj" /><br />
[1] [History lesson] Live Journal &#8211; <a href="http://www.sixapart.com/about/history">now owned</a> by <strike>A List Apart</strike><a href="http://www.sixapart.com/">Six Apart</a> &#8211; invented OpenID. [/History Lesson]</p>
<p><a name="2-openid" /><br />
[2] Through a draft specification <a href="http://openid.net/specs.bml">OpenID Attribute Exchange</a>; very nifty indeed as the raw OpenID1.1 spec has very limited profile data sharing. Like none.</p>


<p>Related posts:<ol><li><a href='http://drnicwilliams.com/2008/02/22/zero-sign-on-with-client-certificates/' rel='bookmark' title='Permanent Link: Zero Sign On &#8211; 1 better or Infinitely better than Single Sign On?'>Zero Sign On &#8211; 1 better or Infinitely better than Single Sign On?</a> <small>This article has no code in it. There are no...</small></li><li><a href='http://drnicwilliams.com/2007/09/11/myopenid-goes-down-multiple-openids-useful/' rel='bookmark' title='Permanent Link: Why supporting multiple OpenIDs per User is useful for users&#8230;'>Why supporting multiple OpenIDs per User is useful for users&#8230;</a> <small>Web apps/services go down for maintenance (expected or erroneously) all...</small></li><li><a href='http://drnicwilliams.com/2007/09/11/railsrumble-hates-openid/' rel='bookmark' title='Permanent Link: RailsRumble hates OpenID'>RailsRumble hates OpenID</a> <small>There are 146 RailsRumble entrants. %w[rubygems hpricot open-uri].each { |l|...</small></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://drnicwilliams.com/2007/07/20/one-app-one-user-account-and-multiple-openids/feed/</wfw:commentRss>
		<slash:comments>23</slash:comments>
		</item>
	</channel>
</rss>

