What's the current state of Yahoo's openid support? No matter how I tried, it only gives back the nameperson attribute, but I can't get the user's email (contact/email). Is there any way to get the email with the lightopenid library?
Asked
Active
Viewed 252 times
1 Answers
0
Exactly the way you tried -- by adding 'contact/email'
to $openid->required
(or optional
).
If a provider doesn't return the email -- that's fine, it doesn't have to. It doesn't mean that the provider doesn't support OpenID, or doesn't support SREG/AX (the OpenID extensions used to fetch the email). It just means that it decided not to send you the email address.
So my advice is: stop depending on that.
OpenID is a decentralized protocol, so there are a lot of providers that won't return email and other data, and you still have to support them. So again: the provider may return whatever data it wants, regardless of what you asked for, so you can't depend on it being returned.

Mewp
- 4,715
- 1
- 21
- 24
-
If you can't depend on these providers to give you some kind of unique user identifier, then what is the point of their existence? How do you make use of such a system? – user1002039 Nov 17 '12 at 00:04
-
@user1002039: The user's unique identifier in case of OpenID is always his OpenID identity, not his email address, or something else. OpenID identity, being an url, is globally unique, solving that particular problem with the lack of an email address. – Mewp Nov 18 '12 at 12:17