Skip to content

[Spike] Explore/research the oauth2+session based authentication strategy #2624

Description

@jannyHou

Description / Steps to reproduce / Feature proposal

A follow-up story for PR #2576

Add new authentication strategies in loopback4-example-shopping to investigate how to verify a 3rd-party user using oauth2, and track the user using session.

Acceptance Criteria:

The acceptance criteria is written with oauth2+google, the story owner can choose any 3rd party auth provider: oauth2+fb, oauth2+google, etc...

  • Create a static login page that allows user to choose from local login or 3rd-party login. Keep the UI as simple as possible

  • Create an oauth2 strategy to authenticate the users by interacting with 3rd-party provider's auth server completed with fix: passport strategy adapter must support oauth2 flows #4919

    • Please note that usually 3rd-party login requires a callback URL, which implies 2 endpoints are involved in the login flow. E.g. login/facebook and login/facebook/callback. And this is the most important user experience we need to figure out from design's perspective.
  • Track the user profile using session. Keep the session related functionalities as simple as possible, we can create sub-stories to enhance.

  • Create an example endpoint that verifies user using session.
    - [ ] Update the md file docs/strategies/oauth2.md

Activity

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

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions