Limit maximum TLS version in ftp_server to 1.2

This might fix (#58) getting uploads from the linux version of the
BambuStudio network plugin. Issue observer is connection resets with
larger uploads (somewhere >80k).
This commit is contained in:
Gernot Vormayr
2026-02-08 23:52:30 +01:00
parent f094c16012
commit 47ed16ae60
@@ -504,6 +504,7 @@ class VirtualPrinterFTPServer:
self._ssl_context = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER)
self._ssl_context.load_cert_chain(str(self.cert_path), str(self.key_path))
self._ssl_context.minimum_version = ssl.TLSVersion.TLSv1_2
self._ssl_context.maximum_version = ssl.TLSVersion.TLSv1_2
# Use standard TLS settings for compatibility
self._ssl_context.set_ciphers("HIGH:!aNULL:!MD5:!RC4")