Merged update from upstream sources

This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/opensc.git#c6440704de7b51ec42ac85c639781e3cbc507cdc
This commit is contained in:
DistroBaker 2020-11-24 17:30:09 +00:00
parent 00829f6305
commit b2e46fb419
6 changed files with 12 additions and 1401 deletions

1
.gitignore vendored
View File

@ -7,3 +7,4 @@
/opensc-0.18.0.tar.gz
/opensc-0.19.0.tar.gz
/opensc-0.20.0.tar.gz
/opensc-0.21.0.tar.gz

File diff suppressed because it is too large Load Diff

View File

@ -1,24 +0,0 @@
From 8551e84d74af24638581a473775b71e6aad10dcf Mon Sep 17 00:00:00 2001
From: Frank Morgner <frankmorgner@gmail.com>
Date: Wed, 4 Mar 2020 23:09:57 +0100
Subject: [PATCH] fixed https://github.com/OpenSC/OpenSC/issues/1948
closes https://github.com/OpenSC/OpenSC/pull/1958
---
src/tests/p11test/p11test_case_pss_oaep.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/tests/p11test/p11test_case_pss_oaep.c b/src/tests/p11test/p11test_case_pss_oaep.c
index 0194711924..b114b73658 100644
--- a/src/tests/p11test/p11test_case_pss_oaep.c
+++ b/src/tests/p11test/p11test_case_pss_oaep.c
@@ -376,7 +376,7 @@ int oaep_encrypt_decrypt_test(test_cert_t *o, token_info_t *info, test_mech_t *m
CK_BYTE *dec_message = NULL;
int dec_message_length = 0;
int message_length = 16;
- unsigned char *enc_message;
+ unsigned char *enc_message = NULL;
int enc_message_length, rv;
if (o->private_handle == CK_INVALID_HANDLE) {

View File

@ -1,27 +0,0 @@
diff --git a/src/tests/p11test/p11test.c b/src/tests/p11test/p11test.c
index feecf6fb..a16282cb 100644
--- a/src/tests/p11test/p11test.c
+++ b/src/tests/p11test/p11test.c
@@ -34,6 +34,9 @@
#define DEFAULT_P11LIB "../../pkcs11/.libs/opensc-pkcs11.so"
+/* Global variable keeping information about token we are using */
+token_info_t token;
+
void display_usage() {
fprintf(stdout,
" Usage:\n"
diff --git a/src/tests/p11test/p11test_common.h b/src/tests/p11test/p11test_common.h
index 2f3b238d..9eb5cede 100644
--- a/src/tests/p11test/p11test_common.h
+++ b/src/tests/p11test/p11test_common.h
@@ -84,7 +84,7 @@ typedef struct {
size_t num_keygen_mechs;
} token_info_t;
-token_info_t token;
+extern token_info_t token;
#endif /* P11TEST_COMMON_H */

View File

@ -2,8 +2,8 @@
%define nssdb %{_sysconfdir}/pki/nssdb
Name: opensc
Version: 0.20.0
Release: 9%{?dist}
Version: 0.21.0
Release: 1%{?dist}
Summary: Smart card library and applications
License: LGPLv2+
@ -14,11 +14,6 @@ Source1: opensc.module
# https://github.com/OpenSC/OpenSC/blob/master/tests/common.sh
Source2: common.sh
Patch1: opensc-0.19.0-pinpad.patch
Patch2: opensc-0.20.0-no-common.patch
# https://github.com/OpenSC/OpenSC/pull/1987
Patch3: opensc-0.20.0-cardos.patch
# https://github.com/OpenSC/OpenSC/commit/8551e84d
Patch4: opensc-0.20.0-lto-build.patch
Patch5: %{name}-gcc11.patch
BuildRequires: pcsc-lite-devel
@ -56,9 +51,6 @@ every software/card that does so, too.
%prep
%setup -q
%patch1 -p1 -b .pinpad
%patch2 -p1 -b .no-common
%patch3 -p1 -b .cardos
%patch4 -p1 -b .lto-build
%patch5 -p1 -b .gcc11
cp %{SOURCE2} tests/
@ -132,6 +124,10 @@ rm -rf %{buildroot}%{_datadir}/bash-completion/
rm -rf %{buildroot}%{_bindir}/npa-tool
rm -rf %{buildroot}%{_mandir}/man1/npa-tool.1*
# the pkcs11-register is not applicable to Fedora/RHEL where we use p11-kit
rm -rf %{buildroot}%{_bindir}/pkcs11-register
rm -rf %{buildroot}%{_mandir}/man1/pkcs11-register.1*
# Remove the notification files
rm %{buildroot}%{_bindir}/opensc-notify
rm %{buildroot}%{_datadir}/applications/org.opensc.notify.desktop
@ -177,7 +173,6 @@ rm %{buildroot}%{_mandir}/man1/opensc-notify.1*
%{_bindir}/westcos-tool
%{_bindir}/egk-tool
%{_bindir}/goid-tool
%{_bindir}/pkcs11-register
%{_libdir}/lib*.so.*
%{_libdir}/opensc-pkcs11.so
%{_libdir}/pkcs11-spy.so
@ -191,6 +186,7 @@ rm %{buildroot}%{_mandir}/man1/opensc-notify.1*
%{_mandir}/man1/cryptoflex-tool.1*
%{_mandir}/man1/eidenv.1*
%{_mandir}/man1/gids-tool.1*
%{_mandir}/man1/goid-tool.1*
%{_mandir}/man1/iasecc-tool.1*
%{_mandir}/man1/netkey-tool.1*
%{_mandir}/man1/openpgp-tool.1*
@ -210,6 +206,9 @@ rm %{buildroot}%{_mandir}/man1/opensc-notify.1*
%changelog
* Tue Nov 24 2020 Jakub Jelen <jjelen@redhat.com> - 0.21.0-1
- New upstream release (#1884886)
* Fri Oct 30 2020 Jeff Law <law@redhat.com> - 0.20.0-9
- Fix potentially uninitialized array reference exposed by gcc-11

View File

@ -1 +1 @@
SHA512 (opensc-0.20.0.tar.gz) = 71f71fa6062410e63c6c60f5b2d10d1d855cc6cc815ef0e42e42a1ddd25bbd52fc396c1e495ef54610f3243996dec84dacc8007b186deb670ed645b04ee6eda5
SHA512 (opensc-0.21.0.tar.gz) = 3511b0a04a96e62011c48667e3fd36a1611fe67a89f7626ff056c9c3614f8cabc91c9924a6ca7a8ea50076a128e3967277a0dd624b4fa27c62cefee9fab22646