{"action":"created","comment":{"url":"https://api.github.com/repos/lookout/borderpatrol/pulls/comments/41631619","id":41631619,"diff_hunk":"@@ -91,12 +91,17 @@ object SessionId {\n   def toCookie(id: SessionId): Cookie =\n     new Cookie(\"border_session\", toBase64(id))\n \n-  def fromRequest(req: Request)(implicit ev: SecretStoreApi): Try[SessionId] =\n-    req.cookies.get(\"border_session\") match {\n+  def fromCookie(cooki: Option[Cookie])(implicit ev: SecretStoreApi): Try[SessionId] =\n+    cooki match {\n       case Some(cookie) => SessionId.from[Cookie](cookie)\n       case None => Failure(SessionIdError(\"no border_session cookie\"))\n     }\n \n+  def fromRequest(req: Request)(implicit ev: SecretStoreApi): Try[SessionId] =\n+    fromCookie(req.cookies.get(\"border_session\"))\n+\n+  def fromResponse(rep: Response)(implicit ev: SecretStoreApi): Try[SessionId] =","path":"core/src/main/scala/com/lookout/borderpatrol/sessionx/SessionId.scala","position":24,"original_position":24,"commit_id":"feb793513a896e43f14b2fd8511e93ec7abfa41a","original_commit_id":"feb793513a896e43f14b2fd8511e93ec7abfa41a","user":{"login":"maheshkelkar","id":10839177,"avatar_url":"https://avatars.githubusercontent.com/u/10839177?v=3","gravatar_id":"","url":"https://api.github.com/users/maheshkelkar","html_url":"https://github.com/maheshkelkar","followers_url":"https://api.github.com/users/maheshkelkar/followers","following_url":"https://api.github.com/users/maheshkelkar/following{/other_user}","gists_url":"https://api.github.com/users/maheshkelkar/gists{/gist_id}","starred_url":"https://api.github.com/users/maheshkelkar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maheshkelkar/subscriptions","organizations_url":"https://api.github.com/users/maheshkelkar/orgs","repos_url":"https://api.github.com/users/maheshkelkar/repos","events_url":"https://api.github.com/users/maheshkelkar/events{/privacy}","received_events_url":"https://api.github.com/users/maheshkelkar/received_events","type":"User","site_admin":false},"body":"For scalatests","created_at":"2015-10-09T13:52:06Z","updated_at":"2015-10-09T13:52:06Z","html_url":"https://github.com/lookout/borderpatrol/pull/75#discussion_r41631619","pull_request_url":"https://api.github.com/repos/lookout/borderpatrol/pulls/75","_links":{"self":{"href":"https://api.github.com/repos/lookout/borderpatrol/pulls/comments/41631619"},"html":{"href":"https://github.com/lookout/borderpatrol/pull/75#discussion_r41631619"},"pull_request":{"href":"https://api.github.com/repos/lookout/borderpatrol/pulls/75"}}},"pull_request":{"url":"https://api.github.com/repos/lookout/borderpatrol/pulls/75","id":46814076,"html_url":"https://github.com/lookout/borderpatrol/pull/75","diff_url":"https://github.com/lookout/borderpatrol/pull/75.diff","patch_url":"https://github.com/lookout/borderpatrol/pull/75.patch","issue_url":"https://api.github.com/repos/lookout/borderpatrol/issues/75","number":75,"state":"open","locked":false,"title":"Added scalatests for Core and Auth abstractions","user":{"login":"maheshkelkar","id":10839177,"avatar_url":"https://avatars.githubusercontent.com/u/10839177?v=3","gravatar_id":"","url":"https://api.github.com/users/maheshkelkar","html_url":"https://github.com/maheshkelkar","followers_url":"https://api.github.com/users/maheshkelkar/followers","following_url":"https://api.github.com/users/maheshkelkar/following{/other_user}","gists_url":"https://api.github.com/users/maheshkelkar/gists{/gist_id}","starred_url":"https://api.github.com/users/maheshkelkar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maheshkelkar/subscriptions","organizations_url":"https://api.github.com/users/maheshkelkar/orgs","repos_url":"https://api.github.com/users/maheshkelkar/repos","events_url":"https://api.github.com/users/maheshkelkar/events{/privacy}","received_events_url":"https://api.github.com/users/maheshkelkar/received_events","type":"User","site_admin":false},"body":"Add scalatests for functionality referenced in #72, #73, #74 (SessionIdFilter, ServiceFilter, IdentityFilter, KeymasterLoginFilter, KeymasterIdentityProvider, KeymasterAccessIssuer)\r\n\r\nFixes #59 ","created_at":"2015-10-05T18:14:09Z","updated_at":"2015-10-09T13:52:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"90dee4165f95826e3039f0a8029881fdb4ecdcef","assignee":{"login":"trane","id":36095,"avatar_url":"https://avatars.githubusercontent.com/u/36095?v=3","gravatar_id":"","url":"https://api.github.com/users/trane","html_url":"https://github.com/trane","followers_url":"https://api.github.com/users/trane/followers","following_url":"https://api.github.com/users/trane/following{/other_user}","gists_url":"https://api.github.com/users/trane/gists{/gist_id}","starred_url":"https://api.github.com/users/trane/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trane/subscriptions","organizations_url":"https://api.github.com/users/trane/orgs","repos_url":"https://api.github.com/users/trane/repos","events_url":"https://api.github.com/users/trane/events{/privacy}","received_events_url":"https://api.github.com/users/trane/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/lookout/borderpatrol/pulls/75/commits","review_comments_url":"https://api.github.com/repos/lookout/borderpatrol/pulls/75/comments","review_comment_url":"https://api.github.com/repos/lookout/borderpatrol/pulls/comments{/number}","comments_url":"https://api.github.com/repos/lookout/borderpatrol/issues/75/comments","statuses_url":"https://api.github.com/repos/lookout/borderpatrol/statuses/feb793513a896e43f14b2fd8511e93ec7abfa41a","head":{"label":"maheshkelkar:add-scalatests-for-auth-code","ref":"add-scalatests-for-auth-code","sha":"feb793513a896e43f14b2fd8511e93ec7abfa41a","user":{"login":"maheshkelkar","id":10839177,"avatar_url":"https://avatars.githubusercontent.com/u/10839177?v=3","gravatar_id":"","url":"https://api.github.com/users/maheshkelkar","html_url":"https://github.com/maheshkelkar","followers_url":"https://api.github.com/users/maheshkelkar/followers","following_url":"https://api.github.com/users/maheshkelkar/following{/other_user}","gists_url":"https://api.github.com/users/maheshkelkar/gists{/gist_id}","starred_url":"https://api.github.com/users/maheshkelkar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maheshkelkar/subscriptions","organizations_url":"https://api.github.com/users/maheshkelkar/orgs","repos_url":"https://api.github.com/users/maheshkelkar/repos","events_url":"https://api.github.com/users/maheshkelkar/events{/privacy}","received_events_url":"https://api.github.com/users/maheshkelkar/received_events","type":"User","site_admin":false},"repo":{"id":41160852,"name":"borderpatrol","full_name":"maheshkelkar/borderpatrol","owner":{"login":"maheshkelkar","id":10839177,"avatar_url":"https://avatars.githubusercontent.com/u/10839177?v=3","gravatar_id":"","url":"https://api.github.com/users/maheshkelkar","html_url":"https://github.com/maheshkelkar","followers_url":"https://api.github.com/users/maheshkelkar/followers","following_url":"https://api.github.com/users/maheshkelkar/following{/other_user}","gists_url":"https://api.github.com/users/maheshkelkar/gists{/gist_id}","starred_url":"https://api.github.com/users/maheshkelkar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maheshkelkar/subscriptions","organizations_url":"https://api.github.com/users/maheshkelkar/orgs","repos_url":"https://api.github.com/users/maheshkelkar/repos","events_url":"https://api.github.com/users/maheshkelkar/events{/privacy}","received_events_url":"https://api.github.com/users/maheshkelkar/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/maheshkelkar/borderpatrol","description":"Functional library for web sessions and authentication in an SOA","fork":true,"url":"https://api.github.com/repos/maheshkelkar/borderpatrol","forks_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/forks","keys_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/keys{/key_id}","collaborators_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/teams","hooks_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/hooks","issue_events_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/issues/events{/number}","events_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/events","assignees_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/assignees{/user}","branches_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/branches{/branch}","tags_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/tags","blobs_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/git/refs{/sha}","trees_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/git/trees{/sha}","statuses_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/statuses/{sha}","languages_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/languages","stargazers_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/stargazers","contributors_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/contributors","subscribers_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/subscribers","subscription_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/subscription","commits_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/commits{/sha}","git_commits_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/git/commits{/sha}","comments_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/comments{/number}","issue_comment_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/issues/comments{/number}","contents_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/contents/{+path}","compare_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/compare/{base}...{head}","merges_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/merges","archive_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/downloads","issues_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/issues{/number}","pulls_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/pulls{/number}","milestones_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/milestones{/number}","notifications_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/labels{/name}","releases_url":"https://api.github.com/repos/maheshkelkar/borderpatrol/releases{/id}","created_at":"2015-08-21T14:40:33Z","updated_at":"2015-08-21T14:40:33Z","pushed_at":"2015-10-08T20:22:56Z","git_url":"git://github.com/maheshkelkar/borderpatrol.git","ssh_url":"git@github.com:maheshkelkar/borderpatrol.git","clone_url":"https://github.com/maheshkelkar/borderpatrol.git","svn_url":"https://github.com/maheshkelkar/borderpatrol","homepage":"http://hackers.lookout.com/2014/06/introducing-borderpatrol/","size":923,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"lookout:master","ref":"master","sha":"eaaca6baf28067925ded15745909a42619adba1b","user":{"login":"lookout","id":47237,"avatar_url":"https://avatars.githubusercontent.com/u/47237?v=3","gravatar_id":"","url":"https://api.github.com/users/lookout","html_url":"https://github.com/lookout","followers_url":"https://api.github.com/users/lookout/followers","following_url":"https://api.github.com/users/lookout/following{/other_user}","gists_url":"https://api.github.com/users/lookout/gists{/gist_id}","starred_url":"https://api.github.com/users/lookout/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lookout/subscriptions","organizations_url":"https://api.github.com/users/lookout/orgs","repos_url":"https://api.github.com/users/lookout/repos","events_url":"https://api.github.com/users/lookout/events{/privacy}","received_events_url":"https://api.github.com/users/lookout/received_events","type":"Organization","site_admin":false},"repo":{"id":20500575,"name":"borderpatrol","full_name":"lookout/borderpatrol","owner":{"login":"lookout","id":47237,"avatar_url":"https://avatars.githubusercontent.com/u/47237?v=3","gravatar_id":"","url":"https://api.github.com/users/lookout","html_url":"https://github.com/lookout","followers_url":"https://api.github.com/users/lookout/followers","following_url":"https://api.github.com/users/lookout/following{/other_user}","gists_url":"https://api.github.com/users/lookout/gists{/gist_id}","starred_url":"https://api.github.com/users/lookout/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lookout/subscriptions","organizations_url":"https://api.github.com/users/lookout/orgs","repos_url":"https://api.github.com/users/lookout/repos","events_url":"https://api.github.com/users/lookout/events{/privacy}","received_events_url":"https://api.github.com/users/lookout/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/lookout/borderpatrol","description":"Functional library for web sessions and authentication in an SOA","fork":false,"url":"https://api.github.com/repos/lookout/borderpatrol","forks_url":"https://api.github.com/repos/lookout/borderpatrol/forks","keys_url":"https://api.github.com/repos/lookout/borderpatrol/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lookout/borderpatrol/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lookout/borderpatrol/teams","hooks_url":"https://api.github.com/repos/lookout/borderpatrol/hooks","issue_events_url":"https://api.github.com/repos/lookout/borderpatrol/issues/events{/number}","events_url":"https://api.github.com/repos/lookout/borderpatrol/events","assignees_url":"https://api.github.com/repos/lookout/borderpatrol/assignees{/user}","branches_url":"https://api.github.com/repos/lookout/borderpatrol/branches{/branch}","tags_url":"https://api.github.com/repos/lookout/borderpatrol/tags","blobs_url":"https://api.github.com/repos/lookout/borderpatrol/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lookout/borderpatrol/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lookout/borderpatrol/git/refs{/sha}","trees_url":"https://api.github.com/repos/lookout/borderpatrol/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lookout/borderpatrol/statuses/{sha}","languages_url":"https://api.github.com/repos/lookout/borderpatrol/languages","stargazers_url":"https://api.github.com/repos/lookout/borderpatrol/stargazers","contributors_url":"https://api.github.com/repos/lookout/borderpatrol/contributors","subscribers_url":"https://api.github.com/repos/lookout/borderpatrol/subscribers","subscription_url":"https://api.github.com/repos/lookout/borderpatrol/subscription","commits_url":"https://api.github.com/repos/lookout/borderpatrol/commits{/sha}","git_commits_url":"https://api.github.com/repos/lookout/borderpatrol/git/commits{/sha}","comments_url":"https://api.github.com/repos/lookout/borderpatrol/comments{/number}","issue_comment_url":"https://api.github.com/repos/lookout/borderpatrol/issues/comments{/number}","contents_url":"https://api.github.com/repos/lookout/borderpatrol/contents/{+path}","compare_url":"https://api.github.com/repos/lookout/borderpatrol/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lookout/borderpatrol/merges","archive_url":"https://api.github.com/repos/lookout/borderpatrol/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lookout/borderpatrol/downloads","issues_url":"https://api.github.com/repos/lookout/borderpatrol/issues{/number}","pulls_url":"https://api.github.com/repos/lookout/borderpatrol/pulls{/number}","milestones_url":"https://api.github.com/repos/lookout/borderpatrol/milestones{/number}","notifications_url":"https://api.github.com/repos/lookout/borderpatrol/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lookout/borderpatrol/labels{/name}","releases_url":"https://api.github.com/repos/lookout/borderpatrol/releases{/id}","created_at":"2014-06-04T21:00:49Z","updated_at":"2015-10-01T14:12:52Z","pushed_at":"2015-10-08T20:22:56Z","git_url":"git://github.com/lookout/borderpatrol.git","ssh_url":"git@github.com:lookout/borderpatrol.git","clone_url":"https://github.com/lookout/borderpatrol.git","svn_url":"https://github.com/lookout/borderpatrol","homepage":"http://hackers.lookout.com/2014/06/introducing-borderpatrol/","size":1781,"stargazers_count":15,"watchers_count":15,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":11,"mirror_url":null,"open_issues_count":28,"forks":11,"open_issues":28,"watchers":15,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/lookout/borderpatrol/pulls/75"},"html":{"href":"https://github.com/lookout/borderpatrol/pull/75"},"issue":{"href":"https://api.github.com/repos/lookout/borderpatrol/issues/75"},"comments":{"href":"https://api.github.com/repos/lookout/borderpatrol/issues/75/comments"},"review_comments":{"href":"https://api.github.com/repos/lookout/borderpatrol/pulls/75/comments"},"review_comment":{"href":"https://api.github.com/repos/lookout/borderpatrol/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/lookout/borderpatrol/pulls/75/commits"},"statuses":{"href":"https://api.github.com/repos/lookout/borderpatrol/statuses/feb793513a896e43f14b2fd8511e93ec7abfa41a"}}}}