secure.py¶
secure.py 🔒 is a lightweight package that adds optional security headers for Python web frameworks.
Supported Python web frameworks:¶
aiohttp, Bottle, CherryPy, Django, Falcon, FastAPI, Flask, hug, Masonite, Pyramid, Quart, Responder, Sanic, Starlette, Tornado
Install¶
pip:
$ pip install secure
Pipenv:
$ pipenv install secure
After installing secure.py:
import secure
secure_headers = secure.Secure()