From 2baf2b67cff85d519fe95ee46bf831f43f9b329c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppi...@redhat.com> Date: Mon, 28 Nov 2016 15:28:09 +0100 Subject: Adjust tests to libgcrypt >= 1.7
--- .rpmlint | 2 ++ ...6-Use-an-encryption-key-in-the-test-suite.patch | 31 ++++++++++++++++++++++ perl-Crypt-GCrypt.spec | 13 ++++++--- 3 files changed, 43 insertions(+), 3 deletions(-) create mode 100644 .rpmlint create mode 100644 Crypt-GCrypt-1.26-Use-an-encryption-key-in-the-test-suite.patch diff --git a/.rpmlint b/.rpmlint new file mode 100644 index 0000000..0678d90 --- /dev/null +++ b/.rpmlint @@ -0,0 +1,2 @@ +from Config import * +addFilter("spelling-error .* (cryptographic|libgcrypt)"); diff --git a/Crypt-GCrypt-1.26-Use-an-encryption-key-in-the-test-suite.patch b/Crypt-GCrypt-1.26-Use-an-encryption-key-in-the-test-suite.patch new file mode 100644 index 0000000..b5878a8 --- /dev/null +++ b/Crypt-GCrypt-1.26-Use-an-encryption-key-in-the-test-suite.patch @@ -0,0 +1,31 @@ +From cf6ef66ab447c696d465d3d1123685c2f281e8c2 Mon Sep 17 00:00:00 2001 +From: Niko Tyni <nt...@debian.org> +Date: Sat, 23 Apr 2016 16:49:57 +0300 +Subject: [PATCH] Use an encryption key in the test suite + +While encrypting without calling setkey() used to work before libgcrypt +1.7.0, this was accidental and not supported. It causes a SIGSEGV in +1.7.0 and will return an error in future versions. + +See <http://thread.gmane.org/gmane.comp.encryption.gpg.libgcrypt.devel/4487> + +Bug-Debian: https://bugs.debian.org/816104 +--- + t/01-cipher.t | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/t/01-cipher.t b/t/01-cipher.t +index 3f7de37..0bbdf0a 100644 +--- a/t/01-cipher.t ++++ b/t/01-cipher.t +@@ -102,6 +102,7 @@ ok(substr($d, 0, length $p) eq $p) + algorithm => 'aes', + padding => 'none' + ); ++ $c->setkey($key); + $c->start('encrypting'); + ok(!eval {my $e2 = $c->encrypt('aaa'); 1}); # this should die + ok(eval { my $e2 = $c->encrypt('aaaaaaaaaaaaaaaa') . $c->finish; 1 }); # this should not die +-- +2.8.0.rc3 + diff --git a/perl-Crypt-GCrypt.spec b/perl-Crypt-GCrypt.spec index db9aee7..7820555 100644 --- a/perl-Crypt-GCrypt.spec +++ b/perl-Crypt-GCrypt.spec @@ -1,6 +1,6 @@ Name: perl-Crypt-GCrypt Version: 1.26 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Perl interface to libgcrypt library License: GPL+ or Artistic Group: Development/Libraries @@ -10,8 +10,11 @@ Source0: http://www.cpan.org/authors/id/A/AA/AAR/Crypt-GCrypt-%{version}. Patch0: Crypt-GCrypt-1.26-libgcrypt_1_6_support.diff # Correct some warnings, CPAN RT#107300 Patch1: Crypt-GCrypt-1.26-Correct-some-warnings.patch +# Adjust tests to libgcrypt >= 1.7, bug #1399193, CPAN RT#112504 +Patch2: Crypt-GCrypt-1.26-Use-an-encryption-key-in-the-test-suite.patch BuildRequires: coreutils BuildRequires: findutils +BuildRequires: gcc BuildRequires: libgcrypt-devel >= 1.3.0 BuildRequires: make BuildRequires: perl @@ -48,6 +51,7 @@ Twofish, Triple DES, Arcfour etc. %setup -q -n Crypt-GCrypt-%{version} %patch0 -p0 %patch1 -p1 +%patch2 -p1 # Remove bundled modules rm -r inc sed -i -e '/^inc\//d' MANIFEST @@ -58,8 +62,8 @@ make %{?_smp_mflags} %install make pure_install DESTDIR=$RPM_BUILD_ROOT -find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} \; -find $RPM_BUILD_ROOT -type f -name '*.bs' -size 0 -exec rm -f {} \; +find $RPM_BUILD_ROOT -type f -name .packlist -delete +find $RPM_BUILD_ROOT -type f -name '*.bs' -size 0 -delete %{_fixperms} $RPM_BUILD_ROOT/* %check @@ -72,6 +76,9 @@ make test %{_mandir}/man3/* %changelog +* Mon Nov 28 2016 Petr Pisar <ppi...@redhat.com> - 1.26-4 +- Adjust tests to libgcrypt >= 1.7 (bug #1399193) + * Mon May 16 2016 Jitka Plesnikova <jples...@redhat.com> - 1.26-3 - Perl 5.24 rebuild -- cgit v0.12 http://pkgs.fedoraproject.org/cgit/perl-Crypt-GCrypt.git/commit/?h=master&id=2baf2b67cff85d519fe95ee46bf831f43f9b329c _______________________________________________ perl-devel mailing list -- perl-devel@lists.fedoraproject.org To unsubscribe send an email to perl-devel-le...@lists.fedoraproject.org