Fix comparison of OID structure

This commit is contained in:
Jitka Plesnikova 2021-08-18 10:30:01 +02:00
parent 229573135a
commit 566beff54e
2 changed files with 58 additions and 9 deletions

View File

@ -0,0 +1,35 @@
From 4b213b1f0c9681f74d12f991db008f1d891d7447 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michal=20Josef=20=C5=A0pa=C4=8Dek?= <mspacek@redhat.com>
Date: Mon, 16 Aug 2021 15:30:50 +0200
Subject: [PATCH] Fix comparison of OID structure
---
xs/OID.xs | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/xs/OID.xs b/xs/OID.xs
index c805e45..7c2a4ba 100644
--- a/xs/OID.xs
+++ b/xs/OID.xs
@@ -15,12 +15,12 @@ DESTROY(oid)
PPCODE:
#if !defined(HEIMDAL)
if (oid != NULL &&
- oid != __KRB5_MECHTYPE_OID &&
- oid != __KRB5_OLD_MECHTYPE_OID &&
- oid != __GSS_KRB5_NT_USER_NAME &&
- oid != __GSS_KRB5_NT_PRINCIPAL_NAME &&
- oid != __SPNEGO_MECHTYPE_OID &&
- oid != __gss_mech_krb5_v2 ) {
+ ! gss_oid_equal(oid, __KRB5_MECHTYPE_OID) &&
+ ! gss_oid_equal(oid, __KRB5_OLD_MECHTYPE_OID) &&
+ ! gss_oid_equal(oid, __GSS_KRB5_NT_USER_NAME) &&
+ ! gss_oid_equal(oid, __GSS_KRB5_NT_PRINCIPAL_NAME) &&
+ ! gss_oid_equal(oid, __SPNEGO_MECHTYPE_OID) &&
+ ! gss_oid_equal(oid, __gss_mech_krb5_v2) ) {
(void)gss_release_oid(&minor, &oid);
}
#endif
--
2.31.1

View File

@ -6,28 +6,38 @@
Name: perl-GSSAPI
Version: 0.28
Release: 35%{?dist}
Release: 36%{?dist}
Summary: Perl extension providing access to the GSSAPIv2 library
License: GPL+ or Artistic
URL: https://metacpan.org/release/GSSAPI
Source0: https://cpan.metacpan.org/authors/id/A/AG/AGROLMS/GSSAPI-%{version}.tar.gz
BuildRequires: make
# Fix comparison of OID structure (CPAN RT#121873)
Patch0: GSSAPI-0.28-Fix-comparison-of-OID-structure.patch
BuildRequires: coreutils
BuildRequires: findutils
BuildRequires: gcc
BuildRequires: krb5-devel
BuildRequires: which
%{?_with_testsuite:BuildRequires: perl(constant)}
%{?_with_testsuite:BuildRequires: perl(Carp)}
%{?_with_testsuite:BuildRequires: perl(Exporter)}
BuildRequires: make
BuildRequires: perl-devel
BuildRequires: perl-generators
BuildRequires: perl-interpreter
BuildRequires: perl(Config)
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76
%{?_with_testsuite:BuildRequires: perl(ExtUtils::testlib)}
BuildRequires: perl(Getopt::Long)
%{?_with_testsuite:BuildRequires: perl(Test::More)}
%{?_with_testsuite:BuildRequires: perl(Test::Pod) >= 1.00}
BuildRequires: perl(strict)
BuildRequires: which
# Run-time
%{?_with_testsuite:BuildRequires: perl(Carp)}
%{?_with_testsuite:BuildRequires: perl(constant)}
%{?_with_testsuite:BuildRequires: perl(Exporter)}
%{?_with_testsuite:BuildRequires: perl(overload)}
%{?_with_testsuite:BuildRequires: perl(warnings)}
%{?_with_testsuite:BuildRequires: perl(XSLoader)}
# Tests
%{?_with_testsuite:BuildRequires: perl(ExtUtils::testlib)}
%{?_with_testsuite:BuildRequires: perl(Test::More)}
# Optional tests
%{?_with_testsuite:BuildRequires: perl(Test::Pod) >= 1.00}
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
%description
@ -37,6 +47,7 @@ distribution from MIT.
%prep
%setup -q -n GSSAPI-%{version}
%patch0 -p1
chmod -c a-x examples/*.pl
%build
@ -59,6 +70,9 @@ find %{buildroot} -type f -name '*.bs' -empty -delete
%{_mandir}/man3/*
%changelog
* Mon Aug 16 2021 Jitka Plesnikova <jplesnik@redhat.com> - 0.28-36
- Fix comparison of OID structure
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.28-35
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild