Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uncaught exception for duplicate x509 extension #420

Closed
hansjakobli opened this issue Mar 25, 2020 · 1 comment
Closed

Uncaught exception for duplicate x509 extension #420

hansjakobli opened this issue Mar 25, 2020 · 1 comment

Comments

@hansjakobli
Copy link

Exception: cryptography.x509.extensions.DuplicateExtension
Run with options sslyze --json_out=- --certinfo --slow_connection

Traceback (most recent call last): File "/usr/local/bin/sslyze", line 8, in <module> sys.exit(main()) File "/usr/local/lib/python3.7/site-packages/sslyze/__main__.py", line 125, in main output_hub.scans_completed(exec_time) File "/usr/local/lib/python3.7/site-packages/sslyze/cli/output_hub.py", line 77, in scans_completed out_generator.scans_completed(total_scan_time) File "/usr/local/lib/python3.7/site-packages/sslyze/cli/json_output.py", line 69, in scans_completed json_out = json.dumps(self._json_dict, cls=_CustomJsonEncoder, sort_keys=True, indent=4, ensure_ascii=True) File "/usr/local/lib/python3.7/json/__init__.py", line 238, in dumps **kw).encode(obj) File "/usr/local/lib/python3.7/json/encoder.py", line 201, in encode chunks = list(chunks) File "/usr/local/lib/python3.7/json/encoder.py", line 431, in _iterencode yield from _iterencode_dict(o, _current_indent_level) File "/usr/local/lib/python3.7/json/encoder.py", line 405, in _iterencode_dict yield from chunks File "/usr/local/lib/python3.7/json/encoder.py", line 325, in _iterencode_list yield from chunks File "/usr/local/lib/python3.7/json/encoder.py", line 405, in _iterencode_dict yield from chunks File "/usr/local/lib/python3.7/json/encoder.py", line 405, in _iterencode_dict yield from chunks File "/usr/local/lib/python3.7/json/encoder.py", line 405, in _iterencode_dict yield from chunks File "/usr/local/lib/python3.7/json/encoder.py", line 325, in _iterencode_list yield from chunks File "/usr/local/lib/python3.7/json/encoder.py", line 438, in _iterencode o = _default(o) File "/usr/local/lib/python3.7/site-packages/sslyze/cli/json_output.py", line 99, in default dns_alt_names = CertificateUtils.get_dns_subject_alternative_names(certificate) File "/usr/local/lib/python3.7/site-packages/sslyze/plugins/utils/certificate_utils.py", line 27, in get_dns_subject_alternative_names san_ext = certificate.extensions.get_extension_for_oid(ExtensionOID.SUBJECT_ALTERNATIVE_NAME) File "/usr/local/lib/python3.7/site-packages/cryptography/utils.py", line 170, in inner result = func(instance) File "/usr/local/lib/python3.7/site-packages/cryptography/hazmat/backends/openssl/x509.py", line 137, in extensions self._backend, self._x509 File "/usr/local/lib/python3.7/site-packages/cryptography/hazmat/backends/openssl/decode_asn1.py", line 205, in parse "Duplicate {0} extension found".format(oid), oid cryptography.x509.extensions.DuplicateExtension: Duplicate <ObjectIdentifier(oid=2.5.29.19, name=basicConstraints)> extension found

@nabla-c0d3
Copy link
Owner

Fix released in v3.0.2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants