Avoiding multiple logins to an account from different locations

前端 未结 5 481
醉梦人生
醉梦人生 2021-01-06 20:11

I want to restrict multiple logins of the same user from different locations. How can I identify a user\'s multiple logins from different locations in the same/recent times?

5条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-01-06 21:12

    I think, just have extra 2 columns for each user - "LastLoginTime" and "IPAddress" in your Users table. If the duration is too short and IPAddress vary then you can give a warning to the user. Additionally you can also inform the City & Country from which the user is logged in.

提交回复
热议问题