An SSL-enabled development server for Django
Project description
Django SSL Server is a SSL-enabled development server for the Django Framework.
Getting Started
Install the module in your Python distribution or virtualenv:
$ pip install django-sslserver
Add the application to your INSTALLED_APPS:
INSTALLED_APPS = (... "sslserver", ... )
Start a SSL-enabled debug server:
$ python manage.py runsslserver
You’ll now be able to access your Django app on https://localhost:8000/
Browser Certificate Errors
Using the default settings, your local browser will make all sorts of noise that it doesn’t trust the certificate. This is expected.
Django SSL Server ships “batteries included” with a self-signed server certificate. With self-signed certificates, the server is effectively telling the user, “I’m such-and-such server, because I said so”. Whereas, with a commercial SSL certificate, the server tells the user, “I’m Bank of America, because VeriSign said so (or any other commercial certificate authority).”
Using self-signed certificates for development is fine, but not for production. In production, your users will see the same ugly certificate warning you’re seeing now. That’s bad.
There are two options for making the certificate warning go away in development:
Option 1: Tell your browser to explicitly trust the certificate. You can do this in your browser’s “advanced settings” tab, by installing sslserver/certs/development.crt as a trusted certificate. The mechanism for this varies from browser to browser.
Option 2: Use a commercial SSL certificate. If you have a certificate/key pair from a commercial certificate authority, you can tell Django SSL Server to use it with the following arguments:
$ python manage.py runsslserver --certificate /path/to/certificate.crt --key /path/to/key.key
Getting Involved
Feel free to open pull requests or issues. GitHub is the canonical location of this project.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file django-sslserver-0.12.tar.gz
.
File metadata
- Download URL: django-sslserver-0.12.tar.gz
- Upload date:
- Size: 5.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb614b597ff0ae0b34b822259fe06d86344f895116b57a845d61096d3e486ffd |
|
MD5 | d3db9ac5fe5c26cb1796da3257b7b9eb |
|
BLAKE2b-256 | 88998454eaef83599e7737116bb73a2f1db1412342c33be1b51452abdb071bec |