skip to navigation
skip to content

Not Logged In

django-ssl-admin 1.1.4

Django middleware to make the admin https only.

Make the Django admin only available via https. For Django versions >= 1.7.

Installation

You can install django-ssl-admin using pip:

$ pip install django-ssl-admin

Usage

To enable django-ssl-admin you need to add it to MIDDLEWARE_CLASSES:

MIDDLEWARE_CLASSES = (
    ...
    'ssladmin.middleware.SSLAdmin',
    ....
)

If your admin path is not /admin/ you can change the ADMIN_PATH setting like so:

ADMIN_PATH = '^/staff/'

If you have a reverse proxy set up remember to let Django know how it can detect a secure connection, e.g.:

SECURE_PROXY_SSL_HEADER = ('HTTP_X_SCHEME', 'https')

License

Copyright © 2015 Matt Deacalion Stevens, released under The MIT License.

 
File Type Py Version Uploaded on Size
django-ssl-admin-1.1.4.tar.gz (md5) Source 2014-12-28 3KB
django_ssl_admin-1.1.4-py2.py3-none-any.whl (md5) Python Wheel 3.4 2014-12-28 4KB
  • Downloads (All Versions):
  • 11 downloads in the last day
  • 79 downloads in the last week
  • 707 downloads in the last month