Part of the EllisLab Network
This thread is a discussion for the wiki article: OpenID
   
1 of 2
1
OpenID
Posted: 29 September 2009 04:30 PM   [ Ignore ]  
Summer Student
Total Posts:  13
Joined  06-28-2009

I am not sure what I am missing here, but the library refrences a number of files in an Auth directory. Is this something I need to set up before moving forward with the CI specific implementation to leverage it?

Profile
 
 
Posted: 07 October 2009 04:14 PM   [ Ignore ]   [ # 1 ]  
Summer Student
Total Posts:  17
Joined  01-08-2009

I had the same problem, went to the openid site, and then downloaded the libraries for the PHP/OpenID libraries.  Then the example loaded and worked until it started redirecting me back to the example views, but I suspect that had more to do with the parameters being passed back that were handled by the CI example, not anything to do with the library.

http://www.openidenabled.com/php-openid/

Profile
 
 
Posted: 08 October 2009 10:29 AM   [ Ignore ]   [ # 2 ]  
Summer Student
Total Posts:  17
Joined  01-08-2009

Additionally:  to get the test controller to work, you’ll need to modify the allowed uri characters.  Don’t forget the ‘&’!

Another problem I’m wrestling with now, though, is that when the site returns to the controller, it doesn’t put a trailing ‘/’ between the end of my controller’s method name (check) and the return string.

I thought that would be a simple fix in the config files by adding the ‘/’ to the ‘openid_request_to’ option, since that seems to the be the uri that it returns to, but that didn’t work for me.

Profile
 
 
Posted: 08 October 2009 11:44 AM   [ Ignore ]   [ # 3 ]  
Summer Student
Total Posts:  17
Joined  01-08-2009

I ended up adding an additional trailing slash to the construction of the url in the OpenID library itself, and that seems to have fixed my problem. 

I don’t know if it was an issue with the controller itself or what, so as I do more testing, we’ll see if I have to remove it for other pages that call it to work.

Profile
 
 
Posted: 07 December 2009 02:23 PM   [ Ignore ]   [ # 4 ]  
Summer Student
Avatar
Total Posts:  29
Joined  10-06-2008

@bafadam can you possibly post your code? Or some method of how you achieved this? I am trying to get openid working, and get redirected properly to yahoo / flickr, but upon coming back I get:

OpenID authentication failedNo OpenID information found at https://me.yahoo.com/a/W1PpoHhlhIm_4sLx_D**********q16MZUw--#cbdb5 

(added **** for censor just in case)

 Signature 

Need a little Mojo for your Biz? http://www.webmojo.ca

Profile
 
 
Posted: 18 December 2009 11:27 AM   [ Ignore ]   [ # 5 ]  
Summer Student
Total Posts:  17
Joined  01-08-2009

Register for Livejournal and use that to test.  Their urls are cleaner for openid.  Google requires a two step openid login process, so yahoo might as well.

You may have to dig deeper into yahoo’s authentication methods.

Profile
 
 
Posted: 18 December 2009 01:19 PM   [ Ignore ]   [ # 6 ]  
Summer Student
Avatar
Total Posts:  29
Joined  10-06-2008
bafadam - 18 December 2009 04:27 PM

Register for Livejournal and use that to test.  Their urls are cleaner for openid.  Google requires a two step openid login process, so yahoo might as well.

You may have to dig deeper into yahoo’s authentication methods.

How would getting a Livejournal account help me troubleshoot yahoo/google?  if anything I am only interested in those two..

I was just curious if you got them working thats all, and requested some code, but if not thats ok.

 Signature 

Need a little Mojo for your Biz? http://www.webmojo.ca

Profile
 
 
Posted: 18 December 2009 01:26 PM   [ Ignore ]   [ # 7 ]  
Summer Student
Total Posts:  17
Joined  01-08-2009

It’ll help you test to make sure that the openid portion of the returned value is working properly.  If Livejournal works, then you know the problem is definitely with the yahoo side.  If it doesn’t work, then you definitely know that your (first) problem lies with the controller that’s getting the input back.

To begin google’s process, all I did was create a controller for login, and then a function for google login. It redirects to the beginning of the federated login process, which requests the user’s google openid url.

This link was invaluable when dealing with Google’s Federated Login Process. 

http://code.google.com/apis/accounts/docs/OpenID.html

It outlines exactly what you need to do.

Profile
 
 
Posted: 16 January 2010 06:28 PM   [ Ignore ]   [ # 8 ]  
Summer Student
Avatar
Total Posts:  29
Joined  10-06-2008

So I got all of this working on my test linux box (tried windows before and curl would not authenticate over SSL for some reason).  However now I’m at the point where I cannot seem to get any user details. I clearly see in the code that it requests username / fullname / email.  However the code here:

$sreg_resp Auth_OpenID_SRegResponse::fromSuccessResponse($response);
            
$sreg $sreg_resp->contents();

            foreach (
$sreg as $key => $value)
            
{
                $data[
'success'.= $this->_set_message('openid_content', array($key$value), array('%s','%t'));
            

Results in an empty array.  Am I doing something wrong?

Also, after I get successful sign in (working for google/yahoo/livejournal), how should I proceed with a user account on my end?  Would I use the authenticated string as a ref?

https://www.google.com/accounts/o8/id?id=AItOawlla******1x****8X71kSE 

That’s my assumption that I use this id to create a referencing user account, so next time the federated string will reference my local account.  Is that so? 

Thanks any help is appreciated.

 Signature 

Need a little Mojo for your Biz? http://www.webmojo.ca

Profile
 
 
Posted: 18 February 2010 03:19 PM   [ Ignore ]   [ # 9 ]  
Grad Student
Rank
Total Posts:  32
Joined  09-11-2008

hello
I tried the Openid library.

Looks like it is working fine with the openid providers I tried (Yahoo, Livejournal, Myopenid), but I can’t get it working with Google.

When I put openid URL https://www.google.com/accounts/o8/id
and try to verify it, I get “Authentication error; not a valid OpenID.” message.

Any help is appreciated.
thanks

Profile
 
 
Posted: 18 April 2010 05:06 PM   [ Ignore ]   [ # 10 ]  
Grad Student
Rank
Total Posts:  42
Joined  11-05-2007
Volder - 18 February 2010 08:19 PM

hello
I tried the Openid library.

Looks like it is working fine with the openid providers I tried (Yahoo, Livejournal, Myopenid), but I can’t get it working with Google.

When I put openid URL https://www.google.com/accounts/o8/id
and try to verify it, I get “Authentication error; not a valid OpenID.” message.

Any help is appreciated.
thanks

Google needs a profile link like this: http://www.google.com/profiles/your_gmail_username

by the way for me Google is working, but flickr no :\

P.S. I’ve logged in livejournal through my google account and they didn’t get my email address, I had to add it manually..

And gives problems with chi.mp, after allowing the test application from chi.mp secure login, the test controller returns this:

A PHP Error was encountered

Severity
Notice

Message
Undefined propertyAuth_OpenID_PAPE_Response::$auth_age

Filename
controllers/test.php

Line Number
119 
Profile
 
 
Posted: 08 September 2010 11:07 AM   [ Ignore ]   [ # 11 ]  
Grad Student
Rank
Total Posts:  52
Joined  10-16-2009
cereal - 18 April 2010 09:06 PM

Google needs a profile link like this: http://www.google.com/profiles/your_gmail_username

Noo, its actually http://openid-provider.appspot.com/your_gmail_username

 Signature 

Browse Tutorials: Find and Add CodeIgniter Tutorials! Or any tutorials…

Profile
 
 
Posted: 19 September 2010 06:26 PM   [ Ignore ]   [ # 12 ]  
Summer Student
Avatar
Total Posts:  19
Joined  08-15-2007

How to get the google username? How to implement this with OpenID Library?

 Signature 

————————————————
Brazil - www.codeigniter.com.br
————————————————

Profile
 
 
Posted: 20 September 2010 01:41 AM   [ Ignore ]   [ # 13 ]  
Grad Student
Rank
Total Posts:  52
Joined  10-16-2009

I wrote a little tutorial about it: http://www.browse-tutorials.net/tutorial/codeigniter-login-with-google-using-openid-lsnh

 Signature 

Browse Tutorials: Find and Add CodeIgniter Tutorials! Or any tutorials…

Profile
 
 
Posted: 28 September 2010 10:11 AM   [ Ignore ]   [ # 14 ]  
Summer Student
Total Posts:  5
Joined  11-18-2008

I also spend some time without success to make it work.
But look like here other library for php-openid\codeigniter - http://code.kbjrweb.com/project/easyopenid


upd. it does not work too :(
browsing in this anti-debugable code I found one point of errors - here needed dom or domxml extension

Profile
 
 
Posted: 04 December 2010 08:02 AM   [ Ignore ]   [ # 15 ]  
Summer Student
Total Posts:  5
Joined  12-04-2010

I ended up adding an additional trailing slash to the construction of the url in the OpenID library itself, and that seems to have fixed my problem.

 Signature 

loteria

Profile
 
 
   
1 of 2
1
 
‹‹ Panaci Charting Library      HtmlTable ››