{"action":"created","comment":{"url":"https://api.github.com/repos/google/go-tpm/pulls/comments/238048261","pull_request_review_id":180506927,"id":238048261,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzODA0ODI2MQ==","diff_hunk":"@@ -273,3 +273,39 @@ var hashConstructors = map[Algorithm]func() hash.Hash{\n \tAlgSHA384: sha512.New384,\n \tAlgSHA512: sha512.New,\n }\n+\n+// NV attributes","path":"tpm2/constants.go","position":5,"original_position":5,"commit_id":"10327b60b7303d6ebb582ebd8a38da820c474981","original_commit_id":"10327b60b7303d6ebb582ebd8a38da820c474981","user":{"login":"folbricht","id":3505107,"node_id":"MDQ6VXNlcjM1MDUxMDc=","avatar_url":"https://avatars2.githubusercontent.com/u/3505107?v=4","gravatar_id":"","url":"https://api.github.com/users/folbricht","html_url":"https://github.com/folbricht","followers_url":"https://api.github.com/users/folbricht/followers","following_url":"https://api.github.com/users/folbricht/following{/other_user}","gists_url":"https://api.github.com/users/folbricht/gists{/gist_id}","starred_url":"https://api.github.com/users/folbricht/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/folbricht/subscriptions","organizations_url":"https://api.github.com/users/folbricht/orgs","repos_url":"https://api.github.com/users/folbricht/repos","events_url":"https://api.github.com/users/folbricht/events{/privacy}","received_events_url":"https://api.github.com/users/folbricht/received_events","type":"User","site_admin":false},"body":"I'm using those when creating the index. Like so:\r\n\r\n```go\r\n\tif err := tpm2.NVDefineSpace(rwc,\r\n\t\ttpm2.HandleOwner,\r\n\t\tidx,\r\n\t\temptyPassword,\r\n\t\temptyPassword,\r\n\t\tnil,\r\n\t\ttpm2.NVAttrOwnerWrite|tpm2.NVAttrOwnerRead|tpm2.NVAttrAuthRead|tpm2.NVAttrPPRead,\r\n\t\tuint16(len(data)),\r\n\t); err != nil {\r\n\t\tpanic(err)\r\n\t}\r\n```","created_at":"2018-12-01T02:15:46Z","updated_at":"2018-12-01T02:15:46Z","html_url":"https://github.com/google/go-tpm/pull/52#discussion_r238048261","pull_request_url":"https://api.github.com/repos/google/go-tpm/pulls/52","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/google/go-tpm/pulls/comments/238048261"},"html":{"href":"https://github.com/google/go-tpm/pull/52#discussion_r238048261"},"pull_request":{"href":"https://api.github.com/repos/google/go-tpm/pulls/52"}},"in_reply_to_id":238047331},"pull_request":{"url":"https://api.github.com/repos/google/go-tpm/pulls/52","id":234861944,"node_id":"MDExOlB1bGxSZXF1ZXN0MjM0ODYxOTQ0","html_url":"https://github.com/google/go-tpm/pull/52","diff_url":"https://github.com/google/go-tpm/pull/52.diff","patch_url":"https://github.com/google/go-tpm/pull/52.patch","issue_url":"https://api.github.com/repos/google/go-tpm/issues/52","number":52,"state":"open","locked":false,"title":"Implement NVWrite command","user":{"login":"folbricht","id":3505107,"node_id":"MDQ6VXNlcjM1MDUxMDc=","avatar_url":"https://avatars2.githubusercontent.com/u/3505107?v=4","gravatar_id":"","url":"https://api.github.com/users/folbricht","html_url":"https://github.com/folbricht","followers_url":"https://api.github.com/users/folbricht/followers","following_url":"https://api.github.com/users/folbricht/following{/other_user}","gists_url":"https://api.github.com/users/folbricht/gists{/gist_id}","starred_url":"https://api.github.com/users/folbricht/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/folbricht/subscriptions","organizations_url":"https://api.github.com/users/folbricht/orgs","repos_url":"https://api.github.com/users/folbricht/repos","events_url":"https://api.github.com/users/folbricht/events{/privacy}","received_events_url":"https://api.github.com/users/folbricht/received_events","type":"User","site_admin":false},"body":"This adds an implementation of the NVWrite command.\r\n\r\nWould like to also add a test, but can't get NVRead to work without modifications.","created_at":"2018-11-30T03:36:54Z","updated_at":"2018-12-01T02:15:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d5d9926e083ac9daa14a38204f0769f20790abbb","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/google/go-tpm/pulls/52/commits","review_comments_url":"https://api.github.com/repos/google/go-tpm/pulls/52/comments","review_comment_url":"https://api.github.com/repos/google/go-tpm/pulls/comments{/number}","comments_url":"https://api.github.com/repos/google/go-tpm/issues/52/comments","statuses_url":"https://api.github.com/repos/google/go-tpm/statuses/10327b60b7303d6ebb582ebd8a38da820c474981","head":{"label":"folbricht:nvwrite","ref":"nvwrite","sha":"10327b60b7303d6ebb582ebd8a38da820c474981","user":{"login":"folbricht","id":3505107,"node_id":"MDQ6VXNlcjM1MDUxMDc=","avatar_url":"https://avatars2.githubusercontent.com/u/3505107?v=4","gravatar_id":"","url":"https://api.github.com/users/folbricht","html_url":"https://github.com/folbricht","followers_url":"https://api.github.com/users/folbricht/followers","following_url":"https://api.github.com/users/folbricht/following{/other_user}","gists_url":"https://api.github.com/users/folbricht/gists{/gist_id}","starred_url":"https://api.github.com/users/folbricht/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/folbricht/subscriptions","organizations_url":"https://api.github.com/users/folbricht/orgs","repos_url":"https://api.github.com/users/folbricht/repos","events_url":"https://api.github.com/users/folbricht/events{/privacy}","received_events_url":"https://api.github.com/users/folbricht/received_events","type":"User","site_admin":false},"repo":{"id":159761683,"node_id":"MDEwOlJlcG9zaXRvcnkxNTk3NjE2ODM=","name":"go-tpm","full_name":"folbricht/go-tpm","private":false,"owner":{"login":"folbricht","id":3505107,"node_id":"MDQ6VXNlcjM1MDUxMDc=","avatar_url":"https://avatars2.githubusercontent.com/u/3505107?v=4","gravatar_id":"","url":"https://api.github.com/users/folbricht","html_url":"https://github.com/folbricht","followers_url":"https://api.github.com/users/folbricht/followers","following_url":"https://api.github.com/users/folbricht/following{/other_user}","gists_url":"https://api.github.com/users/folbricht/gists{/gist_id}","starred_url":"https://api.github.com/users/folbricht/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/folbricht/subscriptions","organizations_url":"https://api.github.com/users/folbricht/orgs","repos_url":"https://api.github.com/users/folbricht/repos","events_url":"https://api.github.com/users/folbricht/events{/privacy}","received_events_url":"https://api.github.com/users/folbricht/received_events","type":"User","site_admin":false},"html_url":"https://github.com/folbricht/go-tpm","description":null,"fork":true,"url":"https://api.github.com/repos/folbricht/go-tpm","forks_url":"https://api.github.com/repos/folbricht/go-tpm/forks","keys_url":"https://api.github.com/repos/folbricht/go-tpm/keys{/key_id}","collaborators_url":"https://api.github.com/repos/folbricht/go-tpm/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/folbricht/go-tpm/teams","hooks_url":"https://api.github.com/repos/folbricht/go-tpm/hooks","issue_events_url":"https://api.github.com/repos/folbricht/go-tpm/issues/events{/number}","events_url":"https://api.github.com/repos/folbricht/go-tpm/events","assignees_url":"https://api.github.com/repos/folbricht/go-tpm/assignees{/user}","branches_url":"https://api.github.com/repos/folbricht/go-tpm/branches{/branch}","tags_url":"https://api.github.com/repos/folbricht/go-tpm/tags","blobs_url":"https://api.github.com/repos/folbricht/go-tpm/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/folbricht/go-tpm/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/folbricht/go-tpm/git/refs{/sha}","trees_url":"https://api.github.com/repos/folbricht/go-tpm/git/trees{/sha}","statuses_url":"https://api.github.com/repos/folbricht/go-tpm/statuses/{sha}","languages_url":"https://api.github.com/repos/folbricht/go-tpm/languages","stargazers_url":"https://api.github.com/repos/folbricht/go-tpm/stargazers","contributors_url":"https://api.github.com/repos/folbricht/go-tpm/contributors","subscribers_url":"https://api.github.com/repos/folbricht/go-tpm/subscribers","subscription_url":"https://api.github.com/repos/folbricht/go-tpm/subscription","commits_url":"https://api.github.com/repos/folbricht/go-tpm/commits{/sha}","git_commits_url":"https://api.github.com/repos/folbricht/go-tpm/git/commits{/sha}","comments_url":"https://api.github.com/repos/folbricht/go-tpm/comments{/number}","issue_comment_url":"https://api.github.com/repos/folbricht/go-tpm/issues/comments{/number}","contents_url":"https://api.github.com/repos/folbricht/go-tpm/contents/{+path}","compare_url":"https://api.github.com/repos/folbricht/go-tpm/compare/{base}...{head}","merges_url":"https://api.github.com/repos/folbricht/go-tpm/merges","archive_url":"https://api.github.com/repos/folbricht/go-tpm/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/folbricht/go-tpm/downloads","issues_url":"https://api.github.com/repos/folbricht/go-tpm/issues{/number}","pulls_url":"https://api.github.com/repos/folbricht/go-tpm/pulls{/number}","milestones_url":"https://api.github.com/repos/folbricht/go-tpm/milestones{/number}","notifications_url":"https://api.github.com/repos/folbricht/go-tpm/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/folbricht/go-tpm/labels{/name}","releases_url":"https://api.github.com/repos/folbricht/go-tpm/releases{/id}","deployments_url":"https://api.github.com/repos/folbricht/go-tpm/deployments","created_at":"2018-11-30T03:12:39Z","updated_at":"2018-11-30T03:12:41Z","pushed_at":"2018-11-30T03:28:20Z","git_url":"git://github.com/folbricht/go-tpm.git","ssh_url":"git@github.com:folbricht/go-tpm.git","clone_url":"https://github.com/folbricht/go-tpm.git","svn_url":"https://github.com/folbricht/go-tpm","homepage":null,"size":271,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"google:master","ref":"master","sha":"03d39f2bdd2583d4a85e83ffa8f35b2d672233b1","user":{"login":"google","id":1342004,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzNDIwMDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/1342004?v=4","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":22929140,"node_id":"MDEwOlJlcG9zaXRvcnkyMjkyOTE0MA==","name":"go-tpm","full_name":"google/go-tpm","private":false,"owner":{"login":"google","id":1342004,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzNDIwMDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/1342004?v=4","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/google/go-tpm","description":null,"fork":false,"url":"https://api.github.com/repos/google/go-tpm","forks_url":"https://api.github.com/repos/google/go-tpm/forks","keys_url":"https://api.github.com/repos/google/go-tpm/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/go-tpm/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/go-tpm/teams","hooks_url":"https://api.github.com/repos/google/go-tpm/hooks","issue_events_url":"https://api.github.com/repos/google/go-tpm/issues/events{/number}","events_url":"https://api.github.com/repos/google/go-tpm/events","assignees_url":"https://api.github.com/repos/google/go-tpm/assignees{/user}","branches_url":"https://api.github.com/repos/google/go-tpm/branches{/branch}","tags_url":"https://api.github.com/repos/google/go-tpm/tags","blobs_url":"https://api.github.com/repos/google/go-tpm/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/go-tpm/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/go-tpm/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/go-tpm/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/go-tpm/statuses/{sha}","languages_url":"https://api.github.com/repos/google/go-tpm/languages","stargazers_url":"https://api.github.com/repos/google/go-tpm/stargazers","contributors_url":"https://api.github.com/repos/google/go-tpm/contributors","subscribers_url":"https://api.github.com/repos/google/go-tpm/subscribers","subscription_url":"https://api.github.com/repos/google/go-tpm/subscription","commits_url":"https://api.github.com/repos/google/go-tpm/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/go-tpm/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/go-tpm/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/go-tpm/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/go-tpm/contents/{+path}","compare_url":"https://api.github.com/repos/google/go-tpm/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/go-tpm/merges","archive_url":"https://api.github.com/repos/google/go-tpm/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/go-tpm/downloads","issues_url":"https://api.github.com/repos/google/go-tpm/issues{/number}","pulls_url":"https://api.github.com/repos/google/go-tpm/pulls{/number}","milestones_url":"https://api.github.com/repos/google/go-tpm/milestones{/number}","notifications_url":"https://api.github.com/repos/google/go-tpm/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/go-tpm/labels{/name}","releases_url":"https://api.github.com/repos/google/go-tpm/releases{/id}","deployments_url":"https://api.github.com/repos/google/go-tpm/deployments","created_at":"2014-08-13T19:53:34Z","updated_at":"2018-11-29T22:43:28Z","pushed_at":"2018-11-30T03:36:55Z","git_url":"git://github.com/google/go-tpm.git","ssh_url":"git@github.com:google/go-tpm.git","clone_url":"https://github.com/google/go-tpm.git","svn_url":"https://github.com/google/go-tpm","homepage":null,"size":258,"stargazers_count":144,"watchers_count":144,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":43,"mirror_url":null,"archived":false,"open_issues_count":3,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":43,"open_issues":3,"watchers":144,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/go-tpm/pulls/52"},"html":{"href":"https://github.com/google/go-tpm/pull/52"},"issue":{"href":"https://api.github.com/repos/google/go-tpm/issues/52"},"comments":{"href":"https://api.github.com/repos/google/go-tpm/issues/52/comments"},"review_comments":{"href":"https://api.github.com/repos/google/go-tpm/pulls/52/comments"},"review_comment":{"href":"https://api.github.com/repos/google/go-tpm/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/google/go-tpm/pulls/52/commits"},"statuses":{"href":"https://api.github.com/repos/google/go-tpm/statuses/10327b60b7303d6ebb582ebd8a38da820c474981"}},"author_association":"NONE"}}
{"actor":{"display_login":"folbricht"}}