{"action":"closed","number":4633,"pull_request":{"url":"https://api.github.com/repos/django/django/pulls/4633","id":35066643,"html_url":"https://github.com/django/django/pull/4633","diff_url":"https://github.com/django/django/pull/4633.diff","patch_url":"https://github.com/django/django/pull/4633.patch","issue_url":"https://api.github.com/repos/django/django/issues/4633","number":4633,"state":"closed","locked":false,"title":"Added SSL support to the `runserver` development server.","user":{"login":"sjberry","id":2207290,"avatar_url":"https://avatars.githubusercontent.com/u/2207290?v=3","gravatar_id":"","url":"https://api.github.com/users/sjberry","html_url":"https://github.com/sjberry","followers_url":"https://api.github.com/users/sjberry/followers","following_url":"https://api.github.com/users/sjberry/following{/other_user}","gists_url":"https://api.github.com/users/sjberry/gists{/gist_id}","starred_url":"https://api.github.com/users/sjberry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjberry/subscriptions","organizations_url":"https://api.github.com/users/sjberry/orgs","repos_url":"https://api.github.com/users/sjberry/repos","events_url":"https://api.github.com/users/sjberry/events{/privacy}","received_events_url":"https://api.github.com/users/sjberry/received_events","type":"User","site_admin":false},"body":"The Django admin `runserver` command now optionally supports SSL. The\r\nserver key and certificate files can be specified independently or as a\r\nconcatenated certfile. The admin command documentation and test cases\r\nhave been updated accordingly.\r\n\r\nSome changes were necessary in the django.core.servers.basehttp module.\r\nSpecifically SecureWSGIServer and SecureWSGIRequestHandler were added as\r\nSSL-enabled versions of their similarly named parent classes. The run\r\nfunction needed to be abstracted slightly to support variable server and\r\nhandler classes originating in the `runserver` command itself. Rather\r\nthan adding additional parameters for the certfile and keyfile\r\narguments, the explicit ipv6 parameter was removed in favor of a kwargs\r\ndict to make the run function more generic.\r\n\r\nThe SecureWSGIServer class deliberately uses an ssl_version of\r\nssl.PROTOCOL_SSLv23. With the socket thusly wrapped, a more permissive\r\nset of SSL/TLS versions are accepted by the development server. This\r\nflagrantly disregards the security recommendations made in response to\r\nthe discovery of the POODLE vulnerability. However, the development\r\nserver is not intended for production use, so this not of serious\r\nconcern.\r\n\r\nFurthermore, the ssl package is imported within the `__init__` method of\r\nthe SecureWSGIServer so as not to contribute to the overhead of\r\nimporting the basehttp module elsewhere.","created_at":"2015-05-09T13:29:32Z","updated_at":"2015-05-18T22:16:46Z","closed_at":"2015-05-18T22:16:46Z","merged_at":null,"merge_commit_sha":"07861f13ef7990f1831ec939c8df60bbc23a0230","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/django/django/pulls/4633/commits","review_comments_url":"https://api.github.com/repos/django/django/pulls/4633/comments","review_comment_url":"https://api.github.com/repos/django/django/pulls/comments{/number}","comments_url":"https://api.github.com/repos/django/django/issues/4633/comments","statuses_url":"https://api.github.com/repos/django/django/statuses/80d9977c53d27497cbf5fbb2f3f4a5b0bdac8016","head":{"label":"sjberry:ssl_runserver","ref":"ssl_runserver","sha":"80d9977c53d27497cbf5fbb2f3f4a5b0bdac8016","user":{"login":"sjberry","id":2207290,"avatar_url":"https://avatars.githubusercontent.com/u/2207290?v=3","gravatar_id":"","url":"https://api.github.com/users/sjberry","html_url":"https://github.com/sjberry","followers_url":"https://api.github.com/users/sjberry/followers","following_url":"https://api.github.com/users/sjberry/following{/other_user}","gists_url":"https://api.github.com/users/sjberry/gists{/gist_id}","starred_url":"https://api.github.com/users/sjberry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjberry/subscriptions","organizations_url":"https://api.github.com/users/sjberry/orgs","repos_url":"https://api.github.com/users/sjberry/repos","events_url":"https://api.github.com/users/sjberry/events{/privacy}","received_events_url":"https://api.github.com/users/sjberry/received_events","type":"User","site_admin":false},"repo":{"id":35322539,"name":"django","full_name":"sjberry/django","owner":{"login":"sjberry","id":2207290,"avatar_url":"https://avatars.githubusercontent.com/u/2207290?v=3","gravatar_id":"","url":"https://api.github.com/users/sjberry","html_url":"https://github.com/sjberry","followers_url":"https://api.github.com/users/sjberry/followers","following_url":"https://api.github.com/users/sjberry/following{/other_user}","gists_url":"https://api.github.com/users/sjberry/gists{/gist_id}","starred_url":"https://api.github.com/users/sjberry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjberry/subscriptions","organizations_url":"https://api.github.com/users/sjberry/orgs","repos_url":"https://api.github.com/users/sjberry/repos","events_url":"https://api.github.com/users/sjberry/events{/privacy}","received_events_url":"https://api.github.com/users/sjberry/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/sjberry/django","description":"The Web framework for perfectionists with deadlines.","fork":true,"url":"https://api.github.com/repos/sjberry/django","forks_url":"https://api.github.com/repos/sjberry/django/forks","keys_url":"https://api.github.com/repos/sjberry/django/keys{/key_id}","collaborators_url":"https://api.github.com/repos/sjberry/django/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/sjberry/django/teams","hooks_url":"https://api.github.com/repos/sjberry/django/hooks","issue_events_url":"https://api.github.com/repos/sjberry/django/issues/events{/number}","events_url":"https://api.github.com/repos/sjberry/django/events","assignees_url":"https://api.github.com/repos/sjberry/django/assignees{/user}","branches_url":"https://api.github.com/repos/sjberry/django/branches{/branch}","tags_url":"https://api.github.com/repos/sjberry/django/tags","blobs_url":"https://api.github.com/repos/sjberry/django/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/sjberry/django/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/sjberry/django/git/refs{/sha}","trees_url":"https://api.github.com/repos/sjberry/django/git/trees{/sha}","statuses_url":"https://api.github.com/repos/sjberry/django/statuses/{sha}","languages_url":"https://api.github.com/repos/sjberry/django/languages","stargazers_url":"https://api.github.com/repos/sjberry/django/stargazers","contributors_url":"https://api.github.com/repos/sjberry/django/contributors","subscribers_url":"https://api.github.com/repos/sjberry/django/subscribers","subscription_url":"https://api.github.com/repos/sjberry/django/subscription","commits_url":"https://api.github.com/repos/sjberry/django/commits{/sha}","git_commits_url":"https://api.github.com/repos/sjberry/django/git/commits{/sha}","comments_url":"https://api.github.com/repos/sjberry/django/comments{/number}","issue_comment_url":"https://api.github.com/repos/sjberry/django/issues/comments{/number}","contents_url":"https://api.github.com/repos/sjberry/django/contents/{+path}","compare_url":"https://api.github.com/repos/sjberry/django/compare/{base}...{head}","merges_url":"https://api.github.com/repos/sjberry/django/merges","archive_url":"https://api.github.com/repos/sjberry/django/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/sjberry/django/downloads","issues_url":"https://api.github.com/repos/sjberry/django/issues{/number}","pulls_url":"https://api.github.com/repos/sjberry/django/pulls{/number}","milestones_url":"https://api.github.com/repos/sjberry/django/milestones{/number}","notifications_url":"https://api.github.com/repos/sjberry/django/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/sjberry/django/labels{/name}","releases_url":"https://api.github.com/repos/sjberry/django/releases{/id}","created_at":"2015-05-09T09:15:43Z","updated_at":"2015-05-09T09:15:57Z","pushed_at":"2015-05-09T15:27:39Z","git_url":"git://github.com/sjberry/django.git","ssh_url":"git@github.com:sjberry/django.git","clone_url":"https://github.com/sjberry/django.git","svn_url":"https://github.com/sjberry/django","homepage":"https://www.djangoproject.com/","size":132376,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"django:master","ref":"master","sha":"b99114f67f0e5eba3b1d31641906b75a14fd2fa0","user":{"login":"django","id":27804,"avatar_url":"https://avatars.githubusercontent.com/u/27804?v=3","gravatar_id":"","url":"https://api.github.com/users/django","html_url":"https://github.com/django","followers_url":"https://api.github.com/users/django/followers","following_url":"https://api.github.com/users/django/following{/other_user}","gists_url":"https://api.github.com/users/django/gists{/gist_id}","starred_url":"https://api.github.com/users/django/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/django/subscriptions","organizations_url":"https://api.github.com/users/django/orgs","repos_url":"https://api.github.com/users/django/repos","events_url":"https://api.github.com/users/django/events{/privacy}","received_events_url":"https://api.github.com/users/django/received_events","type":"Organization","site_admin":false},"repo":{"id":4164482,"name":"django","full_name":"django/django","owner":{"login":"django","id":27804,"avatar_url":"https://avatars.githubusercontent.com/u/27804?v=3","gravatar_id":"","url":"https://api.github.com/users/django","html_url":"https://github.com/django","followers_url":"https://api.github.com/users/django/followers","following_url":"https://api.github.com/users/django/following{/other_user}","gists_url":"https://api.github.com/users/django/gists{/gist_id}","starred_url":"https://api.github.com/users/django/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/django/subscriptions","organizations_url":"https://api.github.com/users/django/orgs","repos_url":"https://api.github.com/users/django/repos","events_url":"https://api.github.com/users/django/events{/privacy}","received_events_url":"https://api.github.com/users/django/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/django/django","description":"The Web framework for perfectionists with deadlines.","fork":false,"url":"https://api.github.com/repos/django/django","forks_url":"https://api.github.com/repos/django/django/forks","keys_url":"https://api.github.com/repos/django/django/keys{/key_id}","collaborators_url":"https://api.github.com/repos/django/django/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/django/django/teams","hooks_url":"https://api.github.com/repos/django/django/hooks","issue_events_url":"https://api.github.com/repos/django/django/issues/events{/number}","events_url":"https://api.github.com/repos/django/django/events","assignees_url":"https://api.github.com/repos/django/django/assignees{/user}","branches_url":"https://api.github.com/repos/django/django/branches{/branch}","tags_url":"https://api.github.com/repos/django/django/tags","blobs_url":"https://api.github.com/repos/django/django/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/django/django/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/django/django/git/refs{/sha}","trees_url":"https://api.github.com/repos/django/django/git/trees{/sha}","statuses_url":"https://api.github.com/repos/django/django/statuses/{sha}","languages_url":"https://api.github.com/repos/django/django/languages","stargazers_url":"https://api.github.com/repos/django/django/stargazers","contributors_url":"https://api.github.com/repos/django/django/contributors","subscribers_url":"https://api.github.com/repos/django/django/subscribers","subscription_url":"https://api.github.com/repos/django/django/subscription","commits_url":"https://api.github.com/repos/django/django/commits{/sha}","git_commits_url":"https://api.github.com/repos/django/django/git/commits{/sha}","comments_url":"https://api.github.com/repos/django/django/comments{/number}","issue_comment_url":"https://api.github.com/repos/django/django/issues/comments{/number}","contents_url":"https://api.github.com/repos/django/django/contents/{+path}","compare_url":"https://api.github.com/repos/django/django/compare/{base}...{head}","merges_url":"https://api.github.com/repos/django/django/merges","archive_url":"https://api.github.com/repos/django/django/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/django/django/downloads","issues_url":"https://api.github.com/repos/django/django/issues{/number}","pulls_url":"https://api.github.com/repos/django/django/pulls{/number}","milestones_url":"https://api.github.com/repos/django/django/milestones{/number}","notifications_url":"https://api.github.com/repos/django/django/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/django/django/labels{/name}","releases_url":"https://api.github.com/repos/django/django/releases{/id}","created_at":"2012-04-28T02:47:18Z","updated_at":"2015-05-18T20:21:51Z","pushed_at":"2015-05-18T21:56:03Z","git_url":"git://github.com/django/django.git","ssh_url":"git@github.com:django/django.git","clone_url":"https://github.com/django/django.git","svn_url":"https://github.com/django/django","homepage":"https://www.djangoproject.com/","size":297047,"stargazers_count":14277,"watchers_count":14277,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":5671,"mirror_url":null,"open_issues_count":73,"forks":5671,"open_issues":73,"watchers":14277,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/django/django/pulls/4633"},"html":{"href":"https://github.com/django/django/pull/4633"},"issue":{"href":"https://api.github.com/repos/django/django/issues/4633"},"comments":{"href":"https://api.github.com/repos/django/django/issues/4633/comments"},"review_comments":{"href":"https://api.github.com/repos/django/django/pulls/4633/comments"},"review_comment":{"href":"https://api.github.com/repos/django/django/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/django/django/pulls/4633/commits"},"statuses":{"href":"https://api.github.com/repos/django/django/statuses/80d9977c53d27497cbf5fbb2f3f4a5b0bdac8016"}},"merged":false,"mergeable":false,"mergeable_state":"dirty","merged_by":null,"comments":6,"review_comments":3,"commits":2,"additions":113,"deletions":10,"changed_files":6}}