{"action":"created","comment":{"url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/comments/89677330","pull_request_review_id":10220096,"id":89677330,"diff_hunk":"@@ -420,6 +423,37 @@ def check_tool_present(*args):\n   _tool_present_cache[args] = result\n   return result\n \n+# read PDF's directory to determine if we need to decrypt it\n+def check_pdf_decryption(pdf_path):\n+  try:\n+    doc = pdfrw.PdfReader(pdf_path)\n+    return \"/Encrypt\" in doc","path":"inspectors/utils/utils.py","position":21,"original_position":21,"commit_id":"7dfaa6b928a9b965d5693b349f097ee64d1fa128","original_commit_id":"7dfaa6b928a9b965d5693b349f097ee64d1fa128","user":{"login":"konklone","id":4592,"avatar_url":"https://avatars.githubusercontent.com/u/4592?v=3","gravatar_id":"","url":"https://api.github.com/users/konklone","html_url":"https://github.com/konklone","followers_url":"https://api.github.com/users/konklone/followers","following_url":"https://api.github.com/users/konklone/following{/other_user}","gists_url":"https://api.github.com/users/konklone/gists{/gist_id}","starred_url":"https://api.github.com/users/konklone/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/konklone/subscriptions","organizations_url":"https://api.github.com/users/konklone/orgs","repos_url":"https://api.github.com/users/konklone/repos","events_url":"https://api.github.com/users/konklone/events{/privacy}","received_events_url":"https://api.github.com/users/konklone/received_events","type":"User","site_admin":false},"body":"Where does `/Encrypt` come into play?","created_at":"2016-11-26T20:14:45Z","updated_at":"2016-11-26T20:14:45Z","html_url":"https://github.com/unitedstates/inspectors-general/pull/296#discussion_r89677330","pull_request_url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296","_links":{"self":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/comments/89677330"},"html":{"href":"https://github.com/unitedstates/inspectors-general/pull/296#discussion_r89677330"},"pull_request":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296"}}},"pull_request":{"url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296","id":95380178,"html_url":"https://github.com/unitedstates/inspectors-general/pull/296","diff_url":"https://github.com/unitedstates/inspectors-general/pull/296.diff","patch_url":"https://github.com/unitedstates/inspectors-general/pull/296.patch","issue_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues/296","number":296,"state":"open","locked":false,"title":"Decrypt PDFs with an owner password","user":{"login":"divergentdave","id":181772,"avatar_url":"https://avatars.githubusercontent.com/u/181772?v=3","gravatar_id":"","url":"https://api.github.com/users/divergentdave","html_url":"https://github.com/divergentdave","followers_url":"https://api.github.com/users/divergentdave/followers","following_url":"https://api.github.com/users/divergentdave/following{/other_user}","gists_url":"https://api.github.com/users/divergentdave/gists{/gist_id}","starred_url":"https://api.github.com/users/divergentdave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/divergentdave/subscriptions","organizations_url":"https://api.github.com/users/divergentdave/orgs","repos_url":"https://api.github.com/users/divergentdave/repos","events_url":"https://api.github.com/users/divergentdave/events{/privacy}","received_events_url":"https://api.github.com/users/divergentdave/received_events","type":"User","site_admin":false},"body":"This allows us to extract text and metadata from many Smithsonian OIG reports. Closes #283.","created_at":"2016-11-26T19:15:35Z","updated_at":"2016-11-26T20:14:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8ce558fc78d6bc15153b7e39785a64dcd5a9271b","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296/commits","review_comments_url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296/comments","review_comment_url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/comments{/number}","comments_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues/296/comments","statuses_url":"https://api.github.com/repos/unitedstates/inspectors-general/statuses/7dfaa6b928a9b965d5693b349f097ee64d1fa128","head":{"label":"unitedstates:passwords","ref":"passwords","sha":"7dfaa6b928a9b965d5693b349f097ee64d1fa128","user":{"login":"unitedstates","id":2200203,"avatar_url":"https://avatars.githubusercontent.com/u/2200203?v=3","gravatar_id":"","url":"https://api.github.com/users/unitedstates","html_url":"https://github.com/unitedstates","followers_url":"https://api.github.com/users/unitedstates/followers","following_url":"https://api.github.com/users/unitedstates/following{/other_user}","gists_url":"https://api.github.com/users/unitedstates/gists{/gist_id}","starred_url":"https://api.github.com/users/unitedstates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unitedstates/subscriptions","organizations_url":"https://api.github.com/users/unitedstates/orgs","repos_url":"https://api.github.com/users/unitedstates/repos","events_url":"https://api.github.com/users/unitedstates/events{/privacy}","received_events_url":"https://api.github.com/users/unitedstates/received_events","type":"Organization","site_admin":false},"repo":{"id":13230665,"name":"inspectors-general","full_name":"unitedstates/inspectors-general","owner":{"login":"unitedstates","id":2200203,"avatar_url":"https://avatars.githubusercontent.com/u/2200203?v=3","gravatar_id":"","url":"https://api.github.com/users/unitedstates","html_url":"https://github.com/unitedstates","followers_url":"https://api.github.com/users/unitedstates/followers","following_url":"https://api.github.com/users/unitedstates/following{/other_user}","gists_url":"https://api.github.com/users/unitedstates/gists{/gist_id}","starred_url":"https://api.github.com/users/unitedstates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unitedstates/subscriptions","organizations_url":"https://api.github.com/users/unitedstates/orgs","repos_url":"https://api.github.com/users/unitedstates/repos","events_url":"https://api.github.com/users/unitedstates/events{/privacy}","received_events_url":"https://api.github.com/users/unitedstates/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/unitedstates/inspectors-general","description":"Collecting reports from Inspectors General across the US federal government.","fork":false,"url":"https://api.github.com/repos/unitedstates/inspectors-general","forks_url":"https://api.github.com/repos/unitedstates/inspectors-general/forks","keys_url":"https://api.github.com/repos/unitedstates/inspectors-general/keys{/key_id}","collaborators_url":"https://api.github.com/repos/unitedstates/inspectors-general/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/unitedstates/inspectors-general/teams","hooks_url":"https://api.github.com/repos/unitedstates/inspectors-general/hooks","issue_events_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues/events{/number}","events_url":"https://api.github.com/repos/unitedstates/inspectors-general/events","assignees_url":"https://api.github.com/repos/unitedstates/inspectors-general/assignees{/user}","branches_url":"https://api.github.com/repos/unitedstates/inspectors-general/branches{/branch}","tags_url":"https://api.github.com/repos/unitedstates/inspectors-general/tags","blobs_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/refs{/sha}","trees_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/trees{/sha}","statuses_url":"https://api.github.com/repos/unitedstates/inspectors-general/statuses/{sha}","languages_url":"https://api.github.com/repos/unitedstates/inspectors-general/languages","stargazers_url":"https://api.github.com/repos/unitedstates/inspectors-general/stargazers","contributors_url":"https://api.github.com/repos/unitedstates/inspectors-general/contributors","subscribers_url":"https://api.github.com/repos/unitedstates/inspectors-general/subscribers","subscription_url":"https://api.github.com/repos/unitedstates/inspectors-general/subscription","commits_url":"https://api.github.com/repos/unitedstates/inspectors-general/commits{/sha}","git_commits_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/commits{/sha}","comments_url":"https://api.github.com/repos/unitedstates/inspectors-general/comments{/number}","issue_comment_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues/comments{/number}","contents_url":"https://api.github.com/repos/unitedstates/inspectors-general/contents/{+path}","compare_url":"https://api.github.com/repos/unitedstates/inspectors-general/compare/{base}...{head}","merges_url":"https://api.github.com/repos/unitedstates/inspectors-general/merges","archive_url":"https://api.github.com/repos/unitedstates/inspectors-general/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/unitedstates/inspectors-general/downloads","issues_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues{/number}","pulls_url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls{/number}","milestones_url":"https://api.github.com/repos/unitedstates/inspectors-general/milestones{/number}","notifications_url":"https://api.github.com/repos/unitedstates/inspectors-general/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/unitedstates/inspectors-general/labels{/name}","releases_url":"https://api.github.com/repos/unitedstates/inspectors-general/releases{/id}","deployments_url":"https://api.github.com/repos/unitedstates/inspectors-general/deployments","created_at":"2013-09-30T23:55:47Z","updated_at":"2016-11-25T17:06:39Z","pushed_at":"2016-11-26T19:15:35Z","git_url":"git://github.com/unitedstates/inspectors-general.git","ssh_url":"git@github.com:unitedstates/inspectors-general.git","clone_url":"https://github.com/unitedstates/inspectors-general.git","svn_url":"https://github.com/unitedstates/inspectors-general","homepage":"https://sunlightfoundation.com/blog/2014/11/07/opengov-voices-opening-up-government-reports-through-teamwork-and-open-data/","size":1581,"stargazers_count":68,"watchers_count":68,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":15,"mirror_url":null,"open_issues_count":20,"forks":15,"open_issues":20,"watchers":68,"default_branch":"master"}},"base":{"label":"unitedstates:master","ref":"master","sha":"e4e04a5fa1c6a2a67599a6775fa4ed4334e21c1a","user":{"login":"unitedstates","id":2200203,"avatar_url":"https://avatars.githubusercontent.com/u/2200203?v=3","gravatar_id":"","url":"https://api.github.com/users/unitedstates","html_url":"https://github.com/unitedstates","followers_url":"https://api.github.com/users/unitedstates/followers","following_url":"https://api.github.com/users/unitedstates/following{/other_user}","gists_url":"https://api.github.com/users/unitedstates/gists{/gist_id}","starred_url":"https://api.github.com/users/unitedstates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unitedstates/subscriptions","organizations_url":"https://api.github.com/users/unitedstates/orgs","repos_url":"https://api.github.com/users/unitedstates/repos","events_url":"https://api.github.com/users/unitedstates/events{/privacy}","received_events_url":"https://api.github.com/users/unitedstates/received_events","type":"Organization","site_admin":false},"repo":{"id":13230665,"name":"inspectors-general","full_name":"unitedstates/inspectors-general","owner":{"login":"unitedstates","id":2200203,"avatar_url":"https://avatars.githubusercontent.com/u/2200203?v=3","gravatar_id":"","url":"https://api.github.com/users/unitedstates","html_url":"https://github.com/unitedstates","followers_url":"https://api.github.com/users/unitedstates/followers","following_url":"https://api.github.com/users/unitedstates/following{/other_user}","gists_url":"https://api.github.com/users/unitedstates/gists{/gist_id}","starred_url":"https://api.github.com/users/unitedstates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/unitedstates/subscriptions","organizations_url":"https://api.github.com/users/unitedstates/orgs","repos_url":"https://api.github.com/users/unitedstates/repos","events_url":"https://api.github.com/users/unitedstates/events{/privacy}","received_events_url":"https://api.github.com/users/unitedstates/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/unitedstates/inspectors-general","description":"Collecting reports from Inspectors General across the US federal government.","fork":false,"url":"https://api.github.com/repos/unitedstates/inspectors-general","forks_url":"https://api.github.com/repos/unitedstates/inspectors-general/forks","keys_url":"https://api.github.com/repos/unitedstates/inspectors-general/keys{/key_id}","collaborators_url":"https://api.github.com/repos/unitedstates/inspectors-general/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/unitedstates/inspectors-general/teams","hooks_url":"https://api.github.com/repos/unitedstates/inspectors-general/hooks","issue_events_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues/events{/number}","events_url":"https://api.github.com/repos/unitedstates/inspectors-general/events","assignees_url":"https://api.github.com/repos/unitedstates/inspectors-general/assignees{/user}","branches_url":"https://api.github.com/repos/unitedstates/inspectors-general/branches{/branch}","tags_url":"https://api.github.com/repos/unitedstates/inspectors-general/tags","blobs_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/refs{/sha}","trees_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/trees{/sha}","statuses_url":"https://api.github.com/repos/unitedstates/inspectors-general/statuses/{sha}","languages_url":"https://api.github.com/repos/unitedstates/inspectors-general/languages","stargazers_url":"https://api.github.com/repos/unitedstates/inspectors-general/stargazers","contributors_url":"https://api.github.com/repos/unitedstates/inspectors-general/contributors","subscribers_url":"https://api.github.com/repos/unitedstates/inspectors-general/subscribers","subscription_url":"https://api.github.com/repos/unitedstates/inspectors-general/subscription","commits_url":"https://api.github.com/repos/unitedstates/inspectors-general/commits{/sha}","git_commits_url":"https://api.github.com/repos/unitedstates/inspectors-general/git/commits{/sha}","comments_url":"https://api.github.com/repos/unitedstates/inspectors-general/comments{/number}","issue_comment_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues/comments{/number}","contents_url":"https://api.github.com/repos/unitedstates/inspectors-general/contents/{+path}","compare_url":"https://api.github.com/repos/unitedstates/inspectors-general/compare/{base}...{head}","merges_url":"https://api.github.com/repos/unitedstates/inspectors-general/merges","archive_url":"https://api.github.com/repos/unitedstates/inspectors-general/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/unitedstates/inspectors-general/downloads","issues_url":"https://api.github.com/repos/unitedstates/inspectors-general/issues{/number}","pulls_url":"https://api.github.com/repos/unitedstates/inspectors-general/pulls{/number}","milestones_url":"https://api.github.com/repos/unitedstates/inspectors-general/milestones{/number}","notifications_url":"https://api.github.com/repos/unitedstates/inspectors-general/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/unitedstates/inspectors-general/labels{/name}","releases_url":"https://api.github.com/repos/unitedstates/inspectors-general/releases{/id}","deployments_url":"https://api.github.com/repos/unitedstates/inspectors-general/deployments","created_at":"2013-09-30T23:55:47Z","updated_at":"2016-11-25T17:06:39Z","pushed_at":"2016-11-26T19:15:35Z","git_url":"git://github.com/unitedstates/inspectors-general.git","ssh_url":"git@github.com:unitedstates/inspectors-general.git","clone_url":"https://github.com/unitedstates/inspectors-general.git","svn_url":"https://github.com/unitedstates/inspectors-general","homepage":"https://sunlightfoundation.com/blog/2014/11/07/opengov-voices-opening-up-government-reports-through-teamwork-and-open-data/","size":1581,"stargazers_count":68,"watchers_count":68,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":15,"mirror_url":null,"open_issues_count":20,"forks":15,"open_issues":20,"watchers":68,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296"},"html":{"href":"https://github.com/unitedstates/inspectors-general/pull/296"},"issue":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/issues/296"},"comments":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/issues/296/comments"},"review_comments":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296/comments"},"review_comment":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/pulls/296/commits"},"statuses":{"href":"https://api.github.com/repos/unitedstates/inspectors-general/statuses/7dfaa6b928a9b965d5693b349f097ee64d1fa128"}}}}
{"actor":{"display_login":"konklone"}}