{"action":"created","comment":{"url":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/comments/79965700","id":79965700,"diff_hunk":"@@ -151,11 +159,16 @@ def disconnect(self):\n         \"\"\"\n         self.log(\"serverdisconnect\", \"debug\", [repr(self.server_conn.address)])\n         address = self.server_conn.address\n-        source_address = self.server_conn.source_address\n         self.server_conn.finish()\n         self.server_conn.close()\n         self.channel.tell(\"serverdisconnect\", self.server_conn)\n-        self.server_conn = models.ServerConnection(address, (source_address.host, 0))\n+\n+        if self.config.options.spoof_source_address:","path":"mitmproxy/protocol/base.py","position":27,"original_position":27,"commit_id":"2d4e4eafe1545e9ac79c04fcfc48f198e85900aa","original_commit_id":"2d4e4eafe1545e9ac79c04fcfc48f198e85900aa","user":{"login":"mhils","id":1019198,"avatar_url":"https://avatars.githubusercontent.com/u/1019198?v=3","gravatar_id":"","url":"https://api.github.com/users/mhils","html_url":"https://github.com/mhils","followers_url":"https://api.github.com/users/mhils/followers","following_url":"https://api.github.com/users/mhils/following{/other_user}","gists_url":"https://api.github.com/users/mhils/gists{/gist_id}","starred_url":"https://api.github.com/users/mhils/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mhils/subscriptions","organizations_url":"https://api.github.com/users/mhils/orgs","repos_url":"https://api.github.com/users/mhils/repos","events_url":"https://api.github.com/users/mhils/events{/privacy}","received_events_url":"https://api.github.com/users/mhils/received_events","type":"User","site_admin":false},"body":"Wouldn't `source_address.host` work for both cases?","created_at":"2016-09-22T01:34:40Z","updated_at":"2016-09-22T01:45:48Z","html_url":"https://github.com/mitmproxy/mitmproxy/pull/1525#discussion_r79965700","pull_request_url":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525","_links":{"self":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/comments/79965700"},"html":{"href":"https://github.com/mitmproxy/mitmproxy/pull/1525#discussion_r79965700"},"pull_request":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525"}}},"pull_request":{"url":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525","id":83894495,"html_url":"https://github.com/mitmproxy/mitmproxy/pull/1525","diff_url":"https://github.com/mitmproxy/mitmproxy/pull/1525.diff","patch_url":"https://github.com/mitmproxy/mitmproxy/pull/1525.patch","issue_url":"https://api.github.com/repos/mitmproxy/mitmproxy/issues/1525","number":1525,"state":"open","locked":false,"title":"\"Fully transparent\" proxy mode.","user":{"login":"omfgroflbbq","id":5622198,"avatar_url":"https://avatars.githubusercontent.com/u/5622198?v=3","gravatar_id":"","url":"https://api.github.com/users/omfgroflbbq","html_url":"https://github.com/omfgroflbbq","followers_url":"https://api.github.com/users/omfgroflbbq/followers","following_url":"https://api.github.com/users/omfgroflbbq/following{/other_user}","gists_url":"https://api.github.com/users/omfgroflbbq/gists{/gist_id}","starred_url":"https://api.github.com/users/omfgroflbbq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/omfgroflbbq/subscriptions","organizations_url":"https://api.github.com/users/omfgroflbbq/orgs","repos_url":"https://api.github.com/users/omfgroflbbq/repos","events_url":"https://api.github.com/users/omfgroflbbq/events{/privacy}","received_events_url":"https://api.github.com/users/omfgroflbbq/received_events","type":"User","site_admin":false},"body":"Resolves #436.\r\nTODO: make sure the shim loader gets built using setuptools. ","created_at":"2016-09-03T12:30:06Z","updated_at":"2016-09-22T01:45:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a8eb5d4c9f9bc2af9dcec9d686a12d96de5725e4","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525/commits","review_comments_url":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525/comments","review_comment_url":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mitmproxy/mitmproxy/issues/1525/comments","statuses_url":"https://api.github.com/repos/mitmproxy/mitmproxy/statuses/2d4e4eafe1545e9ac79c04fcfc48f198e85900aa","head":{"label":"omfgroflbbq:master","ref":"master","sha":"2d4e4eafe1545e9ac79c04fcfc48f198e85900aa","user":{"login":"omfgroflbbq","id":5622198,"avatar_url":"https://avatars.githubusercontent.com/u/5622198?v=3","gravatar_id":"","url":"https://api.github.com/users/omfgroflbbq","html_url":"https://github.com/omfgroflbbq","followers_url":"https://api.github.com/users/omfgroflbbq/followers","following_url":"https://api.github.com/users/omfgroflbbq/following{/other_user}","gists_url":"https://api.github.com/users/omfgroflbbq/gists{/gist_id}","starred_url":"https://api.github.com/users/omfgroflbbq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/omfgroflbbq/subscriptions","organizations_url":"https://api.github.com/users/omfgroflbbq/orgs","repos_url":"https://api.github.com/users/omfgroflbbq/repos","events_url":"https://api.github.com/users/omfgroflbbq/events{/privacy}","received_events_url":"https://api.github.com/users/omfgroflbbq/received_events","type":"User","site_admin":false},"repo":{"id":67288665,"name":"mitmproxy","full_name":"omfgroflbbq/mitmproxy","owner":{"login":"omfgroflbbq","id":5622198,"avatar_url":"https://avatars.githubusercontent.com/u/5622198?v=3","gravatar_id":"","url":"https://api.github.com/users/omfgroflbbq","html_url":"https://github.com/omfgroflbbq","followers_url":"https://api.github.com/users/omfgroflbbq/followers","following_url":"https://api.github.com/users/omfgroflbbq/following{/other_user}","gists_url":"https://api.github.com/users/omfgroflbbq/gists{/gist_id}","starred_url":"https://api.github.com/users/omfgroflbbq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/omfgroflbbq/subscriptions","organizations_url":"https://api.github.com/users/omfgroflbbq/orgs","repos_url":"https://api.github.com/users/omfgroflbbq/repos","events_url":"https://api.github.com/users/omfgroflbbq/events{/privacy}","received_events_url":"https://api.github.com/users/omfgroflbbq/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/omfgroflbbq/mitmproxy","description":"An interactive TLS-capable intercepting HTTP proxy for penetration testers and software developers","fork":true,"url":"https://api.github.com/repos/omfgroflbbq/mitmproxy","forks_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/forks","keys_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/teams","hooks_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/hooks","issue_events_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/issues/events{/number}","events_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/events","assignees_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/assignees{/user}","branches_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/branches{/branch}","tags_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/tags","blobs_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/git/refs{/sha}","trees_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/statuses/{sha}","languages_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/languages","stargazers_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/stargazers","contributors_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/contributors","subscribers_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/subscribers","subscription_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/subscription","commits_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/commits{/sha}","git_commits_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/git/commits{/sha}","comments_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/comments{/number}","issue_comment_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/issues/comments{/number}","contents_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/contents/{+path}","compare_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/merges","archive_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/downloads","issues_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/issues{/number}","pulls_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/pulls{/number}","milestones_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/milestones{/number}","notifications_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/labels{/name}","releases_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/releases{/id}","deployments_url":"https://api.github.com/repos/omfgroflbbq/mitmproxy/deployments","created_at":"2016-09-03T12:21:13Z","updated_at":"2016-09-03T12:21:15Z","pushed_at":"2016-09-15T18:55:32Z","git_url":"git://github.com/omfgroflbbq/mitmproxy.git","ssh_url":"git@github.com:omfgroflbbq/mitmproxy.git","clone_url":"https://github.com/omfgroflbbq/mitmproxy.git","svn_url":"https://github.com/omfgroflbbq/mitmproxy","homepage":"http://mitmproxy.org","size":32020,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"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":"mitmproxy:master","ref":"master","sha":"b476966a45a6f77b1a819867dbbc943af9a57ef0","user":{"login":"mitmproxy","id":4652787,"avatar_url":"https://avatars.githubusercontent.com/u/4652787?v=3","gravatar_id":"","url":"https://api.github.com/users/mitmproxy","html_url":"https://github.com/mitmproxy","followers_url":"https://api.github.com/users/mitmproxy/followers","following_url":"https://api.github.com/users/mitmproxy/following{/other_user}","gists_url":"https://api.github.com/users/mitmproxy/gists{/gist_id}","starred_url":"https://api.github.com/users/mitmproxy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mitmproxy/subscriptions","organizations_url":"https://api.github.com/users/mitmproxy/orgs","repos_url":"https://api.github.com/users/mitmproxy/repos","events_url":"https://api.github.com/users/mitmproxy/events{/privacy}","received_events_url":"https://api.github.com/users/mitmproxy/received_events","type":"Organization","site_admin":false},"repo":{"id":519832,"name":"mitmproxy","full_name":"mitmproxy/mitmproxy","owner":{"login":"mitmproxy","id":4652787,"avatar_url":"https://avatars.githubusercontent.com/u/4652787?v=3","gravatar_id":"","url":"https://api.github.com/users/mitmproxy","html_url":"https://github.com/mitmproxy","followers_url":"https://api.github.com/users/mitmproxy/followers","following_url":"https://api.github.com/users/mitmproxy/following{/other_user}","gists_url":"https://api.github.com/users/mitmproxy/gists{/gist_id}","starred_url":"https://api.github.com/users/mitmproxy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mitmproxy/subscriptions","organizations_url":"https://api.github.com/users/mitmproxy/orgs","repos_url":"https://api.github.com/users/mitmproxy/repos","events_url":"https://api.github.com/users/mitmproxy/events{/privacy}","received_events_url":"https://api.github.com/users/mitmproxy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mitmproxy/mitmproxy","description":"An interactive TLS-capable intercepting HTTP proxy for penetration testers and software developers","fork":false,"url":"https://api.github.com/repos/mitmproxy/mitmproxy","forks_url":"https://api.github.com/repos/mitmproxy/mitmproxy/forks","keys_url":"https://api.github.com/repos/mitmproxy/mitmproxy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mitmproxy/mitmproxy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mitmproxy/mitmproxy/teams","hooks_url":"https://api.github.com/repos/mitmproxy/mitmproxy/hooks","issue_events_url":"https://api.github.com/repos/mitmproxy/mitmproxy/issues/events{/number}","events_url":"https://api.github.com/repos/mitmproxy/mitmproxy/events","assignees_url":"https://api.github.com/repos/mitmproxy/mitmproxy/assignees{/user}","branches_url":"https://api.github.com/repos/mitmproxy/mitmproxy/branches{/branch}","tags_url":"https://api.github.com/repos/mitmproxy/mitmproxy/tags","blobs_url":"https://api.github.com/repos/mitmproxy/mitmproxy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mitmproxy/mitmproxy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mitmproxy/mitmproxy/git/refs{/sha}","trees_url":"https://api.github.com/repos/mitmproxy/mitmproxy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mitmproxy/mitmproxy/statuses/{sha}","languages_url":"https://api.github.com/repos/mitmproxy/mitmproxy/languages","stargazers_url":"https://api.github.com/repos/mitmproxy/mitmproxy/stargazers","contributors_url":"https://api.github.com/repos/mitmproxy/mitmproxy/contributors","subscribers_url":"https://api.github.com/repos/mitmproxy/mitmproxy/subscribers","subscription_url":"https://api.github.com/repos/mitmproxy/mitmproxy/subscription","commits_url":"https://api.github.com/repos/mitmproxy/mitmproxy/commits{/sha}","git_commits_url":"https://api.github.com/repos/mitmproxy/mitmproxy/git/commits{/sha}","comments_url":"https://api.github.com/repos/mitmproxy/mitmproxy/comments{/number}","issue_comment_url":"https://api.github.com/repos/mitmproxy/mitmproxy/issues/comments{/number}","contents_url":"https://api.github.com/repos/mitmproxy/mitmproxy/contents/{+path}","compare_url":"https://api.github.com/repos/mitmproxy/mitmproxy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mitmproxy/mitmproxy/merges","archive_url":"https://api.github.com/repos/mitmproxy/mitmproxy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mitmproxy/mitmproxy/downloads","issues_url":"https://api.github.com/repos/mitmproxy/mitmproxy/issues{/number}","pulls_url":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls{/number}","milestones_url":"https://api.github.com/repos/mitmproxy/mitmproxy/milestones{/number}","notifications_url":"https://api.github.com/repos/mitmproxy/mitmproxy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mitmproxy/mitmproxy/labels{/name}","releases_url":"https://api.github.com/repos/mitmproxy/mitmproxy/releases{/id}","deployments_url":"https://api.github.com/repos/mitmproxy/mitmproxy/deployments","created_at":"2010-02-16T04:10:13Z","updated_at":"2016-09-21T14:36:25Z","pushed_at":"2016-09-22T01:13:15Z","git_url":"git://github.com/mitmproxy/mitmproxy.git","ssh_url":"git@github.com:mitmproxy/mitmproxy.git","clone_url":"https://github.com/mitmproxy/mitmproxy.git","svn_url":"https://github.com/mitmproxy/mitmproxy","homepage":"http://mitmproxy.org","size":39676,"stargazers_count":5734,"watchers_count":5734,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":813,"mirror_url":null,"open_issues_count":88,"forks":813,"open_issues":88,"watchers":5734,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525"},"html":{"href":"https://github.com/mitmproxy/mitmproxy/pull/1525"},"issue":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/issues/1525"},"comments":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/issues/1525/comments"},"review_comments":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525/comments"},"review_comment":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/pulls/1525/commits"},"statuses":{"href":"https://api.github.com/repos/mitmproxy/mitmproxy/statuses/2d4e4eafe1545e9ac79c04fcfc48f198e85900aa"}}}}
{"actor":{"display_login":"mhils"}}