How to do authentication with Node.js, Express and Mongoose?

Some useful links:

how to implement login auth in node.js

creating registration and login form in node.js and mongodb

Also session management isn’t done by Mongoose, but by connect-mongodb or connect-redis. You can checkout an example on how to do user auth and session management in a real application here:

https://github.com/alexyoung/nodepad/blob/master/app.js

Further explanations for that app you can find here: http://dailyjs.com/tag/lmawa or http://dailyjs.com/2010/12/06/node-tutorial-5/

Leave a Comment