5265c69ed6
* external/poppler/char_traits.patch is no longer neeeded after https://cgit.freedesktop.org/poppler/poppler/commit/cpp/poppler-global.h?id=b4ac7d9af7cb5edfcfcbda035ed8b8c218ba8564 * Adapt external/poppler/disable-nss-and-gpgmepp.patch.1 after https://cgit.freedesktop.org/poppler/poppler/commit/?id=d40bb7e308c9e3299e50d3e2880229cd6272587e Downloaded from https://poppler.freedesktop.org/poppler-24.05.0.tar.xz Change-Id: I87ed833f92e504f0a39b5f64c1db42d579050a37 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167582 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
103 lines
3 KiB
Groff
103 lines
3 KiB
Groff
disable NSS/GPGMEPP dependent code.
|
|
|
|
--- poppler/poppler/Form.cc.orig 2023-06-05 19:29:14.000000000 +0900
|
|
+++ poppler/poppler/Form.cc 2023-06-17 16:51:27.873431500 +0900
|
|
@@ -64,7 +64,7 @@
|
|
#include "Form.h"
|
|
#include "PDFDoc.h"
|
|
#include "DateInfo.h"
|
|
-#include "CryptoSignBackend.h"
|
|
+/*#include "CryptoSignBackend.h"*/
|
|
#include "SignatureInfo.h"
|
|
#include "CertificateInfo.h"
|
|
#include "XRef.h"
|
|
@@ -584,7 +584,7 @@
|
|
{
|
|
return static_cast<FormFieldSignature *>(field)->validateSignatureResult();
|
|
}
|
|
-
|
|
+#if 0
|
|
// update hash with the specified range of data from the file
|
|
static bool hashFileRange(FILE *f, CryptoSign::SigningInterface *handler, Goffset start, Goffset end)
|
|
{
|
|
@@ -608,10 +608,12 @@
|
|
delete[] buf;
|
|
return true;
|
|
}
|
|
+#endif
|
|
|
|
bool FormWidgetSignature::signDocument(const std::string &saveFilename, const std::string &certNickname, const std::string &password, const GooString *reason, const GooString *location, const std::optional<GooString> &ownerPassword,
|
|
const std::optional<GooString> &userPassword)
|
|
{
|
|
+#if 0
|
|
auto backend = CryptoSign::Factory::createActive();
|
|
if (!backend) {
|
|
return false;
|
|
@@ -697,8 +699,8 @@
|
|
signatureField->setSignature(*signature);
|
|
|
|
fclose(file);
|
|
-
|
|
- return true;
|
|
+#endif
|
|
+ return false;
|
|
}
|
|
|
|
static std::tuple<double, double> calculateDxDy(int rot, const PDFRectangle *rect)
|
|
@@ -2355,6 +2357,7 @@
|
|
|
|
void FormFieldSignature::hashSignedDataBlock(CryptoSign::VerificationInterface *handler, Goffset block_len)
|
|
{
|
|
+#if 0
|
|
if (!handler) {
|
|
return;
|
|
}
|
|
@@ -2374,6 +2377,7 @@
|
|
i += BLOCK_SIZE;
|
|
}
|
|
}
|
|
+#endif
|
|
}
|
|
|
|
FormSignatureType FormWidgetSignature::signatureType() const
|
|
@@ -2395,6 +2399,7 @@
|
|
|
|
SignatureInfo *FormFieldSignature::validateSignatureAsync(bool doVerifyCert, bool forceRevalidation, time_t validationTime, bool ocspRevocationCheck, bool enableAIA, const std::function<void()> &doneCallback)
|
|
{
|
|
+#if 0
|
|
auto backend = CryptoSign::Factory::createActive();
|
|
if (!backend) {
|
|
if (doneCallback) {
|
|
@@ -2497,6 +2502,7 @@
|
|
|
|
signature_handler->validateCertificateAsync(std::chrono::system_clock::from_time_t(validationTime), ocspRevocationCheck, enableAIA, doneCallback);
|
|
|
|
+#endif
|
|
return signature_info;
|
|
}
|
|
|
|
@@ -2508,10 +2508,13 @@
|
|
|
|
CertificateValidationStatus FormFieldSignature::validateSignatureResult()
|
|
{
|
|
+#if 0
|
|
if (!signature_handler) {
|
|
return CERTIFICATE_GENERIC_ERROR;
|
|
}
|
|
return signature_handler->validateCertificateResult();
|
|
+#endif
|
|
+ return CERTIFICATE_GENERIC_ERROR;
|
|
}
|
|
|
|
std::vector<Goffset> FormFieldSignature::getSignedRangeBounds() const
|
|
|
|
--- poppler/poppler/Form.h 2024-05-13 10:18:04.303912457 +0200
|
|
+++ poppler/poppler/Form.h 2024-05-13 11:41:51.547002511 +0200
|
|
@@ -669,7 +669,6 @@
|
|
double customAppearanceLeftFontSize = 20;
|
|
Ref imageResource = Ref::INVALID();
|
|
std::unique_ptr<X509CertificateInfo> certificate_info;
|
|
- std::unique_ptr<CryptoSign::VerificationInterface> signature_handler;
|
|
|
|
void print(int indent) override;
|
|
};
|