When ca_certs parameter was supplied to ssl.get_server_certificate() function, the identity of the certificate is not checked.
https://mail.python.org/archives/list/[email protected]/thread/SXBD6BGHDBTGM4KSUMQEWYIQ5RO4BQ76/
https://github.com/python/cpython/pull/161507
https://github.com/python/cpython/issues/161503
https://github.com/python/cpython/commit/8dde46eaa6baf5f027a7234845b20d50b509624e