Python3 SSL – Ignore hostname verification only for debugging purposes!

Spread the love

Sometimes, when using self-signed certificate need to disable verification for debug.

Just use code in the head of your python script:

import ssl
ssl.match_hostname = lambda cert, hostname: True

Добавить комментарий