Providing SSL Connections in Python using PKCS#11

后端 未结 1 432
梦谈多话
梦谈多话 2020-12-15 09:52

I have to implement a Python based web server on a Linux based firmware for an embedded system component:

class WebServer(http.server.HTTPServer)
...
...


        
相关标签:
1条回答
  • 2020-12-15 10:29

    It's not recommended to do this TLS stuff in the webserver with Python. It's better to do it using nginx or apache. They support both the pkcs#11 SSL context and are fast to negociate SSL since they are written in C.

    So to resume:

    • Stay on HTTP (not secure) in Python side
    • Install nginx or apache
    • Configure it for HTTPS :
      1. using pkcs#11 SSL cert/key (pkcs#11 URI to your HSM)
      2. reverse proxy it to your HTTP (not secure) Python webserver.
    0 讨论(0)
提交回复
热议问题