Sessions in Node JS

前端 未结 10 870
北海茫月
北海茫月 2021-01-07 23:46

How can I maintain my SESSIONS in Node JS ? E.g I want to store UserID in SESSION using Node Js. How can I do that in Node JS ? And can I use that Node JS SESSION in PHP too

10条回答
  •  死守一世寂寞
    2021-01-08 00:15

    Session that gives access/permission to view user's area, as well as it's a credential so we can use it over the application. I used jsonwebtoken to make a token which will have user's details with time after successful login attempt by user. I stored it in redis, and can be used for a pre-declared time limit.

提交回复
热议问题