Skip to content

I have created a Basic Version of a Two Factor Authentication using MongoDB as the Backend and using Node.js, EJS, Express.js and Passport.js as the Frontend! I have used the Passport-Local Strategy from Passport.js and the local authentication strategy authenticates users using a username and password.

Notifications You must be signed in to change notification settings

DhruvAthaide/TwoFactorAuthentication--MongoDB

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Two Factor Authentication with MongoDB and Passport JS

I have created a Basic Version of a Two Factor Authentication using MongoDB as the Backend and using Node.js, EJS, Express.js and Passport.js as the Frontend! I have used the Passport-Local Strategy from Passport.js and the local authentication strategy authenticates users using a username and password.

Installation

To install and run this project,

You can download the zip file or Clone the Project Repository using Git with the below command:

git clone https://github.com/DhruvAthaide/TwoFactorAuthentication-MongoDB.git

Then, open the terminal in the project directory, and run the following command:

  npm install

Once, you have installed the dependancies for the project using NodeJS, Open your Mongo DataBase using the MongoDB Compass GUI Application click on "Create a Database" and enter the following details:

Database Name: passport
Collection Name: users

Once, you have created the Database to store all the user data, you can run the following command in the terminal of the project directory to start the ExpressJS server using nodemon:

npm run dev

Then, you can paste the following address into your browser to access the LoginSignUp Server:

http://localhost:3000/

Authors

Languages & Tools Used:

html5 css3 javascript mongodb expressjs nodejs

About

I have created a Basic Version of a Two Factor Authentication using MongoDB as the Backend and using Node.js, EJS, Express.js and Passport.js as the Frontend! I have used the Passport-Local Strategy from Passport.js and the local authentication strategy authenticates users using a username and password.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published