From 36ab447c7b16e2cf496aef9bfdc5ee900268939e Mon Sep 17 00:00:00 2001 From: Raul Metsma Date: Wed, 3 Jul 2024 10:00:30 +0300 Subject: [PATCH] HTML Escape certificate content (#1267) IB-8093 Signed-off-by: Raul Metsma --- client/widgets/CardWidget.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/widgets/CardWidget.cpp b/client/widgets/CardWidget.cpp index cc1ccc916..26a68f86b 100644 --- a/client/widgets/CardWidget.cpp +++ b/client/widgets/CardWidget.cpp @@ -91,9 +91,9 @@ void CardWidget::update(const TokenData &token, bool multiple) SslCertificate c = t.cert(); QString id = c.personalCode(); if(!c.subjectInfo("GN").isEmpty() || !c.subjectInfo("SN").isEmpty()) - ui->cardName->setText(c.toString(QStringLiteral("GN SN"))); + ui->cardName->setText(c.toString(QStringLiteral("GN SN")).toHtmlEscaped()); else - ui->cardName->setText(c.toString(QStringLiteral("CN"))); + ui->cardName->setText(c.toString(QStringLiteral("CN")).toHtmlEscaped()); ui->cardName->setAccessibleName(ui->cardName->text().toLower()); ui->cardCode->setText(id + " |"); ui->cardCode->setAccessibleName(id);