Skip to content

OAuth based login #241

Description

@flovilmart

I have some code that's been originally written for could code for OAuth2 providers, it needs a refactor as it was using an external object to store the login informations.
I have the basic implementations for instagram, meetup, linkedin, as well as the iOS side.
Twitter login could also be added in that, but since it's OAuth 1.1 that's a totally different game.

@gfosco is it something you'd like to see integrated soon or you prefer to wait for stabilization?

Activity

  1. gfosco commented on Feb 4, 2016

    @gfosco
    Contributor

    That would be great, don't think we need to wait. Looks like most of the work is in RestWrite.js.

  2. flovilmart commented on Feb 4, 2016

    @flovilmart
    ContributorAuthor

    I investigated already, I believe I'll start with OAuth2 flows, in an extensible way.
    Quick architectural question, are the ParseServer options exposed in the RestWrite?

  3. flovilmart commented on Feb 4, 2016

    @flovilmart
    ContributorAuthor

    @gfosco I could also refactor the Facebook login around this new OAuth provider as they will share 99% of the code, what do you think?

  4. nlutsenko commented on Feb 5, 2016

    @nlutsenko
    Contributor

    That's an awesome idea!
    And the SDKs are already built in a way that can support this.

    One of the potential ways for building this could be via custom cloud functions or similar piece, so anyone can bring in their own validation.

    Look into how Facebook is hooked on right now - all of this could be similar, where we would store the data in _User.

  5. flovilmart commented on Feb 5, 2016

    @flovilmart
    ContributorAuthor

    @nlutsenko the PR is open with meetup, instagram, and linked in. I didn't realize initially that the full oAuth flow is not provided by parse-server itself so adding twitter would be just another validator.

    We could also support custom validator through:

    {
       appId: ...
       oauth: {
            customProvider: {
                validateUserId:function(userId, token) { /*code */ },
                validateAppId: function() { /* code */}
            }
       }
    }

    This could be added before tomorrow

  6. gfosco commented on Feb 16, 2016

    @gfosco
    Contributor

    This will be landing in #247. 🎆

  7. sprabs commented on Jul 12, 2016

    @sprabs

    Quick question for you all (since you implemented this). We have two Twitter apps (one our iOS clients are using and one that our Android clients are using). How do we specify two sets of keys in index.js?

    #2254

  8. flovilmart commented on Jul 12, 2016

    @flovilmart
    ContributorAuthor

    It isn't supported yet

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions