Skip to main content

This module contains a simple class to implement authentication and authorization in a Flask app using JSON Web Token (JWT)

Project description

flask_jwt_auth

Introduction
Getting Started
Example
Contributors
License

Introduction

This module contains a simple class to implement authentication and authorization in a Flask app using JSON Web Token (JWT)

Getting Started

In order to install, open the command prompt and type ✌️:
pip install flask_jwt_auth

In order to import:

from flask_jwt_auth import AuthFilters

Token Validation using an SQL Database

This library supports using an SQL database for token validation. The basic idea is that you store all your tokens in DB, and flag the invalidated tokens (e.g. when a user logs out). To use this feature: - Set the environment variable containing the DB connection string, called `JWT_SESSION_TOKEN_DB_URI`. - Create a table in that DB, called `session_token`. It must have the following fields: - `access_token` : string - `refresh_token` : string - `is_invalid` : boolean

Contributors

This project exists thanks to all the people who contribute. [Contribute]. ""

License

This library is licensed under the MIT License - see the LICENSE.md file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

flask_jwt_auth-0.0.10.tar.gz (3.9 kB view hashes)

Uploaded Source

Built Distribution

flask_jwt_auth-0.0.10-py3-none-any.whl (4.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page