10 from PyQt4.QtCore import QCryptographicHash |
10 from PyQt4.QtCore import QCryptographicHash |
11 from PyQt4.QtGui import QDialog |
11 from PyQt4.QtGui import QDialog |
12 from PyQt4.QtNetwork import QSslCertificate |
12 from PyQt4.QtNetwork import QSslCertificate |
13 |
13 |
14 from .Ui_SslInfoDialog import Ui_SslInfoDialog |
14 from .Ui_SslInfoDialog import Ui_SslInfoDialog |
|
15 |
|
16 import Utilities |
15 |
17 |
16 class SslInfoDialog(QDialog, Ui_SslInfoDialog): |
18 class SslInfoDialog(QDialog, Ui_SslInfoDialog): |
17 """ |
19 """ |
18 Class implementing a dialog to show SSL certificate infos. |
20 Class implementing a dialog to show SSL certificate infos. |
19 """ |
21 """ |
55 @return prepared text (string) |
57 @return prepared text (string) |
56 """ |
58 """ |
57 if txt is None or txt == "": |
59 if txt is None or txt == "": |
58 return self.trUtf8("<not part of the certificate>") |
60 return self.trUtf8("<not part of the certificate>") |
59 |
61 |
60 return txt |
62 return Utilities.decodeString(txt) |
61 |
63 |
62 def __serialNumber(self, cert): |
64 def __serialNumber(self, cert): |
63 """ |
65 """ |
64 Private slot to format the certificate serial number. |
66 Private slot to format the certificate serial number. |
65 |
67 |