| 1 |
Flask-Security |
| 2 |
=================== |
| 3 |
|
| 4 |
.. image:: https://github.com/pallets-eco/flask-security/actions/workflows/tests.yml/badge.svg?branch=main&event=push |
| 5 |
:target: https://github.com/pallets-eco/flask-security |
| 6 |
|
| 7 |
.. image:: https://codecov.io/gh/pallets-eco/flask-security/graph/badge.svg?token=ZYS0AST5M3 |
| 8 |
:target: https://codecov.io/gh/pallets-eco/flask-security |
| 9 |
:alt: Coverage! |
| 10 |
|
| 11 |
.. image:: https://img.shields.io/github/tag/pallets-eco/flask-security.svg |
| 12 |
:target: https://github.com/pallets-eco/flask-security/releases |
| 13 |
|
| 14 |
.. image:: https://img.shields.io/pypi/dm/flask-security.svg |
| 15 |
:target: https://pypi.python.org/pypi/flask-security |
| 16 |
:alt: Downloads |
| 17 |
|
| 18 |
.. image:: https://img.shields.io/pypi/dm/flask-security-too.svg |
| 19 |
:target: https://pypi.python.org/pypi/flask-security-too |
| 20 |
:alt: Downloads |
| 21 |
|
| 22 |
.. image:: https://img.shields.io/github/license/pallets-eco/flask-security.svg |
| 23 |
:target: https://github.com/pallets-eco/flask-security/blob/main/LICENSE |
| 24 |
:alt: License |
| 25 |
|
| 26 |
.. image:: https://readthedocs.org/projects/flask-security/badge/?version=latest |
| 27 |
:target: https://flask-security.readthedocs.io/en/latest/?badge=latest |
| 28 |
:alt: Documentation Status |
| 29 |
|
| 30 |
.. image:: https://img.shields.io/badge/code%20style-black-000000.svg |
| 31 |
:target: https://github.com/python/black |
| 32 |
|
| 33 |
.. image:: https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white |
| 34 |
:target: https://github.com/pre-commit/pre-commit |
| 35 |
:alt: pre-commit |
| 36 |
|
| 37 |
Quickly add security features to your Flask application. |
| 38 |
|
| 39 |
Notes on this repo |
| 40 |
------------------ |
| 41 |
As of 7/30/2024, the independent fork Flask-Security-Too replaced the archived |
| 42 |
Flask-Security repo (now called Flask-Security-3.0). This repo is published at PyPI at |
| 43 |
both Flask-Security and Flask-Security-Too. Please consider changing your |
| 44 |
requirements file to point to flask-security. |
| 45 |
|
| 46 |
Flask-Security-Too was a fork from the 3.0.0 |
| 47 |
version of the `Original <https://github.com/mattupstate/flask-security>`_ |
| 48 |
|
| 49 |
Pallets Community Ecosystem |
| 50 |
---------------------------- |
| 51 |
|
| 52 |
This project is part of the Pallets Community Ecosystem. Pallets is the open |
| 53 |
source organization that maintains Flask; Pallets-Eco enables community |
| 54 |
maintenance of related projects. If you are interested in helping maintain |
| 55 |
this project, please reach out on `the Pallets Discord server <https://discord.gg/pallets>`. |
| 56 |
|
| 57 |
Goals |
| 58 |
----- |
| 59 |
|
| 60 |
* Use `OWASP <https://github.com/OWASP/ASVS>`_ to guide best practice and default configurations. |
| 61 |
* Be more opinionated and 'batteries' included by reducing reliance on abandoned projects and |
| 62 |
bundling in support for common use cases. |
| 63 |
* Follow the `Pallets <https://github.com/pallets>`_ lead on supported versions, documentation |
| 64 |
standards and any other guidelines for extensions that they come up with. |
| 65 |
* Continue to add newer authentication/authorization standards: |
| 66 |
* 'Social Login (OAuth)' integrated (using authlib) (5.1) |
| 67 |
* WebAuthn/Passkey support (5.0) |
| 68 |
* Two-Factor recovery codes (5.0) |
| 69 |
* First-class support for username as identity (4.1) |
| 70 |
* Support for freshness decorator to ensure sensitive operations have new authentication (4.0) |
| 71 |
* Support for email normalization and validation (4.0) |
| 72 |
* Unified signin (username, phone, passwordless) feature (3.4) |
| 73 |
* Two/Multi-Factor authentication supporting SMS, email, authenticator apps (4.0) |
| 74 |
|
| 75 |
|
| 76 |
Contributing |
| 77 |
------------ |
| 78 |
Issues and pull requests are welcome. Other maintainers are also welcome. |
| 79 |
Please consult these `contributing`_ guidelines. |
| 80 |
|
| 81 |
.. _contributing: https://github.com/pallets-eco/flask-security/blob/main/CONTRIBUTING.rst |
| 82 |
|
| 83 |
Installing |
| 84 |
---------- |
| 85 |
Install and update using `pip <https://pip.pypa.io/en/stable/quickstart/>`_: |
| 86 |
|
| 87 |
:: |
| 88 |
|
| 89 |
pip install -U Flask-Security |
| 90 |
|
| 91 |
|
| 92 |
Resources |
| 93 |
--------- |
| 94 |
|
| 95 |
- `Documentation <https://flask-security.readthedocs.io/>`_ |
| 96 |
- `Releases <https://pypi.org/project/Flask-Security/>`_ |
| 97 |
- `Issue Tracker <https://github.com/pallets-eco/flask-security/issues>`_ |
| 98 |
- `Code <https://github.com/pallets-eco/flask-security/>`_ |