--- a/eric6/E5Network/E5SslInfoWidget.py Mon Mar 01 17:48:43 2021 +0100 +++ b/eric6/E5Network/E5SslInfoWidget.py Tue Mar 02 17:17:09 2021 +0100 @@ -47,11 +47,12 @@ ## Identity Information ########################################## imageLabel = QLabel(self) - layout.addWidget(imageLabel, rows, 0, Qt.AlignCenter) + layout.addWidget(imageLabel, rows, 0, Qt.AlignmentFlag.AlignCenter) label = QLabel(self) label.setWordWrap(True) - label.setSizePolicy(QSizePolicy.Expanding, QSizePolicy.Preferred) + label.setSizePolicy(QSizePolicy.Policy.Expanding, + QSizePolicy.Policy.Preferred) label.setText(self.tr("Identity")) font = label.font() font.setBold(True) @@ -69,7 +70,7 @@ valid = not cert.isBlacklisted() if valid: txt = ", ".join( - cert.issuerInfo(QSslCertificate.CommonName)) + cert.issuerInfo(QSslCertificate.SubjectInfo.CommonName)) label.setText(self.tr( "The certificate for this site is valid" " and has been verified by:\n{0}").format( @@ -97,7 +98,7 @@ ## Identity Information ########################################## imageLabel = QLabel(self) - layout.addWidget(imageLabel, rows, 0, Qt.AlignCenter) + layout.addWidget(imageLabel, rows, 0, Qt.AlignmentFlag.AlignCenter) label = QLabel(self) label.setWordWrap(True) @@ -127,15 +128,15 @@ layout.addWidget(label, rows, 1) proto = cipher.protocol() - if proto == QSsl.SslV3: + if proto == QSsl.SslProtocol.SslV3: sslVersion = "SSL 3.0" imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityLow32")) - elif proto == QSsl.TlsV1SslV3: + elif proto == QSsl.SslProtocol.TlsV1SslV3: sslVersion = "TLS 1.0/SSL 3.0" imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityLow32")) - elif proto == QSsl.SslV2: + elif proto == QSsl.SslProtocol.SslV2: sslVersion = "SSL 2.0" imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityLow32")) @@ -143,19 +144,19 @@ sslVersion = self.tr("unknown") imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityLow32")) - if proto == QSsl.TlsV1_0: + if proto == QSsl.SslProtocol.TlsV1_0: sslVersion = "TLS 1.0" imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityHigh32")) - elif proto == QSsl.TlsV1_1: + elif proto == QSsl.SslProtocol.TlsV1_1: sslVersion = "TLS 1.1" imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityHigh32")) - elif proto == QSsl.TlsV1_2: + elif proto == QSsl.SslProtocol.TlsV1_2: sslVersion = "TLS 1.2" imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityHigh32")) - elif proto == QSsl.TlsV1_3: + elif proto == QSsl.SslProtocol.TlsV1_3: sslVersion = "TLS 1.3" imageLabel.setPixmap( UI.PixmapCache.getPixmap("securityHigh32"))