Token-Based Authentication

This repo contains the code for one of my blogposts on Token-Based Authentication. If you have not read it you can do so here.

Usage

If you want to play around with the code feel free to clone the repo.

In order to get the code to run you will need to set up a few things.

  • run npm install

  • Create a file named .env and add data of the following form to it. Obviously using your own data.

TOKEN_SECRET = "Your very secret token secret"
  • start your server with node server.js

  • open your Web browser on localhost:3000

You should be all set.

License

MIT © Arthur Mathies