[django/django] 1c3c21: Fixed #19987 -- Disabled host validation when DEBU...

0 views
Skip to first unread message

GitHub

unread,
Jul 31, 2013, 10:39:18 AM7/31/13
to django-...@googlegroups.com
Branch: refs/heads/master
Home: https://github.com/django/django
Commit: 1c3c21b38d154eff0286c194711dced2ac39dd3d
https://github.com/django/django/commit/1c3c21b38d154eff0286c194711dced2ac39dd3d
Author: Will Hardy <dja...@willhardy.com.au>
Date: 2013-07-31 (Wed, 31 Jul 2013)

Changed paths:
M django/http/request.py
M tests/requests/tests.py

Log Message:
-----------
Fixed #19987 -- Disabled host validation when DEBUG=True.

The documentation promises that host validation is disabled when
DEBUG=True, that all hostnames are accepted. Domains not compliant with
RFC 1034/1035 were however being validated, this validation has now been
removed when DEBUG=True.

Additionally, when DEBUG=False a more detailed SuspiciousOperation
exception message is provided when host validation fails because the
hostname is not RFC 1034/1035 compliant.



Reply all
Reply to author
Forward
0 new messages