Skip to content
Django middleware implementing the Referrer-Policy header
Python Makefile
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github
django_http_referrer_policy
docs
tests
.coveragerc
.editorconfig
.gitignore Add feature Referrer Policy Middleware Aug 11, 2019
.travis.yml
AUTHORS.rst
CONTRIBUTING.rst
HISTORY.rst
LICENSE
MANIFEST.in Add feature Referrer Policy Middleware Aug 11, 2019
Makefile
README.rst
manage.py
requirements_dev.txt
requirements_test.txt
runtests.py
setup.cfg
setup.py
tox.ini

README.rst

Django HTTP Referrer Policy

https://travis-ci.org/DmytroLitvinov/django-http-referrer-policy.svg?branch=master Documentation Status

django-referrer-policy provides a middleware class implementing the Referrer-Policy header for Django-powered sites.

Documentation

The full documentation is at https://django-http-referrer-policy.readthedocs.io.

Quickstart

Install Django HTTP Referrer Policy:

pip install django-http-referrer-policy

Add it to your INSTALLED_APPS:

INSTALLED_APPS = (
    ...
    'django_http_referrer_policy',
    ...
)

Add Django HTTP Referrer Policy Middleware to your settings:

MIDDLEWARE = [
    ...
    'django_http_referrer_policy.middleware.ReferrerPolicyMiddleware',
    ...
]

Running Tests

Does the code actually work?

source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install tox
(myenv) $ tox

Credits

Maintainable version of original library.

Tools used in rendering this package:

You can’t perform that action at this time.