{"action":"created","comment":{"url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/comments/26787631","id":26787631,"diff_hunk":"@@ -187,6 +208,20 @@ VALUE sign(VALUE self, VALUE rb_opts) {\n     exception_message = \"signature failed\";\n     goto done;\n   }\n+  if (store_references) {\n+    rb_references = rb_ary_new_capa((long)xmlSecPtrListGetSize(&dsigCtx->signedInfoReferences));\n+    rb_hash_aset(rb_opts, ID2SYM(rb_intern(\"references\")), rb_references);\n+    for(xmlSecSize pos = 0; pos < xmlSecPtrListGetSize(&dsigCtx->signedInfoReferences); ++pos) {\n+      VALUE rb_reference = rb_hash_new();\n+      rb_ary_push(rb_references, rb_reference);\n+      xmlSecDSigReferenceCtxPtr dsigRefCtx = (xmlSecDSigReferenceCtxPtr)xmlSecPtrListGetItem(&dsigCtx->signedInfoReferences, pos);\n+      xmlSecBufferPtr pre_digest_buffer = xmlSecDSigReferenceCtxGetPreDigestBuffer(dsigRefCtx);\n+      if (pre_digest_buffer && xmlSecBufferGetData(pre_digest_buffer)) {\n+        VALUE rb_pre_digest_buffer = rb_str_new(xmlSecBufferGetData(pre_digest_buffer), xmlSecBufferGetSize(pre_digest_buffer));\n+        rb_hash_aset(rb_reference, ID2SYM(rb_intern(\"pre_digest_buffer\")), rb_pre_digest_buffer);","path":"ext/nokogiri_ext_xmlsec/nokogiri_sign.c","position":70,"original_position":70,"commit_id":"21f261edbbf5db42ed35c41aa3542d2eb3f663d1","original_commit_id":"21f261edbbf5db42ed35c41aa3542d2eb3f663d1","user":{"login":"awong-dev","id":144579,"avatar_url":"https://avatars.githubusercontent.com/u/144579?v=3","gravatar_id":"","url":"https://api.github.com/users/awong-dev","html_url":"https://github.com/awong-dev","followers_url":"https://api.github.com/users/awong-dev/followers","following_url":"https://api.github.com/users/awong-dev/following{/other_user}","gists_url":"https://api.github.com/users/awong-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/awong-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awong-dev/subscriptions","organizations_url":"https://api.github.com/users/awong-dev/orgs","repos_url":"https://api.github.com/users/awong-dev/repos","events_url":"https://api.github.com/users/awong-dev/events{/privacy}","received_events_url":"https://api.github.com/users/awong-dev/received_events","type":"User","site_admin":false},"body":"Move this rb_intern outside the loop?","created_at":"2015-03-19T19:11:15Z","updated_at":"2015-03-19T19:11:15Z","html_url":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder/pull/5#discussion_r26787631","pull_request_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5","_links":{"self":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/comments/26787631"},"html":{"href":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder/pull/5#discussion_r26787631"},"pull_request":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5","id":31550229,"html_url":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder/pull/5","diff_url":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder/pull/5.diff","patch_url":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder/pull/5.patch","issue_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/issues/5","number":5,"state":"open","locked":false,"title":"add an option to store the pre digest buffer for debugging","user":{"login":"ccutrer","id":191320,"avatar_url":"https://avatars.githubusercontent.com/u/191320?v=3","gravatar_id":"","url":"https://api.github.com/users/ccutrer","html_url":"https://github.com/ccutrer","followers_url":"https://api.github.com/users/ccutrer/followers","following_url":"https://api.github.com/users/ccutrer/following{/other_user}","gists_url":"https://api.github.com/users/ccutrer/gists{/gist_id}","starred_url":"https://api.github.com/users/ccutrer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ccutrer/subscriptions","organizations_url":"https://api.github.com/users/ccutrer/orgs","repos_url":"https://api.github.com/users/ccutrer/repos","events_url":"https://api.github.com/users/ccutrer/events{/privacy}","received_events_url":"https://api.github.com/users/ccutrer/received_events","type":"User","site_admin":false},"body":"matches the --store-references option to xmlsec1 utility","created_at":"2015-03-19T18:09:58Z","updated_at":"2015-03-19T19:11:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"35328b8fbd5e552e9ea75cecdfb048d3871156aa","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5/commits","review_comments_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5/comments","review_comment_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/comments{/number}","comments_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/issues/5/comments","statuses_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/statuses/21f261edbbf5db42ed35c41aa3542d2eb3f663d1","head":{"label":"instructure:store_references","ref":"store_references","sha":"21f261edbbf5db42ed35c41aa3542d2eb3f663d1","user":{"login":"instructure","id":515326,"avatar_url":"https://avatars.githubusercontent.com/u/515326?v=3","gravatar_id":"","url":"https://api.github.com/users/instructure","html_url":"https://github.com/instructure","followers_url":"https://api.github.com/users/instructure/followers","following_url":"https://api.github.com/users/instructure/following{/other_user}","gists_url":"https://api.github.com/users/instructure/gists{/gist_id}","starred_url":"https://api.github.com/users/instructure/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/instructure/subscriptions","organizations_url":"https://api.github.com/users/instructure/orgs","repos_url":"https://api.github.com/users/instructure/repos","events_url":"https://api.github.com/users/instructure/events{/privacy}","received_events_url":"https://api.github.com/users/instructure/received_events","type":"Organization","site_admin":false},"repo":{"id":30374198,"name":"nokogiri-xmlsec-me-harder","full_name":"instructure/nokogiri-xmlsec-me-harder","owner":{"login":"instructure","id":515326,"avatar_url":"https://avatars.githubusercontent.com/u/515326?v=3","gravatar_id":"","url":"https://api.github.com/users/instructure","html_url":"https://github.com/instructure","followers_url":"https://api.github.com/users/instructure/followers","following_url":"https://api.github.com/users/instructure/following{/other_user}","gists_url":"https://api.github.com/users/instructure/gists{/gist_id}","starred_url":"https://api.github.com/users/instructure/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/instructure/subscriptions","organizations_url":"https://api.github.com/users/instructure/orgs","repos_url":"https://api.github.com/users/instructure/repos","events_url":"https://api.github.com/users/instructure/events{/privacy}","received_events_url":"https://api.github.com/users/instructure/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/instructure/nokogiri-xmlsec-me-harder","description":"","fork":true,"url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder","forks_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/forks","keys_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/teams","hooks_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/hooks","issue_events_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/issues/events{/number}","events_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/events","assignees_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/assignees{/user}","branches_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/branches{/branch}","tags_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/tags","blobs_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/git/refs{/sha}","trees_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/statuses/{sha}","languages_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/languages","stargazers_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/stargazers","contributors_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/contributors","subscribers_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/subscribers","subscription_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/subscription","commits_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/commits{/sha}","git_commits_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/git/commits{/sha}","comments_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/comments{/number}","issue_comment_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/issues/comments{/number}","contents_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/contents/{+path}","compare_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/merges","archive_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/downloads","issues_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/issues{/number}","pulls_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/pulls{/number}","milestones_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/milestones{/number}","notifications_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/labels{/name}","releases_url":"https://api.github.com/repos/instructure/nokogiri-xmlsec-me-harder/releases{/id}","created_at":"2015-02-05T19:34:25Z","updated_at":"2015-02-05T19:34:25Z","pushed_at":"2015-03-19T18:09:41Z","git_url":"git://github.com/instructure/nokogiri-xmlsec-me-harder.git","ssh_url":"git@github.com:instructure/nokogiri-xmlsec-me-harder.git","clone_url":"https://github.com/instructure/nokogiri-xmlsec-me-harder.git","svn_url":"https://github.com/instructure/nokogiri-xmlsec-me-harder","homepage":null,"size":1236,"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":"dev"}},"base":{"label":"awong-dev:dev","ref":"dev","sha":"d703bf11b5a41977f8b1d8072401d529511b23b2","user":{"login":"awong-dev","id":144579,"avatar_url":"https://avatars.githubusercontent.com/u/144579?v=3","gravatar_id":"","url":"https://api.github.com/users/awong-dev","html_url":"https://github.com/awong-dev","followers_url":"https://api.github.com/users/awong-dev/followers","following_url":"https://api.github.com/users/awong-dev/following{/other_user}","gists_url":"https://api.github.com/users/awong-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/awong-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awong-dev/subscriptions","organizations_url":"https://api.github.com/users/awong-dev/orgs","repos_url":"https://api.github.com/users/awong-dev/repos","events_url":"https://api.github.com/users/awong-dev/events{/privacy}","received_events_url":"https://api.github.com/users/awong-dev/received_events","type":"User","site_admin":false},"repo":{"id":25453469,"name":"nokogiri-xmlsec-me-harder","full_name":"awong-dev/nokogiri-xmlsec-me-harder","owner":{"login":"awong-dev","id":144579,"avatar_url":"https://avatars.githubusercontent.com/u/144579?v=3","gravatar_id":"","url":"https://api.github.com/users/awong-dev","html_url":"https://github.com/awong-dev","followers_url":"https://api.github.com/users/awong-dev/followers","following_url":"https://api.github.com/users/awong-dev/following{/other_user}","gists_url":"https://api.github.com/users/awong-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/awong-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/awong-dev/subscriptions","organizations_url":"https://api.github.com/users/awong-dev/orgs","repos_url":"https://api.github.com/users/awong-dev/repos","events_url":"https://api.github.com/users/awong-dev/events{/privacy}","received_events_url":"https://api.github.com/users/awong-dev/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder","description":"","fork":true,"url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder","forks_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/forks","keys_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/teams","hooks_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/hooks","issue_events_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/issues/events{/number}","events_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/events","assignees_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/assignees{/user}","branches_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/branches{/branch}","tags_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/tags","blobs_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/git/refs{/sha}","trees_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/statuses/{sha}","languages_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/languages","stargazers_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/stargazers","contributors_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/contributors","subscribers_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/subscribers","subscription_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/subscription","commits_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/commits{/sha}","git_commits_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/git/commits{/sha}","comments_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/comments{/number}","issue_comment_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/issues/comments{/number}","contents_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/contents/{+path}","compare_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/merges","archive_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/downloads","issues_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/issues{/number}","pulls_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls{/number}","milestones_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/milestones{/number}","notifications_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/labels{/name}","releases_url":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/releases{/id}","created_at":"2014-10-20T06:22:04Z","updated_at":"2015-03-01T21:22:29Z","pushed_at":"2015-03-01T21:22:28Z","git_url":"git://github.com/awong-dev/nokogiri-xmlsec-me-harder.git","ssh_url":"git@github.com:awong-dev/nokogiri-xmlsec-me-harder.git","clone_url":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder.git","svn_url":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder","homepage":null,"size":1301,"stargazers_count":1,"watchers_count":1,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":2,"forks":4,"open_issues":2,"watchers":1,"default_branch":"dev"}},"_links":{"self":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5"},"html":{"href":"https://github.com/awong-dev/nokogiri-xmlsec-me-harder/pull/5"},"issue":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/issues/5"},"comments":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/awong-dev/nokogiri-xmlsec-me-harder/statuses/21f261edbbf5db42ed35c41aa3542d2eb3f663d1"}}}}