Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How should I implement session storage on node.js

I'm creating josi, a web framework for node.js. And I'd like to add session storage. What would be the best way to implement this? I'm assuming it probably has to be cookie based, but I'm interested in knowing if any other frameworks have a different approach.

like image 545
thatismatt Avatar asked Oct 14 '22 04:10

thatismatt


1 Answers

I had a look at josi a few days ago. Very nice work!

Other than cookie based, you could use infamous session tokens (e.g. JSESSIONID, PHPSESSID and ASPSESSIONID) and put them in hidden forms or the URL query string.

Cookies are really the best option. They work perfectly for the job.

like image 69
Brian McKenna Avatar answered Oct 31 '22 21:10

Brian McKenna