Skip to content

Nodejs api that can handle authentication using jwt (JSON Web Token)

Notifications You must be signed in to change notification settings

SaikrishnaReddy1919/Node-Authentication-With-JWT

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NodeJs API that can handle authentication using JWT.

Tech Stack :

-> bcryptjs [To hash password]

-> expressjs

-> joi [Schema Validation]

-> JWT

-> mongoose

JSON Web Token :

JSON Web Token is an Internet standard for creating data with optional signature and/or optional encryption whose payload holds JSON that asserts some number of claims. The tokens are signed either using a private secret or a public/private key. For example, a server could generate a token that has the claim "logged in as admin" and provide that to a client. The client could then use that token to prove that it is logged in as admin. The tokens can be signed by one party's private key (usually the server's) so that party can subsequently verify the token is legitimate. If the other party, by some suitable and trustworthy means, is in possession of the corresponding public key, they too are able to verify the token's legitimacy. The tokens are designed to be compact, URL-safe, and usable especially in a web-browser single-sign-on (SSO) context. JWT claims can typically be used to pass identity of authenticated users between an identity provider and a service provider, or any other type of claims as required by business processes.

Releases

No releases published

Packages

No packages published