Refuse to listen to QT_PLUGIN_PATH.

We don't need it ourselves, and it's a potentially serious attack vector.

CURA-8475
This commit is contained in:
Remco Burema 2022-01-07 19:12:36 +01:00
parent 25ec588754
commit c849cf8e88
No known key found for this signature in database
GPG Key ID: 215C49431D43F98C

View File

@ -15,6 +15,7 @@ if "" in sys.path:
import argparse
import faulthandler
import os
os.environ["QT_PLUGIN_PATH"] = "" # Security workaround: Don't need it, and introduces an attack vector, so set to nul.
from PyQt5.QtNetwork import QSslConfiguration, QSslSocket