{"action":"created","comment":{"url":"https://api.github.com/repos/pyca/cryptography/pulls/comments/33899481","id":33899481,"diff_hunk":"@@ -1578,6 +1615,30 @@ def test_invalid_rfc822name(self, backend):\n \n         assert 'Invalid rfc822name value' in str(exc.value)\n \n+    def test_other_name(self, backend):\n+        cert = _load_cert(\n+            os.path.join(\n+                \"x509\", \"custom\", \"san_other_name.pem\"\n+            ),\n+            x509.load_pem_x509_certificate,\n+            backend\n+        )\n+\n+        ext = cert.extensions.get_extension_for_oid(\n+            x509.OID_SUBJECT_ALTERNATIVE_NAME\n+        )\n+        assert ext is not None\n+        assert ext.critical is False\n+\n+        assert len(ext.value) == 1\n+        assert list(ext.value)[0] == \\\n+            x509.OtherName(\n+                x509.ObjectIdentifier(\"1.2.3.4\"),\n+                b'\\x16\\x0bHello World')\n+\n+        othernames = ext.value.get_values_for_type(x509.OtherName)\n+        assert othernames == [b'\\x16\\x0bHello World']","path":"tests/test_x509_ext.py","position":70,"original_position":70,"commit_id":"d411864709e30bbf2e70a96ed977289eb846eded","original_commit_id":"d411864709e30bbf2e70a96ed977289eb846eded","user":{"login":"JoshData","id":445875,"avatar_url":"https://avatars.githubusercontent.com/u/445875?v=3","gravatar_id":"","url":"https://api.github.com/users/JoshData","html_url":"https://github.com/JoshData","followers_url":"https://api.github.com/users/JoshData/followers","following_url":"https://api.github.com/users/JoshData/following{/other_user}","gists_url":"https://api.github.com/users/JoshData/gists{/gist_id}","starred_url":"https://api.github.com/users/JoshData/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JoshData/subscriptions","organizations_url":"https://api.github.com/users/JoshData/orgs","repos_url":"https://api.github.com/users/JoshData/repos","events_url":"https://api.github.com/users/JoshData/events{/privacy}","received_events_url":"https://api.github.com/users/JoshData/received_events","type":"User","site_admin":false},"body":"Err, I forgot that value was the name of the der property and not just an abstract method for getting the value. Nevermind. Special-casing sounds better.","created_at":"2015-07-05T22:03:02Z","updated_at":"2015-07-05T22:03:02Z","html_url":"https://github.com/pyca/cryptography/pull/2108#discussion_r33899481","pull_request_url":"https://api.github.com/repos/pyca/cryptography/pulls/2108","_links":{"self":{"href":"https://api.github.com/repos/pyca/cryptography/pulls/comments/33899481"},"html":{"href":"https://github.com/pyca/cryptography/pull/2108#discussion_r33899481"},"pull_request":{"href":"https://api.github.com/repos/pyca/cryptography/pulls/2108"}}},"pull_request":{"url":"https://api.github.com/repos/pyca/cryptography/pulls/2108","id":39209005,"html_url":"https://github.com/pyca/cryptography/pull/2108","diff_url":"https://github.com/pyca/cryptography/pull/2108.diff","patch_url":"https://github.com/pyca/cryptography/pull/2108.patch","issue_url":"https://api.github.com/repos/pyca/cryptography/issues/2108","number":2108,"state":"open","locked":false,"title":"Dont bail if a certficate SAN has an unsupported GeneralName?","user":{"login":"JoshData","id":445875,"avatar_url":"https://avatars.githubusercontent.com/u/445875?v=3","gravatar_id":"","url":"https://api.github.com/users/JoshData","html_url":"https://github.com/JoshData","followers_url":"https://api.github.com/users/JoshData/followers","following_url":"https://api.github.com/users/JoshData/following{/other_user}","gists_url":"https://api.github.com/users/JoshData/gists{/gist_id}","starred_url":"https://api.github.com/users/JoshData/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JoshData/subscriptions","organizations_url":"https://api.github.com/users/JoshData/orgs","repos_url":"https://api.github.com/users/JoshData/repos","events_url":"https://api.github.com/users/JoshData/events{/privacy}","received_events_url":"https://api.github.com/users/JoshData/received_events","type":"User","site_admin":false},"body":"There are a few GeneralName types that aren't yet supported. I encountered an otherName in the wild (https://github.com/mail-in-a-box/mailinabox/issues/481). Rather than raising an exception and preventing the certificate from being loaded at all, it would be nice if the library is able to parse the certificate but leave the otherName as a placeholder.\r\n\r\nThis patch removes the `x509.UnsupportedGeneralNameType` exception and adds a new class `x509.UnsupportedGeneralName`.\r\n\r\nWhat do you think?\r\n\r\nI didn't update the tests. Wasn't sure quite how to do that.","created_at":"2015-07-04T15:10:10Z","updated_at":"2015-07-05T22:03:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9e267fbd8b258f1aff05b07df11c87db2e278633","assignee":null,"milestone":{"url":"https://api.github.com/repos/pyca/cryptography/milestones/11","html_url":"https://github.com/pyca/cryptography/milestones/Tenth%20Release","labels_url":"https://api.github.com/repos/pyca/cryptography/milestones/11/labels","id":1099545,"number":11,"title":"Tenth Release","description":"","creator":{"login":"reaperhulk","id":161495,"avatar_url":"https://avatars.githubusercontent.com/u/161495?v=3","gravatar_id":"","url":"https://api.github.com/users/reaperhulk","html_url":"https://github.com/reaperhulk","followers_url":"https://api.github.com/users/reaperhulk/followers","following_url":"https://api.github.com/users/reaperhulk/following{/other_user}","gists_url":"https://api.github.com/users/reaperhulk/gists{/gist_id}","starred_url":"https://api.github.com/users/reaperhulk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/reaperhulk/subscriptions","organizations_url":"https://api.github.com/users/reaperhulk/orgs","repos_url":"https://api.github.com/users/reaperhulk/repos","events_url":"https://api.github.com/users/reaperhulk/events{/privacy}","received_events_url":"https://api.github.com/users/reaperhulk/received_events","type":"User","site_admin":false},"open_issues":5,"closed_issues":102,"state":"open","created_at":"2015-05-07T04:01:32Z","updated_at":"2015-07-05T19:07:16Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/pyca/cryptography/pulls/2108/commits","review_comments_url":"https://api.github.com/repos/pyca/cryptography/pulls/2108/comments","review_comment_url":"https://api.github.com/repos/pyca/cryptography/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pyca/cryptography/issues/2108/comments","statuses_url":"https://api.github.com/repos/pyca/cryptography/statuses/d411864709e30bbf2e70a96ed977289eb846eded","head":{"label":"mail-in-a-box:master","ref":"master","sha":"d411864709e30bbf2e70a96ed977289eb846eded","user":{"login":"mail-in-a-box","id":8107370,"avatar_url":"https://avatars.githubusercontent.com/u/8107370?v=3","gravatar_id":"","url":"https://api.github.com/users/mail-in-a-box","html_url":"https://github.com/mail-in-a-box","followers_url":"https://api.github.com/users/mail-in-a-box/followers","following_url":"https://api.github.com/users/mail-in-a-box/following{/other_user}","gists_url":"https://api.github.com/users/mail-in-a-box/gists{/gist_id}","starred_url":"https://api.github.com/users/mail-in-a-box/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mail-in-a-box/subscriptions","organizations_url":"https://api.github.com/users/mail-in-a-box/orgs","repos_url":"https://api.github.com/users/mail-in-a-box/repos","events_url":"https://api.github.com/users/mail-in-a-box/events{/privacy}","received_events_url":"https://api.github.com/users/mail-in-a-box/received_events","type":"Organization","site_admin":false},"repo":{"id":38537266,"name":"cryptography","full_name":"mail-in-a-box/cryptography","owner":{"login":"mail-in-a-box","id":8107370,"avatar_url":"https://avatars.githubusercontent.com/u/8107370?v=3","gravatar_id":"","url":"https://api.github.com/users/mail-in-a-box","html_url":"https://github.com/mail-in-a-box","followers_url":"https://api.github.com/users/mail-in-a-box/followers","following_url":"https://api.github.com/users/mail-in-a-box/following{/other_user}","gists_url":"https://api.github.com/users/mail-in-a-box/gists{/gist_id}","starred_url":"https://api.github.com/users/mail-in-a-box/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mail-in-a-box/subscriptions","organizations_url":"https://api.github.com/users/mail-in-a-box/orgs","repos_url":"https://api.github.com/users/mail-in-a-box/repos","events_url":"https://api.github.com/users/mail-in-a-box/events{/privacy}","received_events_url":"https://api.github.com/users/mail-in-a-box/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mail-in-a-box/cryptography","description":"cryptography is a package designed to expose cryptographic primitives and recipes to Python developers.","fork":true,"url":"https://api.github.com/repos/mail-in-a-box/cryptography","forks_url":"https://api.github.com/repos/mail-in-a-box/cryptography/forks","keys_url":"https://api.github.com/repos/mail-in-a-box/cryptography/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mail-in-a-box/cryptography/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mail-in-a-box/cryptography/teams","hooks_url":"https://api.github.com/repos/mail-in-a-box/cryptography/hooks","issue_events_url":"https://api.github.com/repos/mail-in-a-box/cryptography/issues/events{/number}","events_url":"https://api.github.com/repos/mail-in-a-box/cryptography/events","assignees_url":"https://api.github.com/repos/mail-in-a-box/cryptography/assignees{/user}","branches_url":"https://api.github.com/repos/mail-in-a-box/cryptography/branches{/branch}","tags_url":"https://api.github.com/repos/mail-in-a-box/cryptography/tags","blobs_url":"https://api.github.com/repos/mail-in-a-box/cryptography/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mail-in-a-box/cryptography/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mail-in-a-box/cryptography/git/refs{/sha}","trees_url":"https://api.github.com/repos/mail-in-a-box/cryptography/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mail-in-a-box/cryptography/statuses/{sha}","languages_url":"https://api.github.com/repos/mail-in-a-box/cryptography/languages","stargazers_url":"https://api.github.com/repos/mail-in-a-box/cryptography/stargazers","contributors_url":"https://api.github.com/repos/mail-in-a-box/cryptography/contributors","subscribers_url":"https://api.github.com/repos/mail-in-a-box/cryptography/subscribers","subscription_url":"https://api.github.com/repos/mail-in-a-box/cryptography/subscription","commits_url":"https://api.github.com/repos/mail-in-a-box/cryptography/commits{/sha}","git_commits_url":"https://api.github.com/repos/mail-in-a-box/cryptography/git/commits{/sha}","comments_url":"https://api.github.com/repos/mail-in-a-box/cryptography/comments{/number}","issue_comment_url":"https://api.github.com/repos/mail-in-a-box/cryptography/issues/comments{/number}","contents_url":"https://api.github.com/repos/mail-in-a-box/cryptography/contents/{+path}","compare_url":"https://api.github.com/repos/mail-in-a-box/cryptography/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mail-in-a-box/cryptography/merges","archive_url":"https://api.github.com/repos/mail-in-a-box/cryptography/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mail-in-a-box/cryptography/downloads","issues_url":"https://api.github.com/repos/mail-in-a-box/cryptography/issues{/number}","pulls_url":"https://api.github.com/repos/mail-in-a-box/cryptography/pulls{/number}","milestones_url":"https://api.github.com/repos/mail-in-a-box/cryptography/milestones{/number}","notifications_url":"https://api.github.com/repos/mail-in-a-box/cryptography/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mail-in-a-box/cryptography/labels{/name}","releases_url":"https://api.github.com/repos/mail-in-a-box/cryptography/releases{/id}","created_at":"2015-07-04T14:54:18Z","updated_at":"2015-07-04T14:54:25Z","pushed_at":"2015-07-05T21:45:14Z","git_url":"git://github.com/mail-in-a-box/cryptography.git","ssh_url":"git@github.com:mail-in-a-box/cryptography.git","clone_url":"https://github.com/mail-in-a-box/cryptography.git","svn_url":"https://github.com/mail-in-a-box/cryptography","homepage":"https://cryptography.io/","size":44691,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"pyca:master","ref":"master","sha":"0784a23d4ab15e98214ccdf07021d42568404c1c","user":{"login":"pyca","id":5615737,"avatar_url":"https://avatars.githubusercontent.com/u/5615737?v=3","gravatar_id":"","url":"https://api.github.com/users/pyca","html_url":"https://github.com/pyca","followers_url":"https://api.github.com/users/pyca/followers","following_url":"https://api.github.com/users/pyca/following{/other_user}","gists_url":"https://api.github.com/users/pyca/gists{/gist_id}","starred_url":"https://api.github.com/users/pyca/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pyca/subscriptions","organizations_url":"https://api.github.com/users/pyca/orgs","repos_url":"https://api.github.com/users/pyca/repos","events_url":"https://api.github.com/users/pyca/events{/privacy}","received_events_url":"https://api.github.com/users/pyca/received_events","type":"Organization","site_admin":false},"repo":{"id":11939484,"name":"cryptography","full_name":"pyca/cryptography","owner":{"login":"pyca","id":5615737,"avatar_url":"https://avatars.githubusercontent.com/u/5615737?v=3","gravatar_id":"","url":"https://api.github.com/users/pyca","html_url":"https://github.com/pyca","followers_url":"https://api.github.com/users/pyca/followers","following_url":"https://api.github.com/users/pyca/following{/other_user}","gists_url":"https://api.github.com/users/pyca/gists{/gist_id}","starred_url":"https://api.github.com/users/pyca/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pyca/subscriptions","organizations_url":"https://api.github.com/users/pyca/orgs","repos_url":"https://api.github.com/users/pyca/repos","events_url":"https://api.github.com/users/pyca/events{/privacy}","received_events_url":"https://api.github.com/users/pyca/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/pyca/cryptography","description":"cryptography is a package designed to expose cryptographic primitives and recipes to Python developers.","fork":false,"url":"https://api.github.com/repos/pyca/cryptography","forks_url":"https://api.github.com/repos/pyca/cryptography/forks","keys_url":"https://api.github.com/repos/pyca/cryptography/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pyca/cryptography/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pyca/cryptography/teams","hooks_url":"https://api.github.com/repos/pyca/cryptography/hooks","issue_events_url":"https://api.github.com/repos/pyca/cryptography/issues/events{/number}","events_url":"https://api.github.com/repos/pyca/cryptography/events","assignees_url":"https://api.github.com/repos/pyca/cryptography/assignees{/user}","branches_url":"https://api.github.com/repos/pyca/cryptography/branches{/branch}","tags_url":"https://api.github.com/repos/pyca/cryptography/tags","blobs_url":"https://api.github.com/repos/pyca/cryptography/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pyca/cryptography/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pyca/cryptography/git/refs{/sha}","trees_url":"https://api.github.com/repos/pyca/cryptography/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pyca/cryptography/statuses/{sha}","languages_url":"https://api.github.com/repos/pyca/cryptography/languages","stargazers_url":"https://api.github.com/repos/pyca/cryptography/stargazers","contributors_url":"https://api.github.com/repos/pyca/cryptography/contributors","subscribers_url":"https://api.github.com/repos/pyca/cryptography/subscribers","subscription_url":"https://api.github.com/repos/pyca/cryptography/subscription","commits_url":"https://api.github.com/repos/pyca/cryptography/commits{/sha}","git_commits_url":"https://api.github.com/repos/pyca/cryptography/git/commits{/sha}","comments_url":"https://api.github.com/repos/pyca/cryptography/comments{/number}","issue_comment_url":"https://api.github.com/repos/pyca/cryptography/issues/comments{/number}","contents_url":"https://api.github.com/repos/pyca/cryptography/contents/{+path}","compare_url":"https://api.github.com/repos/pyca/cryptography/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pyca/cryptography/merges","archive_url":"https://api.github.com/repos/pyca/cryptography/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pyca/cryptography/downloads","issues_url":"https://api.github.com/repos/pyca/cryptography/issues{/number}","pulls_url":"https://api.github.com/repos/pyca/cryptography/pulls{/number}","milestones_url":"https://api.github.com/repos/pyca/cryptography/milestones{/number}","notifications_url":"https://api.github.com/repos/pyca/cryptography/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pyca/cryptography/labels{/name}","releases_url":"https://api.github.com/repos/pyca/cryptography/releases{/id}","created_at":"2013-08-07T02:23:38Z","updated_at":"2015-07-03T06:26:33Z","pushed_at":"2015-07-05T21:45:15Z","git_url":"git://github.com/pyca/cryptography.git","ssh_url":"git@github.com:pyca/cryptography.git","clone_url":"https://github.com/pyca/cryptography.git","svn_url":"https://github.com/pyca/cryptography","homepage":"https://cryptography.io/","size":44691,"stargazers_count":721,"watchers_count":721,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":164,"mirror_url":null,"open_issues_count":72,"forks":164,"open_issues":72,"watchers":721,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pyca/cryptography/pulls/2108"},"html":{"href":"https://github.com/pyca/cryptography/pull/2108"},"issue":{"href":"https://api.github.com/repos/pyca/cryptography/issues/2108"},"comments":{"href":"https://api.github.com/repos/pyca/cryptography/issues/2108/comments"},"review_comments":{"href":"https://api.github.com/repos/pyca/cryptography/pulls/2108/comments"},"review_comment":{"href":"https://api.github.com/repos/pyca/cryptography/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pyca/cryptography/pulls/2108/commits"},"statuses":{"href":"https://api.github.com/repos/pyca/cryptography/statuses/d411864709e30bbf2e70a96ed977289eb846eded"}}}}