diff --git a/src/network/networkmanager.cpp b/src/network/networkmanager.cpp index 45920564f..cab11d09b 100644 --- a/src/network/networkmanager.cpp +++ b/src/network/networkmanager.cpp @@ -345,7 +345,10 @@ void NetworkManager::addLocalCertificate(const QSslCertificate &cert) dir.mkdir("certificates"); } - QString fileName = qz_ensureUniqueFilename(mApp->getActiveProfilPath() + "certificates/" + CertificateInfoWidget::certificateItemText(cert).remove(" ") + ".crt"); + QString certFileName = CertificateInfoWidget::certificateItemText(cert).remove(" ") + ".crt"; + certFileName = certFileName.remove("/"); + QString fileName = qz_ensureUniqueFilename(mApp->getActiveProfilPath() + "certificates/" + certFileName); + QFile file(fileName); if (file.open(QFile::WriteOnly)) {