1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/test/units/module_utils/urls
Matt Martz 8bd4e2a144 cert validation fixes - Attempt 2 (#55953)
* Attempt 2 of cert validation fixes

* Remove unused code

* Cleanup the tmp cert using atexit

* Fix linting issues

* Only add SSLValidationHandler when not HAS_SSLCONTEXT

* Catch value errors on non PEM certs

* Only catch NotImplementedError to avoid masking issues

* set self._context even with PyOpenSSLContext for conformity

* Fix error building

* normalize how we interact with the context we create

* Remove unused code

* Address test for py3.7 message difference

* open_url should pass the ca_path through

* Account for new error in url lookup test

* Guard some code behind whether or not we are validating certs

* Make _make_context public

* Move atexit.register up to where the tmp file is created
2019-05-31 16:35:25 -04:00
..
fixtures Add unit tests for ansible.module_utils.urls (#38059) 2018-04-09 10:17:43 -05:00
__init__.py Add unit tests for ansible.module_utils.urls (#38059) 2018-04-09 10:17:43 -05:00
test_fetch_url.py cert validation fixes - Attempt 2 (#55953) 2019-05-31 16:35:25 -04:00
test_generic_urlparse.py Add unit tests for ansible.module_utils.urls (#38059) 2018-04-09 10:17:43 -05:00
test_RedirectHandlerFactory.py cert validation fixes - Attempt 2 (#55953) 2019-05-31 16:35:25 -04:00
test_Request.py cert validation fixes - Attempt 2 (#55953) 2019-05-31 16:35:25 -04:00
test_RequestWithMethod.py Add unit tests for ansible.module_utils.urls (#38059) 2018-04-09 10:17:43 -05:00
test_urls.py Don't rely on netloc for determining hostname and port, just use hostname and port (#56270) 2019-05-20 16:50:54 -04:00