fix signature check crash
This commit is contained in:
parent
8199344b64
commit
7c82340cd6
@ -0,0 +1,27 @@
|
||||
From a38556c13b132c2e3b275fac0d2e2f0f32895036 Mon Sep 17 00:00:00 2001
|
||||
Message-Id: <a38556c13b132c2e3b275fac0d2e2f0f32895036.1590932097.git.mjg@fedoraproject.org>
|
||||
From: Paul Gardiner <paul.gardiner@artifex.com>
|
||||
Date: Tue, 12 May 2020 17:21:18 +0100
|
||||
Subject: [PATCH] Fix possible crash when using openssl for digital signature
|
||||
support.
|
||||
|
||||
---
|
||||
source/helpers/pkcs7/pkcs7-openssl.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/source/helpers/pkcs7/pkcs7-openssl.c b/source/helpers/pkcs7/pkcs7-openssl.c
|
||||
index dfb99bb8c..a0a15fbd5 100644
|
||||
--- a/source/helpers/pkcs7/pkcs7-openssl.c
|
||||
+++ b/source/helpers/pkcs7/pkcs7-openssl.c
|
||||
@@ -606,7 +606,7 @@ static char *x509_get_name_entry_string(fz_context *ctx, X509_NAME *name, int ni
|
||||
int idx = X509_NAME_get_index_by_NID(name, nid, -1);
|
||||
X509_NAME_ENTRY *entry = X509_NAME_get_entry(name, idx);
|
||||
ASN1_STRING *data = X509_NAME_ENTRY_get_data(entry);
|
||||
- return fz_strdup(ctx, (const char *)ASN1_STRING_get0_data(data));
|
||||
+ return data ? fz_strdup(ctx, (const char *)ASN1_STRING_get0_data(data)) : NULL;
|
||||
}
|
||||
|
||||
static pdf_pkcs7_designated_name *x509_designated_name(fz_context *ctx, X509 *x509)
|
||||
--
|
||||
2.27.0.rc1.210.gb37d18b052
|
||||
|
@ -1,6 +1,6 @@
|
||||
Name: mupdf
|
||||
Version: 1.17.0
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
Summary: A lightweight PDF viewer and toolkit
|
||||
License: AGPLv3+
|
||||
URL: http://mupdf.com/
|
||||
@ -23,6 +23,7 @@ Provides: bundled(freeglut-devel) = 3.0.0
|
||||
Provides: bundled(mujs-devel) = 1.0.5
|
||||
Patch0: 0001-fix-build-on-big-endian.patch
|
||||
Patch1: 0001-fix-build-with-gcc-10.patch
|
||||
Patch2: 0001-Fix-possible-crash-when-using-openssl-for-digital-si.patch
|
||||
|
||||
%description
|
||||
MuPDF is a lightweight PDF viewer and toolkit written in portable C.
|
||||
@ -56,6 +57,7 @@ do
|
||||
done
|
||||
%patch0 -p1 -d thirdparty/lcms2
|
||||
%patch1 -p1 -d thirdparty/freeglut
|
||||
%patch2 -p1
|
||||
echo > user.make "\
|
||||
USE_SYSTEM_FREETYPE := yes
|
||||
USE_SYSTEM_HARFBUZZ := yes
|
||||
@ -102,6 +104,9 @@ cd %{buildroot}/%{_bindir} && ln -s %{name}-x11 %{name}
|
||||
%{_libdir}/lib%{name}*.a
|
||||
|
||||
%changelog
|
||||
* Sun May 31 2020 Michael J Gruber <mjg@fedoraproject.org> - 1.17.0-2
|
||||
- fix signature check crash
|
||||
|
||||
* Mon May 11 2020 Michael J Gruber <mjg@fedoraproject.org> - 1.17.0-1
|
||||
- rebase to 1.17.0 (bz #1831652)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user