This is not how server-side sockets are supposed to be created. Please read the docs:
- server_side selects whether the wrapped socket is on the server or client side. A server-side SSL socket should be created from a normal socket returned from
accept()on a non-SSL listening server socket.
https://docs.micropython.org/en/latest/library/ssl.html#ssl.SSLContext.wrap_socket
Meaning, you should accept the socket, and call wrap on the accepted socket. That said it shouldn’t cause a hard-fault, but this is a MicroPython issue, so I’ll report it upstream.
I did get as far as connecting, of course without a key this error is probably expected:
Station connected a0:29:42:56:4f:64
DHCPS: client connected: MAC=a0:29:42:56:4f:64 IP=192.168.4.16
Traceback (most recent call last):
File "<stdin>", line 51, in <module>
File "ssl.py", line 1, in wrap_socket
File "ssl.py", line 1, in wrap_socket
OSError: (-30592, 'MBEDTLS_ERR_SSL_FATAL_ALERT_MESSAGE')