From 2876e5e6f061f15cbbe565276549c51c6c4d01ea Mon Sep 17 00:00:00 2001 From: Paul Howarth Date: Fri, 25 Nov 2016 08:57:19 +0000 Subject: [PATCH] Fix segfault in SSL handling that manifests on OpenSSL 1.1.0 x86_64 (CPAN RT#118584, RHBZ#1390468) --- AnyEvent-7.13-ssl.patch | 13 +++++++++++++ perl-AnyEvent.spec | 21 ++++++++++----------- 2 files changed, 23 insertions(+), 11 deletions(-) create mode 100644 AnyEvent-7.13-ssl.patch diff --git a/AnyEvent-7.13-ssl.patch b/AnyEvent-7.13-ssl.patch new file mode 100644 index 0000000..b06208b --- /dev/null +++ b/AnyEvent-7.13-ssl.patch @@ -0,0 +1,13 @@ +Fix for CPAN RT#118584 from Mike McCauley (Net::SSLeay upstream) + +--- lib/AnyEvent/Handle.pm ++++ lib/AnyEvent/Handle.pm +@@ -2224,7 +2224,7 @@ sub starttls { + # Net::SSLeay::CTX_set_mode ($ssl, + # (eval { local $SIG{__DIE__}; Net::SSLeay::MODE_ENABLE_PARTIAL_WRITE () } || 1) + # | (eval { local $SIG{__DIE__}; Net::SSLeay::MODE_ACCEPT_MOVING_WRITE_BUFFER () } || 2)); +- Net::SSLeay::CTX_set_mode ($tls, 1|2); ++ Net::SSLeay::set_mode ($tls, 1|2); + + $self->{_rbio} = Net::SSLeay::BIO_new (Net::SSLeay::BIO_s_mem ()); + $self->{_wbio} = Net::SSLeay::BIO_new (Net::SSLeay::BIO_s_mem ()); diff --git a/perl-AnyEvent.spec b/perl-AnyEvent.spec index cb9ce58..8b63b8b 100644 --- a/perl-AnyEvent.spec +++ b/perl-AnyEvent.spec @@ -6,17 +6,15 @@ # Use weak dependencies where available %global have_weak_deps 0%{?fedora} > 20 || 0%{?rhel} > 7 -# SSL in Rawhide is currently flaky, probably due to pulling in a mix of OpenSSL versions -%global flaky_ssl 0%{?fedora} == 26 - Name: perl-AnyEvent Version: 7.13 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Framework for multiple event loops Group: Development/Libraries License: GPL+ or Artistic URL: http://search.cpan.org/dist/AnyEvent/ Source0: http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/AnyEvent-%{version}%{?subver}.tar.gz +Patch0: AnyEvent-7.13-ssl.patch # Build requirements BuildRequires: coreutils @@ -52,11 +50,7 @@ BuildRequires: perl(Unicode::Normalize) # Test suite requirements BuildRequires: perl(File::Spec) -%if !(%flaky_ssl) BuildRequires: perl(Net::SSLeay) >= 1.33 -%else -BuildConflicts: perl-Net-SSLeay -%endif BuildRequires: perl(Test::More) BuildRequires: perl(utf8) BuildRequires: perl(warnings) @@ -75,9 +69,7 @@ BuildRequires: perl(Glib) >= 1.210 BuildRequires: perl(POE) >= 1.312 BuildRequires: perl(Tk) %if 0%{?fedora} -%if !(%flaky_ssl) BuildRequires: perl(AnyEvent::AIO) -%endif BuildRequires: perl(EV) >= 4.00 BuildRequires: perl(IO::AIO) >= 4.13 BuildRequires: perl(IO::Async::Loop) >= 0.33 @@ -146,6 +138,9 @@ time). %prep %setup -q -n AnyEvent-%{version}%{?subver} +# Fix segfault in SSL handling that manifests on OpenSSL 1.1.0 x86_64 +%patch0 + %build PERL_CANARY_STABILITY_NOPROMPT=1 perl Makefile.PL INSTALLDIRS=vendor @@ -202,8 +197,12 @@ make test %changelog +* Fri Nov 25 2016 Paul Howarth - 7.13-4 +- Fix segfault in SSL handling that manifests on OpenSSL 1.1.0 x86_64 + (CPAN RT#118584, RHBZ#1390468) + * Tue Nov 1 2016 Paul Howarth - 7.13-3 -- Avoid interactive prompt duing build (#1390463) +- Avoid interactive prompt during build (#1390463) - For now, BuildConflict with perl-Net-SSLeay on Rawhide (#1390468) * Mon Oct 17 2016 Paul Howarth - 7.13-2