8000 [wip/1.0] Remove "name" as required parameter · Issue #70 · opauth/opauth · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

[wip/1.0] Remove "name" as required parameter #70

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
glen-84 opened this issue Oct 19, 2013 · 9 comments
Open

[wip/1.0] Remove "name" as required parameter #70

glen-84 opened this issue Oct 19, 2013 · 9 comments

Comments

@glen-84
Copy link
glen-84 commented Oct 19, 2013

Opauth, as its name suggests, is about authentication, so the only required information from the provider should be some form of identifier.

As not all providers will supply a name (f.e. the Steam OpenID provider), "name" should not be a required parameter.

Please remove this requirement in order to support such providers.

https://github.com/opauth/opauth/blob/wip/1.0/lib/Opauth/Response.php#L149

@uzyn
Copy link
Member
uzyn commented Oct 19, 2013

It should still be required as that's how a consumer can generally expect a user name reliably from a provider.

If there's no standard "username" per se, the strategy author should still "make one up" in a predictable manner, eg. by using firstname (if it's available), or worst of it all, just a repeat of uid.

@glen-84
Copy link
Author
glen-84 commented Oct 19, 2013

I'm not sure I agree.

Take Steam for example, which uses OpenID and provides no attributes (see here). The only available information here would be the identity or claimed_id, "http://steamcommunity.com/openid/id/76561198109020728" is not very useful as a "name" IMHO.

Why should there always be a name? What about email and first/last name, should that be required too?

@uzyn
Copy link
Member
uzyn commented Oct 19, 2013

I'm not all too familiar with Steam, but there's personaname. Can we use that as name for Steam's strategy?

@glen-84
Copy link
Author
glen-84 commented Oct 19, 2013

It requires an API key ... I have an API key, but I'm controlling it's use because it's limited to 100,000 requests per day. It seems like a lot, but it's used to access match history of players (1 match at a time), so it won't last long.

I would prefer to control when this player data is retrieved, because I need it for users that log in via other strategies as well, for example Google and Twitter.

Also, it would mean writing a custom strategy for Steam, instead of simply aliasing the OpenID strategy.

@glen-84
Copy link
Author
glen-84 commented Oct 19, 2013

@ceeram agrees with you, so I wrote a simple strategy for Steam @ https://github.com/glen-84/opauth-steam

@ceeram
Copy link
Member
ceeram commented Oct 19, 2013

Would be nice if it followed same folder and file structure as other
wip/1.0 strategies, so others can use it. Also composer.json needs to be
changed. Thanks for taking the time to make the strategy, i'll make sure it
will be listed in the 1.0 strategies

2013/10/19 glen-84 notifications@github.com

@ceeram https://github.com/ceeram agrees with you, so I wrote a simple
strategy for Steam @ https://github.com/glen-84/opauth-steam


Reply to this email directly or view it on GitHubhttps://github.com//issues/70#issuecomment-26657903
.

@glen-84
Copy link
Author
glen-84 commented Oct 20, 2013

Why can't others use it like this? It has psr-0 autoloading.

The way I did it follows many other libraries ("src" is sometimes replaced with "lib" or "library"), and allows you to have other folders such as "tests" and "docs" alongside it.

BTW, I e-mailed Mewp to ask him if he could submit LightOpenID to packagist. If he doesn't do so within the next few days I'll probably just submit it myself. Until then, you have to add the Git repository to your root project and also use a stability flag ("lightopenid/lightopenid": "@dev").

@ceeram
Copy link
Member
ceeram commented Mar 30, 2014

lightopenid has been added to packagist, there have been some changes to 1.0 strategies in the meantime. I can help update the steam strategy, but i need your help for further testing it.

@Djuki
Copy link
Djuki commented Aug 2, 2014

I have a case when facebook app return response with name = null, and all other data are correct.

I think that validation can be set as optional. Then we can change way we want to validate response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 p 30B5 articipants
0