Skip to content
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

Setup Patient Authentication #457

Open
mattwalo32 opened this issue Nov 5, 2021 · 0 comments · May be fixed by #547
Open

Setup Patient Authentication #457

mattwalo32 opened this issue Nov 5, 2021 · 0 comments · May be fixed by #547
Assignees
Labels
P0 High Priority

Comments

@mattwalo32
Copy link
Collaborator

mattwalo32 commented Nov 5, 2021

Use passport for this. We will use the 2FA code to establish a session, then the cookie will be sent on all future requests to authenticate until it expires.

Here are the steps:

  1. Use the passport-session library
  2. Use the localStrategy as shown here http://www.passportjs.org/docs/configure/
    Make sure the username is _id and the password is the 2FA code. You'll have to make sure the request is properly formatted for passport to automatically grab those fields.
  3. Inside the localStrategy, do the 2FA code check

On the same page, you'll see serializeUser and deserializeUser. You probably need to implement those as well with ``_id`

image

@mattwalo32 mattwalo32 added the P0 High Priority label Dec 14, 2021
@Archna-1 Archna-1 linked a pull request Jan 2, 2022 that will close this issue
11 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P0 High Priority
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants