Commit 5260aaa8 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Fix last check error

parent 5ab77fc2
Pipeline #52925 failed with stage
in 28 minutes and 33 seconds
......@@ -16,6 +16,7 @@
#include <QCryptographicHash>
#include <QDateTime>
#include <QFile>
#include <QRegularExpression>
#include <qca_publickey.h>
// see https://tools.ietf.org/html/rfc6376
......@@ -137,6 +138,10 @@ void DKIMCheckSignatureJob::start()
mBodyCanonizationResult.replace(QStringLiteral(" This is a cryptographically signed message in MIME format."),
QStringLiteral("This is a cryptographically signed message in MIME format."));
}
if (mBodyCanonizationResult.startsWith(QLatin1String(" \r\n"))) { // Remove it from start
static const QRegularExpression reg{QStringLiteral("^ \r\n")};
mBodyCanonizationResult.remove(reg);
}
#ifdef DEBUG_SIGNATURE_DKIM
QFile caFile(QStringLiteral("/tmp/bodycanon-kmail.txt"));
caFile.open(QIODevice::WriteOnly | QIODevice::Text);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment