{"action":"created","comment":{"url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/comments/44372104","id":44372104,"diff_hunk":"@@ -10,7 +22,92 @@ SubHandlers = {\n var uniqueId = 0;\n var serverId = Random.id();\n \n-Meteor.publish('kadira.debug.init', function(browserId, clientId) {\n+// publications\n+\n+Meteor.publish('kadira.debug.remote.auth', function(authKey) {\n+  check(authKey, Match.Any);\n+\n+  if(AppConfig.env === 'production') {\n+    if(authKey !== AppConfig.authKey) {\n+      throw new Meteor.Error('401', 'Unauthorized.');\n+    }\n+\n+    var kadiraInfo = Kadira._getInfo();\n+    var sessionId = kadiraInfo.session;\n+\n+    AppConfig._authorizedSessions.remote[sessionId] = true;\n+  }\n+\n+  this.onStop(function() {\n+    delete AppConfig._authorizedSessions.remote[sessionId];\n+  });\n+\n+  this.ready();\n+});\n+\n+Meteor.publish('kadira.debug.remote.timeline', function() {\n+","path":"lib/server/connect.js","position":45,"original_position":45,"commit_id":"436a323eb45b9cf30a8dd7f33f44b1964b1f92a2","original_commit_id":"436a323eb45b9cf30a8dd7f33f44b1964b1f92a2","user":{"login":"arunoda","id":50838,"avatar_url":"https://avatars.githubusercontent.com/u/50838?v=3","gravatar_id":"","url":"https://api.github.com/users/arunoda","html_url":"https://github.com/arunoda","followers_url":"https://api.github.com/users/arunoda/followers","following_url":"https://api.github.com/users/arunoda/following{/other_user}","gists_url":"https://api.github.com/users/arunoda/gists{/gist_id}","starred_url":"https://api.github.com/users/arunoda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/arunoda/subscriptions","organizations_url":"https://api.github.com/users/arunoda/orgs","repos_url":"https://api.github.com/users/arunoda/repos","events_url":"https://api.github.com/users/arunoda/events{/privacy}","received_events_url":"https://api.github.com/users/arunoda/received_events","type":"User","site_admin":false},"body":"remove this space.","created_at":"2015-11-10T05:46:45Z","updated_at":"2015-11-10T05:46:45Z","html_url":"https://github.com/kadirahq/meteor-debug/pull/20#discussion_r44372104","pull_request_url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20","_links":{"self":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/comments/44372104"},"html":{"href":"https://github.com/kadirahq/meteor-debug/pull/20#discussion_r44372104"},"pull_request":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20"}}},"pull_request":{"url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20","id":49141853,"html_url":"https://github.com/kadirahq/meteor-debug/pull/20","diff_url":"https://github.com/kadirahq/meteor-debug/pull/20.diff","patch_url":"https://github.com/kadirahq/meteor-debug/pull/20.patch","issue_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues/20","number":20,"state":"open","locked":false,"title":"Kadira Debug Support for Production Apps","user":{"login":"thinkholic","id":1164024,"avatar_url":"https://avatars.githubusercontent.com/u/1164024?v=3","gravatar_id":"","url":"https://api.github.com/users/thinkholic","html_url":"https://github.com/thinkholic","followers_url":"https://api.github.com/users/thinkholic/followers","following_url":"https://api.github.com/users/thinkholic/following{/other_user}","gists_url":"https://api.github.com/users/thinkholic/gists{/gist_id}","starred_url":"https://api.github.com/users/thinkholic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thinkholic/subscriptions","organizations_url":"https://api.github.com/users/thinkholic/orgs","repos_url":"https://api.github.com/users/thinkholic/repos","events_url":"https://api.github.com/users/thinkholic/events{/privacy}","received_events_url":"https://api.github.com/users/thinkholic/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-10-29T13:54:07Z","updated_at":"2015-11-10T05:46:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"67acdf0de732afd8d236a20678b588049a29620c","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20/commits","review_comments_url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20/comments","review_comment_url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues/20/comments","statuses_url":"https://api.github.com/repos/kadirahq/meteor-debug/statuses/436a323eb45b9cf30a8dd7f33f44b1964b1f92a2","head":{"label":"kadirahq:kd-production","ref":"kd-production","sha":"436a323eb45b9cf30a8dd7f33f44b1964b1f92a2","user":{"login":"kadirahq","id":13164545,"avatar_url":"https://avatars.githubusercontent.com/u/13164545?v=3","gravatar_id":"","url":"https://api.github.com/users/kadirahq","html_url":"https://github.com/kadirahq","followers_url":"https://api.github.com/users/kadirahq/followers","following_url":"https://api.github.com/users/kadirahq/following{/other_user}","gists_url":"https://api.github.com/users/kadirahq/gists{/gist_id}","starred_url":"https://api.github.com/users/kadirahq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kadirahq/subscriptions","organizations_url":"https://api.github.com/users/kadirahq/orgs","repos_url":"https://api.github.com/users/kadirahq/repos","events_url":"https://api.github.com/users/kadirahq/events{/privacy}","received_events_url":"https://api.github.com/users/kadirahq/received_events","type":"Organization","site_admin":false},"repo":{"id":36714391,"name":"meteor-debug","full_name":"kadirahq/meteor-debug","owner":{"login":"kadirahq","id":13164545,"avatar_url":"https://avatars.githubusercontent.com/u/13164545?v=3","gravatar_id":"","url":"https://api.github.com/users/kadirahq","html_url":"https://github.com/kadirahq","followers_url":"https://api.github.com/users/kadirahq/followers","following_url":"https://api.github.com/users/kadirahq/following{/other_user}","gists_url":"https://api.github.com/users/kadirahq/gists{/gist_id}","starred_url":"https://api.github.com/users/kadirahq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kadirahq/subscriptions","organizations_url":"https://api.github.com/users/kadirahq/orgs","repos_url":"https://api.github.com/users/kadirahq/repos","events_url":"https://api.github.com/users/kadirahq/events{/privacy}","received_events_url":"https://api.github.com/users/kadirahq/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/kadirahq/meteor-debug","description":"Full Stack Debugging Solution for Meteor","fork":false,"url":"https://api.github.com/repos/kadirahq/meteor-debug","forks_url":"https://api.github.com/repos/kadirahq/meteor-debug/forks","keys_url":"https://api.github.com/repos/kadirahq/meteor-debug/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kadirahq/meteor-debug/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kadirahq/meteor-debug/teams","hooks_url":"https://api.github.com/repos/kadirahq/meteor-debug/hooks","issue_events_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues/events{/number}","events_url":"https://api.github.com/repos/kadirahq/meteor-debug/events","assignees_url":"https://api.github.com/repos/kadirahq/meteor-debug/assignees{/user}","branches_url":"https://api.github.com/repos/kadirahq/meteor-debug/branches{/branch}","tags_url":"https://api.github.com/repos/kadirahq/meteor-debug/tags","blobs_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/refs{/sha}","trees_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kadirahq/meteor-debug/statuses/{sha}","languages_url":"https://api.github.com/repos/kadirahq/meteor-debug/languages","stargazers_url":"https://api.github.com/repos/kadirahq/meteor-debug/stargazers","contributors_url":"https://api.github.com/repos/kadirahq/meteor-debug/contributors","subscribers_url":"https://api.github.com/repos/kadirahq/meteor-debug/subscribers","subscription_url":"https://api.github.com/repos/kadirahq/meteor-debug/subscription","commits_url":"https://api.github.com/repos/kadirahq/meteor-debug/commits{/sha}","git_commits_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/commits{/sha}","comments_url":"https://api.github.com/repos/kadirahq/meteor-debug/comments{/number}","issue_comment_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues/comments{/number}","contents_url":"https://api.github.com/repos/kadirahq/meteor-debug/contents/{+path}","compare_url":"https://api.github.com/repos/kadirahq/meteor-debug/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kadirahq/meteor-debug/merges","archive_url":"https://api.github.com/repos/kadirahq/meteor-debug/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kadirahq/meteor-debug/downloads","issues_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues{/number}","pulls_url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls{/number}","milestones_url":"https://api.github.com/repos/kadirahq/meteor-debug/milestones{/number}","notifications_url":"https://api.github.com/repos/kadirahq/meteor-debug/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kadirahq/meteor-debug/labels{/name}","releases_url":"https://api.github.com/repos/kadirahq/meteor-debug/releases{/id}","created_at":"2015-06-02T06:59:17Z","updated_at":"2015-11-08T07:25:28Z","pushed_at":"2015-11-06T12:35:09Z","git_url":"git://github.com/kadirahq/meteor-debug.git","ssh_url":"git@github.com:kadirahq/meteor-debug.git","clone_url":"https://github.com/kadirahq/meteor-debug.git","svn_url":"https://github.com/kadirahq/meteor-debug","homepage":"https://kadira.io/platform/kadira-debug/overview","size":458,"stargazers_count":97,"watchers_count":97,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":7,"forks":5,"open_issues":7,"watchers":97,"default_branch":"master"}},"base":{"label":"kadirahq:master","ref":"master","sha":"1c961adc107ff5cb7a6f60106b71b173a501b446","user":{"login":"kadirahq","id":13164545,"avatar_url":"https://avatars.githubusercontent.com/u/13164545?v=3","gravatar_id":"","url":"https://api.github.com/users/kadirahq","html_url":"https://github.com/kadirahq","followers_url":"https://api.github.com/users/kadirahq/followers","following_url":"https://api.github.com/users/kadirahq/following{/other_user}","gists_url":"https://api.github.com/users/kadirahq/gists{/gist_id}","starred_url":"https://api.github.com/users/kadirahq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kadirahq/subscriptions","organizations_url":"https://api.github.com/users/kadirahq/orgs","repos_url":"https://api.github.com/users/kadirahq/repos","events_url":"https://api.github.com/users/kadirahq/events{/privacy}","received_events_url":"https://api.github.com/users/kadirahq/received_events","type":"Organization","site_admin":false},"repo":{"id":36714391,"name":"meteor-debug","full_name":"kadirahq/meteor-debug","owner":{"login":"kadirahq","id":13164545,"avatar_url":"https://avatars.githubusercontent.com/u/13164545?v=3","gravatar_id":"","url":"https://api.github.com/users/kadirahq","html_url":"https://github.com/kadirahq","followers_url":"https://api.github.com/users/kadirahq/followers","following_url":"https://api.github.com/users/kadirahq/following{/other_user}","gists_url":"https://api.github.com/users/kadirahq/gists{/gist_id}","starred_url":"https://api.github.com/users/kadirahq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kadirahq/subscriptions","organizations_url":"https://api.github.com/users/kadirahq/orgs","repos_url":"https://api.github.com/users/kadirahq/repos","events_url":"https://api.github.com/users/kadirahq/events{/privacy}","received_events_url":"https://api.github.com/users/kadirahq/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/kadirahq/meteor-debug","description":"Full Stack Debugging Solution for Meteor","fork":false,"url":"https://api.github.com/repos/kadirahq/meteor-debug","forks_url":"https://api.github.com/repos/kadirahq/meteor-debug/forks","keys_url":"https://api.github.com/repos/kadirahq/meteor-debug/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kadirahq/meteor-debug/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kadirahq/meteor-debug/teams","hooks_url":"https://api.github.com/repos/kadirahq/meteor-debug/hooks","issue_events_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues/events{/number}","events_url":"https://api.github.com/repos/kadirahq/meteor-debug/events","assignees_url":"https://api.github.com/repos/kadirahq/meteor-debug/assignees{/user}","branches_url":"https://api.github.com/repos/kadirahq/meteor-debug/branches{/branch}","tags_url":"https://api.github.com/repos/kadirahq/meteor-debug/tags","blobs_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/refs{/sha}","trees_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kadirahq/meteor-debug/statuses/{sha}","languages_url":"https://api.github.com/repos/kadirahq/meteor-debug/languages","stargazers_url":"https://api.github.com/repos/kadirahq/meteor-debug/stargazers","contributors_url":"https://api.github.com/repos/kadirahq/meteor-debug/contributors","subscribers_url":"https://api.github.com/repos/kadirahq/meteor-debug/subscribers","subscription_url":"https://api.github.com/repos/kadirahq/meteor-debug/subscription","commits_url":"https://api.github.com/repos/kadirahq/meteor-debug/commits{/sha}","git_commits_url":"https://api.github.com/repos/kadirahq/meteor-debug/git/commits{/sha}","comments_url":"https://api.github.com/repos/kadirahq/meteor-debug/comments{/number}","issue_comment_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues/comments{/number}","contents_url":"https://api.github.com/repos/kadirahq/meteor-debug/contents/{+path}","compare_url":"https://api.github.com/repos/kadirahq/meteor-debug/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kadirahq/meteor-debug/merges","archive_url":"https://api.github.com/repos/kadirahq/meteor-debug/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kadirahq/meteor-debug/downloads","issues_url":"https://api.github.com/repos/kadirahq/meteor-debug/issues{/number}","pulls_url":"https://api.github.com/repos/kadirahq/meteor-debug/pulls{/number}","milestones_url":"https://api.github.com/repos/kadirahq/meteor-debug/milestones{/number}","notifications_url":"https://api.github.com/repos/kadirahq/meteor-debug/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kadirahq/meteor-debug/labels{/name}","releases_url":"https://api.github.com/repos/kadirahq/meteor-debug/releases{/id}","created_at":"2015-06-02T06:59:17Z","updated_at":"2015-11-08T07:25:28Z","pushed_at":"2015-11-06T12:35:09Z","git_url":"git://github.com/kadirahq/meteor-debug.git","ssh_url":"git@github.com:kadirahq/meteor-debug.git","clone_url":"https://github.com/kadirahq/meteor-debug.git","svn_url":"https://github.com/kadirahq/meteor-debug","homepage":"https://kadira.io/platform/kadira-debug/overview","size":458,"stargazers_count":97,"watchers_count":97,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":7,"forks":5,"open_issues":7,"watchers":97,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20"},"html":{"href":"https://github.com/kadirahq/meteor-debug/pull/20"},"issue":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/issues/20"},"comments":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/kadirahq/meteor-debug/statuses/436a323eb45b9cf30a8dd7f33f44b1964b1f92a2"}}}}