{"action":"closed","number":76,"pull_request":{"url":"https://api.github.com/repos/bcgit/bc-java/pulls/76","id":17911756,"html_url":"https://github.com/bcgit/bc-java/pull/76","diff_url":"https://github.com/bcgit/bc-java/pull/76.diff","patch_url":"https://github.com/bcgit/bc-java/pull/76.patch","issue_url":"https://api.github.com/repos/bcgit/bc-java/issues/76","number":76,"state":"closed","locked":false,"title":"BCrypt implementation","user":{"login":"timw","id":670828,"avatar_url":"https://avatars.githubusercontent.com/u/670828?v=3","gravatar_id":"","url":"https://api.github.com/users/timw","html_url":"https://github.com/timw","followers_url":"https://api.github.com/users/timw/followers","following_url":"https://api.github.com/users/timw/following{/other_user}","gists_url":"https://api.github.com/users/timw/gists{/gist_id}","starred_url":"https://api.github.com/users/timw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timw/subscriptions","organizations_url":"https://api.github.com/users/timw/orgs","repos_url":"https://api.github.com/users/timw/repos","events_url":"https://api.github.com/users/timw/events{/privacy}","received_events_url":"https://api.github.com/users/timw/received_events","type":"User","site_admin":false},"body":"Implementation of raw and OpenBSD/crypt style bcrypt password hash functions.\r\n\r\nRaw and OpenBSD style are separated.\r\nThe OpenBSD/crypt style is most useful for compatibility with existing uses or clients wanting a simple hash+params encoding.\r\nThe raw style could be plugged into a future password hash API quite easily (i.e. based on the PHC API).\r\n\r\nTo reuse the existing Blowfish implementation (having an unverified copy is the cause of at least one major bug in crypt_blowfish) BlowfishEngine is extended slightly with hooks to allow the key schedule to be overridden and for salt to be mixed in during table processing in key setup. Performance impact should be negligible given the existing cost of the Blowfish key setup.\r\n\r\nIn the OpenBSD implementation the 2 (original), 2a, 2b and 2y formats are supported (a/b/y are algorithmically equivalent, but represent bug fixes in various crypt implementations). The crypt_blowfish 2x and 'safe 2a' modes are not implemented since they require borking the BlowfishEngine (where the bug was identified).\r\n\r\nCross tested with JBCrypt and OpenWall crypt_blowfish test vectors (links in unit tests).\r\n\r\nAlso added checking for defined key sizes in BlowfishEngine, with a constructor/factory for uses needing unrestricted key lengths (bcrypt being one of them). That's in a separate commit, so feel free to drop/amend.","created_at":"2014-07-02T20:57:59Z","updated_at":"2015-02-02T04:48:43Z","closed_at":"2015-02-02T04:48:43Z","merged_at":null,"merge_commit_sha":"96fd10003082df992f374eff173a51be85ac5fcb","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/bcgit/bc-java/pulls/76/commits","review_comments_url":"https://api.github.com/repos/bcgit/bc-java/pulls/76/comments","review_comment_url":"https://api.github.com/repos/bcgit/bc-java/pulls/comments/{number}","comments_url":"https://api.github.com/repos/bcgit/bc-java/issues/76/comments","statuses_url":"https://api.github.com/repos/bcgit/bc-java/statuses/30ed3e1d8f32516400ea758ebe2a386b62bb1463","head":{"label":"timw:feature/bcrypt","ref":"feature/bcrypt","sha":"30ed3e1d8f32516400ea758ebe2a386b62bb1463","user":{"login":"timw","id":670828,"avatar_url":"https://avatars.githubusercontent.com/u/670828?v=3","gravatar_id":"","url":"https://api.github.com/users/timw","html_url":"https://github.com/timw","followers_url":"https://api.github.com/users/timw/followers","following_url":"https://api.github.com/users/timw/following{/other_user}","gists_url":"https://api.github.com/users/timw/gists{/gist_id}","starred_url":"https://api.github.com/users/timw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timw/subscriptions","organizations_url":"https://api.github.com/users/timw/orgs","repos_url":"https://api.github.com/users/timw/repos","events_url":"https://api.github.com/users/timw/events{/privacy}","received_events_url":"https://api.github.com/users/timw/received_events","type":"User","site_admin":false},"repo":{"id":11146988,"name":"bc-java","full_name":"timw/bc-java","owner":{"login":"timw","id":670828,"avatar_url":"https://avatars.githubusercontent.com/u/670828?v=3","gravatar_id":"","url":"https://api.github.com/users/timw","html_url":"https://github.com/timw","followers_url":"https://api.github.com/users/timw/followers","following_url":"https://api.github.com/users/timw/following{/other_user}","gists_url":"https://api.github.com/users/timw/gists{/gist_id}","starred_url":"https://api.github.com/users/timw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timw/subscriptions","organizations_url":"https://api.github.com/users/timw/orgs","repos_url":"https://api.github.com/users/timw/repos","events_url":"https://api.github.com/users/timw/events{/privacy}","received_events_url":"https://api.github.com/users/timw/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/timw/bc-java","description":"Bouncy Castle Java Distribution (Mirror)","fork":true,"url":"https://api.github.com/repos/timw/bc-java","forks_url":"https://api.github.com/repos/timw/bc-java/forks","keys_url":"https://api.github.com/repos/timw/bc-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/timw/bc-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/timw/bc-java/teams","hooks_url":"https://api.github.com/repos/timw/bc-java/hooks","issue_events_url":"https://api.github.com/repos/timw/bc-java/issues/events{/number}","events_url":"https://api.github.com/repos/timw/bc-java/events","assignees_url":"https://api.github.com/repos/timw/bc-java/assignees{/user}","branches_url":"https://api.github.com/repos/timw/bc-java/branches{/branch}","tags_url":"https://api.github.com/repos/timw/bc-java/tags","blobs_url":"https://api.github.com/repos/timw/bc-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/timw/bc-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/timw/bc-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/timw/bc-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/timw/bc-java/statuses/{sha}","languages_url":"https://api.github.com/repos/timw/bc-java/languages","stargazers_url":"https://api.github.com/repos/timw/bc-java/stargazers","contributors_url":"https://api.github.com/repos/timw/bc-java/contributors","subscribers_url":"https://api.github.com/repos/timw/bc-java/subscribers","subscription_url":"https://api.github.com/repos/timw/bc-java/subscription","commits_url":"https://api.github.com/repos/timw/bc-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/timw/bc-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/timw/bc-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/timw/bc-java/issues/comments/{number}","contents_url":"https://api.github.com/repos/timw/bc-java/contents/{+path}","compare_url":"https://api.github.com/repos/timw/bc-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/timw/bc-java/merges","archive_url":"https://api.github.com/repos/timw/bc-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/timw/bc-java/downloads","issues_url":"https://api.github.com/repos/timw/bc-java/issues{/number}","pulls_url":"https://api.github.com/repos/timw/bc-java/pulls{/number}","milestones_url":"https://api.github.com/repos/timw/bc-java/milestones{/number}","notifications_url":"https://api.github.com/repos/timw/bc-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/timw/bc-java/labels{/name}","releases_url":"https://api.github.com/repos/timw/bc-java/releases{/id}","created_at":"2013-07-03T09:42:59Z","updated_at":"2015-01-05T02:56:33Z","pushed_at":"2015-01-05T02:56:33Z","git_url":"git://github.com/timw/bc-java.git","ssh_url":"git@github.com:timw/bc-java.git","clone_url":"https://github.com/timw/bc-java.git","svn_url":"https://github.com/timw/bc-java","homepage":null,"size":20232,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":0,"forks":2,"open_issues":0,"watchers":0,"default_branch":"status"}},"base":{"label":"bcgit:master","ref":"master","sha":"ebe240ce7fbe01542216ea7d3bcddb5555cfb29c","user":{"login":"bcgit","id":4566970,"avatar_url":"https://avatars.githubusercontent.com/u/4566970?v=3","gravatar_id":"","url":"https://api.github.com/users/bcgit","html_url":"https://github.com/bcgit","followers_url":"https://api.github.com/users/bcgit/followers","following_url":"https://api.github.com/users/bcgit/following{/other_user}","gists_url":"https://api.github.com/users/bcgit/gists{/gist_id}","starred_url":"https://api.github.com/users/bcgit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bcgit/subscriptions","organizations_url":"https://api.github.com/users/bcgit/orgs","repos_url":"https://api.github.com/users/bcgit/repos","events_url":"https://api.github.com/users/bcgit/events{/privacy}","received_events_url":"https://api.github.com/users/bcgit/received_events","type":"User","site_admin":false},"repo":{"id":10416648,"name":"bc-java","full_name":"bcgit/bc-java","owner":{"login":"bcgit","id":4566970,"avatar_url":"https://avatars.githubusercontent.com/u/4566970?v=3","gravatar_id":"","url":"https://api.github.com/users/bcgit","html_url":"https://github.com/bcgit","followers_url":"https://api.github.com/users/bcgit/followers","following_url":"https://api.github.com/users/bcgit/following{/other_user}","gists_url":"https://api.github.com/users/bcgit/gists{/gist_id}","starred_url":"https://api.github.com/users/bcgit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bcgit/subscriptions","organizations_url":"https://api.github.com/users/bcgit/orgs","repos_url":"https://api.github.com/users/bcgit/repos","events_url":"https://api.github.com/users/bcgit/events{/privacy}","received_events_url":"https://api.github.com/users/bcgit/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bcgit/bc-java","description":"Bouncy Castle Java Distribution (Mirror)","fork":false,"url":"https://api.github.com/repos/bcgit/bc-java","forks_url":"https://api.github.com/repos/bcgit/bc-java/forks","keys_url":"https://api.github.com/repos/bcgit/bc-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bcgit/bc-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bcgit/bc-java/teams","hooks_url":"https://api.github.com/repos/bcgit/bc-java/hooks","issue_events_url":"https://api.github.com/repos/bcgit/bc-java/issues/events{/number}","events_url":"https://api.github.com/repos/bcgit/bc-java/events","assignees_url":"https://api.github.com/repos/bcgit/bc-java/assignees{/user}","branches_url":"https://api.github.com/repos/bcgit/bc-java/branches{/branch}","tags_url":"https://api.github.com/repos/bcgit/bc-java/tags","blobs_url":"https://api.github.com/repos/bcgit/bc-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bcgit/bc-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bcgit/bc-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/bcgit/bc-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bcgit/bc-java/statuses/{sha}","languages_url":"https://api.github.com/repos/bcgit/bc-java/languages","stargazers_url":"https://api.github.com/repos/bcgit/bc-java/stargazers","contributors_url":"https://api.github.com/repos/bcgit/bc-java/contributors","subscribers_url":"https://api.github.com/repos/bcgit/bc-java/subscribers","subscription_url":"https://api.github.com/repos/bcgit/bc-java/subscription","commits_url":"https://api.github.com/repos/bcgit/bc-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/bcgit/bc-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/bcgit/bc-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/bcgit/bc-java/issues/comments/{number}","contents_url":"https://api.github.com/repos/bcgit/bc-java/contents/{+path}","compare_url":"https://api.github.com/repos/bcgit/bc-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bcgit/bc-java/merges","archive_url":"https://api.github.com/repos/bcgit/bc-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bcgit/bc-java/downloads","issues_url":"https://api.github.com/repos/bcgit/bc-java/issues{/number}","pulls_url":"https://api.github.com/repos/bcgit/bc-java/pulls{/number}","milestones_url":"https://api.github.com/repos/bcgit/bc-java/milestones{/number}","notifications_url":"https://api.github.com/repos/bcgit/bc-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bcgit/bc-java/labels{/name}","releases_url":"https://api.github.com/repos/bcgit/bc-java/releases{/id}","created_at":"2013-06-01T02:38:42Z","updated_at":"2015-01-30T02:10:50Z","pushed_at":"2015-01-30T02:10:50Z","git_url":"git://github.com/bcgit/bc-java.git","ssh_url":"git@github.com:bcgit/bc-java.git","clone_url":"https://github.com/bcgit/bc-java.git","svn_url":"https://github.com/bcgit/bc-java","homepage":"http://www.bouncycastle.org/java.html","size":24148,"stargazers_count":136,"watchers_count":136,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":120,"mirror_url":"http://git.bouncycastle.org/repositories/bc-java","open_issues_count":12,"forks":120,"open_issues":12,"watchers":136,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bcgit/bc-java/pulls/76"},"html":{"href":"https://github.com/bcgit/bc-java/pull/76"},"issue":{"href":"https://api.github.com/repos/bcgit/bc-java/issues/76"},"comments":{"href":"https://api.github.com/repos/bcgit/bc-java/issues/76/comments"},"review_comments":{"href":"https://api.github.com/repos/bcgit/bc-java/pulls/76/comments"},"review_comment":{"href":"https://api.github.com/repos/bcgit/bc-java/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/bcgit/bc-java/pulls/76/commits"},"statuses":{"href":"https://api.github.com/repos/bcgit/bc-java/statuses/30ed3e1d8f32516400ea758ebe2a386b62bb1463"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":1,"review_comments":0,"commits":3,"additions":1240,"deletions":45,"changed_files":7}}