CakeDC / users

Users Plugin for CakePHP
https://www.cakedc.com
Other
521 stars 296 forks source link

Passwordless Authentication #987

Open rochamarcelo opened 2 years ago

rochamarcelo commented 2 years ago

Currently the login page requires to use password, it would be nice to have a way to authenticate without it. Passwordless authentication can be implemented using E-mail Message, SMS, WebAuthn, Social (Already implemented).

With E-mail and SMS authentication we send a code to the user and a optional 'magic' link. Basic flow: -> User access login page -> User type e-mail and submit -> App send code to e-mail -> User open e-mail and click the link or copy the code -> App check token and authenticate user -> User access home page.

Any thoughts?

rochamarcelo commented 2 years ago

Here is a nodejs implementation for reference https://github.com/florianheinemann/passwordless

nuzulfikrie commented 7 months ago

I was thinking of js. Listening to server sent event. On login attempt. If user with email is found. It will send out link. Js will update page to loading. On user click email link. Will clear out token.. Redirect user to home.