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

ssl.SSLCertVerificationError hostname mismatch #3

Closed
jborbely opened this issue Sep 9, 2018 · 1 comment
Closed

ssl.SSLCertVerificationError hostname mismatch #3

jborbely opened this issue Sep 9, 2018 · 1 comment

Comments

@jborbely
Copy link
Contributor

jborbely commented Sep 9, 2018

This exception occurs because SSL certificates are signed against hostnames and not IP addresses

Traceback (most recent call last):
  File "hostname_issue.py", line 4, in <module>
    cxn = connect(host='192.168.1.68')
  File "d:\code\git\msl-network\msl\network\client.py", line 68, in connect
    password_manager, certificate, disable_tls, debug)
  File "d:\code\git\msl-network\msl\network\client.py", line 558, in start
    if not self._create_connection(self._host_manager, port, certificate, disable_tls, timeout):
  File "d:\code\git\msl-network\msl\network\network.py", line 271, in _create_connection
    ssl=context,
  File "C:\Users\j.borbely\Miniconda3\envs\msl\lib\asyncio\base_events.py", line 568, in run_until_complete
    return future.result()
  File "C:\Users\j.borbely\Miniconda3\envs\msl\lib\asyncio\base_events.py", line 970, in create_connection
    ssl_handshake_timeout=ssl_handshake_timeout)
  File "C:\Users\j.borbely\Miniconda3\envs\msl\lib\asyncio\base_events.py", line 998, in _create_connection_transport
    await waiter
  File "C:\Users\j.borbely\Miniconda3\envs\msl\lib\asyncio\sslproto.py", line 526, in data_received
    ssldata, appdata = self._sslpipe.feed_ssldata(data)
  File "C:\Users\j.borbely\Miniconda3\envs\msl\lib\asyncio\sslproto.py", line 189, in feed_ssldata
    self._sslobj.do_handshake()
  File "C:\Users\j.borbely\Miniconda3\envs\msl\lib\ssl.py", line 763, in do_handshake
    self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: IP address mismatch, certificate is not valid for '192.168.1.68'. (_ssl.c:1045)
@jborbely
Copy link
Contributor Author

jborbely commented Sep 29, 2018

fixed in v0.3.0

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

1 participant