Sunday 27 March 2016

Identifying users without login - passport question

I'm working on a website that heavily revolves around chat. I built the chat using socket.io and I want to add user authentication.I want anyone to be able to go to the website and use all of the features without having to worry about signing up for an account or logging in. An account will be created anytime a user joins the site and isn't recognized. If they come back later, the site should be able to recognize them and authenticate them automatically. At any point they can choose to claim their account by linking it to a google or facebook account.1: I understand how to authenticate with google/facebook/etc, but is there an easy and secure way to identify someone by storing a cookie and linking it to their account? I assume there is a passport strategy that does this, but looking through them I didn't see any that I understood that did this.2: Once I have user authentication working over http, how do I authenticate users over socket.io websockets? I've tried looking this up but almost all the resources I find are 2+ years old and don't seem relevant.Thanks for taking the time to read my post.

Submitted March 28, 2016 at 06:42AM by Nephyst

No comments:

Post a Comment