{"action":"created","comment":{"url":"https://api.github.com/repos/zcash/zcash/pulls/comments/59966851","id":59966851,"diff_hunk":"@@ -0,0 +1,24 @@\n+/*\n+Zcash uses SHA256Compress as a PRF for various components\n+within the zkSNARK circuit.\n+*/\n+\n+#ifndef _PRF_H_\n+#define _PRF_H_\n+\n+#include \"uint256.h\"\n+\n+uint256 PRF(bool a, bool b, bool c, bool d,\n+            uint256 x,\n+            uint256 y);\n+\n+template<unsigned char T>\n+uint256 PRF_addr(uint256 a_sk)\n+{\n+    uint256 y;\n+    *(y.begin()) = T;","path":"src/zcash/prf.h","position":null,"original_position":19,"commit_id":"2c901389d502e85a15349b46b77538999f17031a","original_commit_id":"77875ba45b73e160a4b3870207ed14993639f658","user":{"login":"daira","id":643204,"avatar_url":"https://avatars.githubusercontent.com/u/643204?v=3","gravatar_id":"","url":"https://api.github.com/users/daira","html_url":"https://github.com/daira","followers_url":"https://api.github.com/users/daira/followers","following_url":"https://api.github.com/users/daira/following{/other_user}","gists_url":"https://api.github.com/users/daira/gists{/gist_id}","starred_url":"https://api.github.com/users/daira/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/daira/subscriptions","organizations_url":"https://api.github.com/users/daira/orgs","repos_url":"https://api.github.com/users/daira/repos","events_url":"https://api.github.com/users/daira/events{/privacy}","received_events_url":"https://api.github.com/users/daira/received_events","type":"User","site_admin":false},"body":"This is byte-order-dependent. ``uint256 y = uint256(T);`` would be byte-order-independent. (I think that's correct.)","created_at":"2016-04-16T12:20:39Z","updated_at":"2016-04-16T12:20:39Z","html_url":"https://github.com/zcash/zcash/pull/827#discussion_r59966851","pull_request_url":"https://api.github.com/repos/zcash/zcash/pulls/827","_links":{"self":{"href":"https://api.github.com/repos/zcash/zcash/pulls/comments/59966851"},"html":{"href":"https://github.com/zcash/zcash/pull/827#discussion_r59966851"},"pull_request":{"href":"https://api.github.com/repos/zcash/zcash/pulls/827"}}},"pull_request":{"url":"https://api.github.com/repos/zcash/zcash/pulls/827","id":65193039,"html_url":"https://github.com/zcash/zcash/pull/827","diff_url":"https://github.com/zcash/zcash/pull/827.diff","patch_url":"https://github.com/zcash/zcash/pull/827.patch","issue_url":"https://api.github.com/repos/zcash/zcash/issues/827","number":827,"state":"open","locked":false,"title":"Implementation and integration of ECIES replacement \"NoteEncryption\"","user":{"login":"ebfull","id":3794471,"avatar_url":"https://avatars.githubusercontent.com/u/3794471?v=3","gravatar_id":"","url":"https://api.github.com/users/ebfull","html_url":"https://github.com/ebfull","followers_url":"https://api.github.com/users/ebfull/followers","following_url":"https://api.github.com/users/ebfull/following{/other_user}","gists_url":"https://api.github.com/users/ebfull/gists{/gist_id}","starred_url":"https://api.github.com/users/ebfull/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebfull/subscriptions","organizations_url":"https://api.github.com/users/ebfull/orgs","repos_url":"https://api.github.com/users/ebfull/repos","events_url":"https://api.github.com/users/ebfull/events{/privacy}","received_events_url":"https://api.github.com/users/ebfull/received_events","type":"User","site_admin":false},"body":"Implements `NoteEncryption`, a key-private, IND-CCA2-secure encryption scheme used for privately transferring trapdoors, memos and other information to recipients in the system. Integrates `NoteEncryption` into the codebase, and removes ECIES and crypto++, which we used for this purpose before. This PR avoids any unrelated changes.\r\n\r\n**This breaks compatibility with the testnet because the structure of `CPourTx` is changed as a result.**\r\n\r\ncloses #558, closes #485, closes #515, closes #449\r\n\r\nsupersedes #804","created_at":"2016-04-04T18:44:09Z","updated_at":"2016-04-16T12:20:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"467141a5015ab89943b4e331a7a7df8852683717","assignee":{"login":"ebfull","id":3794471,"avatar_url":"https://avatars.githubusercontent.com/u/3794471?v=3","gravatar_id":"","url":"https://api.github.com/users/ebfull","html_url":"https://github.com/ebfull","followers_url":"https://api.github.com/users/ebfull/followers","following_url":"https://api.github.com/users/ebfull/following{/other_user}","gists_url":"https://api.github.com/users/ebfull/gists{/gist_id}","starred_url":"https://api.github.com/users/ebfull/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebfull/subscriptions","organizations_url":"https://api.github.com/users/ebfull/orgs","repos_url":"https://api.github.com/users/ebfull/repos","events_url":"https://api.github.com/users/ebfull/events{/privacy}","received_events_url":"https://api.github.com/users/ebfull/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/zcash/zcash/milestones/32","html_url":"https://github.com/zcash/zcash/milestones/Protocol%202.0%20Implementation","labels_url":"https://api.github.com/repos/zcash/zcash/milestones/32/labels","id":1687731,"number":32,"title":"Protocol 2.0 Implementation","description":"","creator":{"login":"nathan-at-least","id":4369700,"avatar_url":"https://avatars.githubusercontent.com/u/4369700?v=3","gravatar_id":"","url":"https://api.github.com/users/nathan-at-least","html_url":"https://github.com/nathan-at-least","followers_url":"https://api.github.com/users/nathan-at-least/followers","following_url":"https://api.github.com/users/nathan-at-least/following{/other_user}","gists_url":"https://api.github.com/users/nathan-at-least/gists{/gist_id}","starred_url":"https://api.github.com/users/nathan-at-least/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nathan-at-least/subscriptions","organizations_url":"https://api.github.com/users/nathan-at-least/orgs","repos_url":"https://api.github.com/users/nathan-at-least/repos","events_url":"https://api.github.com/users/nathan-at-least/events{/privacy}","received_events_url":"https://api.github.com/users/nathan-at-least/received_events","type":"User","site_admin":false},"open_issues":11,"closed_issues":0,"state":"open","created_at":"2016-04-06T16:28:28Z","updated_at":"2016-04-13T22:59:13Z","due_on":"2016-05-09T07:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/zcash/zcash/pulls/827/commits","review_comments_url":"https://api.github.com/repos/zcash/zcash/pulls/827/comments","review_comment_url":"https://api.github.com/repos/zcash/zcash/pulls/comments{/number}","comments_url":"https://api.github.com/repos/zcash/zcash/issues/827/comments","statuses_url":"https://api.github.com/repos/zcash/zcash/statuses/2c901389d502e85a15349b46b77538999f17031a","head":{"label":"ebfull:noteencryption-impl","ref":"noteencryption-impl","sha":"2c901389d502e85a15349b46b77538999f17031a","user":{"login":"ebfull","id":3794471,"avatar_url":"https://avatars.githubusercontent.com/u/3794471?v=3","gravatar_id":"","url":"https://api.github.com/users/ebfull","html_url":"https://github.com/ebfull","followers_url":"https://api.github.com/users/ebfull/followers","following_url":"https://api.github.com/users/ebfull/following{/other_user}","gists_url":"https://api.github.com/users/ebfull/gists{/gist_id}","starred_url":"https://api.github.com/users/ebfull/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebfull/subscriptions","organizations_url":"https://api.github.com/users/ebfull/orgs","repos_url":"https://api.github.com/users/ebfull/repos","events_url":"https://api.github.com/users/ebfull/events{/privacy}","received_events_url":"https://api.github.com/users/ebfull/received_events","type":"User","site_admin":false},"repo":{"id":52047666,"name":"zcash","full_name":"ebfull/zcash","owner":{"login":"ebfull","id":3794471,"avatar_url":"https://avatars.githubusercontent.com/u/3794471?v=3","gravatar_id":"","url":"https://api.github.com/users/ebfull","html_url":"https://github.com/ebfull","followers_url":"https://api.github.com/users/ebfull/followers","following_url":"https://api.github.com/users/ebfull/following{/other_user}","gists_url":"https://api.github.com/users/ebfull/gists{/gist_id}","starred_url":"https://api.github.com/users/ebfull/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebfull/subscriptions","organizations_url":"https://api.github.com/users/ebfull/orgs","repos_url":"https://api.github.com/users/ebfull/repos","events_url":"https://api.github.com/users/ebfull/events{/privacy}","received_events_url":"https://api.github.com/users/ebfull/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ebfull/zcash","description":"zcash","fork":true,"url":"https://api.github.com/repos/ebfull/zcash","forks_url":"https://api.github.com/repos/ebfull/zcash/forks","keys_url":"https://api.github.com/repos/ebfull/zcash/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ebfull/zcash/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ebfull/zcash/teams","hooks_url":"https://api.github.com/repos/ebfull/zcash/hooks","issue_events_url":"https://api.github.com/repos/ebfull/zcash/issues/events{/number}","events_url":"https://api.github.com/repos/ebfull/zcash/events","assignees_url":"https://api.github.com/repos/ebfull/zcash/assignees{/user}","branches_url":"https://api.github.com/repos/ebfull/zcash/branches{/branch}","tags_url":"https://api.github.com/repos/ebfull/zcash/tags","blobs_url":"https://api.github.com/repos/ebfull/zcash/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ebfull/zcash/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ebfull/zcash/git/refs{/sha}","trees_url":"https://api.github.com/repos/ebfull/zcash/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ebfull/zcash/statuses/{sha}","languages_url":"https://api.github.com/repos/ebfull/zcash/languages","stargazers_url":"https://api.github.com/repos/ebfull/zcash/stargazers","contributors_url":"https://api.github.com/repos/ebfull/zcash/contributors","subscribers_url":"https://api.github.com/repos/ebfull/zcash/subscribers","subscription_url":"https://api.github.com/repos/ebfull/zcash/subscription","commits_url":"https://api.github.com/repos/ebfull/zcash/commits{/sha}","git_commits_url":"https://api.github.com/repos/ebfull/zcash/git/commits{/sha}","comments_url":"https://api.github.com/repos/ebfull/zcash/comments{/number}","issue_comment_url":"https://api.github.com/repos/ebfull/zcash/issues/comments{/number}","contents_url":"https://api.github.com/repos/ebfull/zcash/contents/{+path}","compare_url":"https://api.github.com/repos/ebfull/zcash/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ebfull/zcash/merges","archive_url":"https://api.github.com/repos/ebfull/zcash/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ebfull/zcash/downloads","issues_url":"https://api.github.com/repos/ebfull/zcash/issues{/number}","pulls_url":"https://api.github.com/repos/ebfull/zcash/pulls{/number}","milestones_url":"https://api.github.com/repos/ebfull/zcash/milestones{/number}","notifications_url":"https://api.github.com/repos/ebfull/zcash/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ebfull/zcash/labels{/name}","releases_url":"https://api.github.com/repos/ebfull/zcash/releases{/id}","deployments_url":"https://api.github.com/repos/ebfull/zcash/deployments","created_at":"2016-02-18T23:50:56Z","updated_at":"2016-02-18T23:50:59Z","pushed_at":"2016-04-16T10:47:57Z","git_url":"git://github.com/ebfull/zcash.git","ssh_url":"git@github.com:ebfull/zcash.git","clone_url":"https://github.com/ebfull/zcash.git","svn_url":"https://github.com/ebfull/zcash","homepage":"https://z.cash/","size":36423,"stargazers_count":0,"watchers_count":0,"language":"C++","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":"zc.v0.11.2.latest"}},"base":{"label":"zcash:zc.v0.11.2.latest","ref":"zc.v0.11.2.latest","sha":"94f0dcddb4d200d95bafa106047d9020cfc79fd7","user":{"login":"zcash","id":16122764,"avatar_url":"https://avatars.githubusercontent.com/u/16122764?v=3","gravatar_id":"","url":"https://api.github.com/users/zcash","html_url":"https://github.com/zcash","followers_url":"https://api.github.com/users/zcash/followers","following_url":"https://api.github.com/users/zcash/following{/other_user}","gists_url":"https://api.github.com/users/zcash/gists{/gist_id}","starred_url":"https://api.github.com/users/zcash/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zcash/subscriptions","organizations_url":"https://api.github.com/users/zcash/orgs","repos_url":"https://api.github.com/users/zcash/repos","events_url":"https://api.github.com/users/zcash/events{/privacy}","received_events_url":"https://api.github.com/users/zcash/received_events","type":"Organization","site_admin":false},"repo":{"id":26987049,"name":"zcash","full_name":"zcash/zcash","owner":{"login":"zcash","id":16122764,"avatar_url":"https://avatars.githubusercontent.com/u/16122764?v=3","gravatar_id":"","url":"https://api.github.com/users/zcash","html_url":"https://github.com/zcash","followers_url":"https://api.github.com/users/zcash/followers","following_url":"https://api.github.com/users/zcash/following{/other_user}","gists_url":"https://api.github.com/users/zcash/gists{/gist_id}","starred_url":"https://api.github.com/users/zcash/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zcash/subscriptions","organizations_url":"https://api.github.com/users/zcash/orgs","repos_url":"https://api.github.com/users/zcash/repos","events_url":"https://api.github.com/users/zcash/events{/privacy}","received_events_url":"https://api.github.com/users/zcash/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/zcash/zcash","description":"zcash","fork":false,"url":"https://api.github.com/repos/zcash/zcash","forks_url":"https://api.github.com/repos/zcash/zcash/forks","keys_url":"https://api.github.com/repos/zcash/zcash/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zcash/zcash/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zcash/zcash/teams","hooks_url":"https://api.github.com/repos/zcash/zcash/hooks","issue_events_url":"https://api.github.com/repos/zcash/zcash/issues/events{/number}","events_url":"https://api.github.com/repos/zcash/zcash/events","assignees_url":"https://api.github.com/repos/zcash/zcash/assignees{/user}","branches_url":"https://api.github.com/repos/zcash/zcash/branches{/branch}","tags_url":"https://api.github.com/repos/zcash/zcash/tags","blobs_url":"https://api.github.com/repos/zcash/zcash/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zcash/zcash/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zcash/zcash/git/refs{/sha}","trees_url":"https://api.github.com/repos/zcash/zcash/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zcash/zcash/statuses/{sha}","languages_url":"https://api.github.com/repos/zcash/zcash/languages","stargazers_url":"https://api.github.com/repos/zcash/zcash/stargazers","contributors_url":"https://api.github.com/repos/zcash/zcash/contributors","subscribers_url":"https://api.github.com/repos/zcash/zcash/subscribers","subscription_url":"https://api.github.com/repos/zcash/zcash/subscription","commits_url":"https://api.github.com/repos/zcash/zcash/commits{/sha}","git_commits_url":"https://api.github.com/repos/zcash/zcash/git/commits{/sha}","comments_url":"https://api.github.com/repos/zcash/zcash/comments{/number}","issue_comment_url":"https://api.github.com/repos/zcash/zcash/issues/comments{/number}","contents_url":"https://api.github.com/repos/zcash/zcash/contents/{+path}","compare_url":"https://api.github.com/repos/zcash/zcash/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zcash/zcash/merges","archive_url":"https://api.github.com/repos/zcash/zcash/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zcash/zcash/downloads","issues_url":"https://api.github.com/repos/zcash/zcash/issues{/number}","pulls_url":"https://api.github.com/repos/zcash/zcash/pulls{/number}","milestones_url":"https://api.github.com/repos/zcash/zcash/milestones{/number}","notifications_url":"https://api.github.com/repos/zcash/zcash/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zcash/zcash/labels{/name}","releases_url":"https://api.github.com/repos/zcash/zcash/releases{/id}","deployments_url":"https://api.github.com/repos/zcash/zcash/deployments","created_at":"2014-11-22T03:13:10Z","updated_at":"2016-04-15T11:47:11Z","pushed_at":"2016-04-15T23:26:06Z","git_url":"git://github.com/zcash/zcash.git","ssh_url":"git@github.com:zcash/zcash.git","clone_url":"https://github.com/zcash/zcash.git","svn_url":"https://github.com/zcash/zcash","homepage":"https://z.cash/","size":41237,"stargazers_count":677,"watchers_count":677,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":67,"mirror_url":null,"open_issues_count":307,"forks":67,"open_issues":307,"watchers":677,"default_branch":"zc.v0.11.2.z2"}},"_links":{"self":{"href":"https://api.github.com/repos/zcash/zcash/pulls/827"},"html":{"href":"https://github.com/zcash/zcash/pull/827"},"issue":{"href":"https://api.github.com/repos/zcash/zcash/issues/827"},"comments":{"href":"https://api.github.com/repos/zcash/zcash/issues/827/comments"},"review_comments":{"href":"https://api.github.com/repos/zcash/zcash/pulls/827/comments"},"review_comment":{"href":"https://api.github.com/repos/zcash/zcash/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/zcash/zcash/pulls/827/commits"},"statuses":{"href":"https://api.github.com/repos/zcash/zcash/statuses/2c901389d502e85a15349b46b77538999f17031a"}}}}