Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bryanjos/plug_jwt
Plug for JWT authentication
https://github.com/bryanjos/plug_jwt
Last synced: about 1 month ago
JSON representation
Plug for JWT authentication
- Host: GitHub
- URL: https://github.com/bryanjos/plug_jwt
- Owner: bryanjos
- Created: 2014-09-26T19:33:59.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2015-08-19T22:13:08.000Z (over 9 years ago)
- Last Synced: 2024-11-01T07:33:26.045Z (about 1 month ago)
- Language: Elixir
- Size: 223 KB
- Stars: 39
- Watchers: 5
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
- freaking_awesome_elixir - Elixir - Plug for JWT authentication. (Framework Components)
- fucking-awesome-elixir - plug_jwt - Plug for JWT authentication. (Framework Components)
- awesome-jwt - plug_jwt - Plug for JWT authentication. (Libraries / Elixir)
- awesome-elixir - plug_jwt - Plug for JWT authentication. (Framework Components)
README
PlugJwt
=======A JWT Plug
Usage:
```elixir
#When reading from joken config block
plug PlugJwt
#or the module that implements `Joken.Config` can be set explicitly
plug PlugJwt, config_module: My.Joken.Config#You may also add a list of expected claims to verify
plug PlugJwt, config_module: My.Joken.Config, claims: [aud: "spiderman", admin: true]
```Parameters:
PlugJWT will attempt to read from your joken config block. Parameters can also be placed on the Plug itself
which overrides the joken configuration* config_module: The module that implements Joken.Config