我怎样才能检测到用户的计算机/浏览器会话进行身份验证的目的 [英] How can I detect a user's computer/browser session for auth purposes

查看:232
本文介绍了我怎样才能检测到用户的计算机/浏览器会话进行身份验证的目的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想实现发送确认电子邮件给用户的情况下,他从一个新的计算机/浏览器登录一个登录系统。

I am trying to implement a login system that sends a confirmation email to the user in case he logs in from a new computer/browser.

我使用的NodeJS,AngularJS和PassportJS。

I am using Nodejs, AngularJS and PassportJS.

要在那里我能找到这个资源的任何指针将大大AP preciated。

Any pointers to where I could find resources for this will be greatly appreciated.

推荐答案

客户端可以检测的东西,如操作系统/浏览器,让你可以POST数据到服务器每当客户端负载。除此之外,你可以搭配IP-不会忽略用户名,但如果你存储之类的信息,你应该在保存前散列信息。

The client side can detect stuff like os/browser, so you can just POST that data up to the server whenever the client loads. Other than that, you can match usernames with IP-adresses, but if you're storing that kind of information you ought to hash the information before saving it.

这篇关于我怎样才能检测到用户的计算机/浏览器会话进行身份验证的目的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆