From 480ac74b4b46ce73d3349293becb77bd76bc66b6 Mon Sep 17 00:00:00 2001 From: Raul Metsma Date: Thu, 31 Mar 2022 11:56:38 +0300 Subject: [PATCH] Show SN,GN,serialNumber if available (#1061) IB-7350 Signed-off-by: Raul Metsma --- client/dialogs/SignatureDialog.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/dialogs/SignatureDialog.cpp b/client/dialogs/SignatureDialog.cpp index e6c3aa7c8..8a929e669 100644 --- a/client/dialogs/SignatureDialog.cpp +++ b/client/dialogs/SignatureDialog.cpp @@ -172,7 +172,7 @@ SignatureDialog::SignatureDialog(const DigiDocSignature &signature, QWidget *par if(cert.isNull()) return; addItem(t, title, cert); - addItem(t, title2, CertificateDetails::decodeCN(cert.issuerInfo(QSslCertificate::CommonName))); + addItem(t, title2, cert.issuerInfo(QSslCertificate::CommonName)); }; auto addTime = [this](QTreeWidget *t, const QString &title, const QDateTime &time) { if(time.isNull()) @@ -248,7 +248,7 @@ void SignatureDialog::addItem(QTreeWidget *view, const QString &variable, const { SslCertificate c(value); QPushButton *button = itemButton( - CertificateDetails::decodeCN(c.subjectInfo(QSslCertificate::CommonName)), view); + c.toString(c.showCN() ? QStringLiteral("CN") : QStringLiteral("GN,SN,serialNumber")), view); connect(button, &QPushButton::clicked, this, [=]{ CertificateDetails::showCertificate(c, this); }); addItem(view, variable, button); }