jczic / MicroWebSrv2

The last Micro Web Server for IoTs (MicroPython) or large servers (CPython), that supports WebSockets, routes, template engine and with really optimized architecture (mem allocations, async I/Os). Ready for ESP32, STM32 on Pyboard, Pycom's chipsets (WiPy, LoPy, ...). Robust, efficient and documented!
https://github.com/jczic/MicroWebSrv2
MIT License
662 stars 97 forks source link

Regression: ssl.SSLEOFError Unsupported in Micropython After Recent Commit #100

Closed ekondayan closed 9 months ago

ekondayan commented 9 months ago

The latest changes in commit 40fc58f4222938e6a3fe04488cb4d474a62b6226 have introduced a compatibility issue with Micropython, specifically related to the handling of SSL errors. The ssl module in Micropython does not support ssl.SSLEOFError, which is now referenced in the Microwebsrv2 code.

Possible Solution: Exception handling on line 666: except ssl.SSLEOFError : to be removed and use the general exception handler below

Additional Context:

I believe addressing this issue is crucial for maintaining Micropython compatibility.

jczic commented 9 months ago

Thank you very much @ekondayan! It should be OK with the commit: 17611da0d87598846b17b0a3363af6c4438961ca

This SSL error can sometimes occur when a large number of SSL requests (attacks) are cut off before they have been fully transmitted. This does not affect microcontrollers.

ekondayan commented 9 months ago

Thank you. It works now.