Permalink
Browse files

Added changelog entries for changes.

  • Loading branch information...
pelle committed Oct 1, 2009
1 parent 0b07998 commit 98e825b96343111e33256534cc4668d0b7b3058d
Showing with 47 additions and 2 deletions.
  1. +45 −0 CHANGELOG.rdoc
  2. +2 −2 lib/authlogic_openid/acts_as_authentic.rb
View
@@ -1,3 +1,48 @@
+= 1.0.6
+
+* Fixed a fairly complex issue with autoregistration and directed identity (as in Google and Yahoo OpenID).
+* Added support for OpenID/OAuth Hybrid model extension:
+
+ http://wiki.openid.net/OpenID-and-OAuth-Hybrid-Extension
+
+ Note this currently requires patched versions of the ruby-openid gem and the open_id_authentication plugin:
+
+ gem install pelle-ruby-openid # http://github.com/pelle/ruby-openid
+ gem install pelle-open_id_authentication # http://github.com/pelle/open_id_authentication
+
+ The rails open_id_authentication is normally installed in vendor/plugin, update that or add the above as a gem plugin.
+
+ Adding this requires you to switch it on in your acts_as_authentic configuration block:
+
+ acts_as_authentic do |c|
+ c.openid_oauth = true
+ end
+
+ Then it needs to know which when to send an OAuth Consumer key along. Override openid_oauth_consumer in your User model:
+
+ def openid_oauth_consumer
+ if openid_identifier=~/^https?:\/\/www\.google\./
+ return {:consumer=>'mydomain.com',:scope=>'http://www.google.com/m8/feeds/'}
+ elsif openid_identifier=~/yahoo.com/
+ return {:consumer=>"YOUR YAHOO CONSUMER"}
+ end
+ end
+
+ You will receive a request_token that you need to exchange for an OAuth AccessToken:
+
+ def exchange_oauth_tokens
+ return unless @request_token
+ if openid_identifier=~/^https?:\/\/www\.google\./
+ GoogleToken.create_from_request_token(self,@request_token,'','')
+ end
+ end
+
+* Added an openid_options configuration item for acts_as_authentic to pass arbitrary values along to the open_id_authentication plugin.
+
+= 1.0.5 released 2009-6-18
+
+* Added support for autoregistration
+
== 1.0.4 released 2009-5-14
* Only authenticate with OpenID for models when a block is passed.
@@ -165,7 +165,7 @@ def map_openid_registration(registration) # :doc:
# registered as a consumer with the particular openid provider.
#
# def openid_oauth_consumer
- # if openid_identifier=="https://www.google.com/accounts/o8/id"
+ # if openid_identifier=~/^https?:\/\/www\.google\./
# return {:consumer=>'mydomain.com',:scope=>'http://www.google.com/m8/feeds/'}
# elsif openid_identifier=~/yahoo.com/
# return {:consumer=>"YOUR YAHOO CONSUMER"}
@@ -181,7 +181,7 @@ def openid_oauth_consumer
#
# def exchange_oauth_tokens
# return unless @request_token
- # if openid_identifier=="https://www.google.com/accounts/o8/id"
+ # if openid_identifier=~/^https?:\/\/www\.google\./
# GoogleToken.create_from_request_token(self,@request_token,'','')
# end
# end

0 comments on commit 98e825b

Please sign in to comment.