File configure-check-for-rpc_gss_seccreate.patch of Package nfs-utils

From: Olga Kornievskaia <kolga@netapp.com>
Date: Mon, 11 Dec 2023 08:59:43 -0500
Subject: configure: check for rpc_gss_seccreate
Git-repo: git://git.linux-nfs.org/projects/steved/nfs-utils.git
Git-commit: 49567e7d03a5605c590be2135a24d4de8345fa3c
References: CVE-2025-12801 bsc#1259204

If we have rpc_gss_sccreate in tirpc library define
HAVE_TIRPC_GSS_SECCREATE, which would allow us to handle bad_integrity
errors.

Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Olga Kornievskaia <kolga@netapp.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
Acked-by: Anthony Iliopoulos <ailiop@suse.com>
---
 aclocal/libtirpc.m4 | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/aclocal/libtirpc.m4 b/aclocal/libtirpc.m4
index bddae0226931..ef48a2aee238 100644
--- a/aclocal/libtirpc.m4
+++ b/aclocal/libtirpc.m4
@@ -26,6 +26,11 @@ AC_DEFUN([AC_LIBTIRPC], [
                                     [Define to 1 if your tirpc library provides libtirpc_set_debug])],,
                          [${LIBS}])])
 
+     AS_IF([test -n "${LIBTIRPC}"],
+           [AC_CHECK_LIB([tirpc], [rpc_gss_seccreate],
+                         [AC_DEFINE([HAVE_TIRPC_GSS_SECCREATE], [1],
+                                    [Define to 1 if your tirpc library provides rpc_gss_seccreate])],,
+                         [${LIBS}])])
   AC_SUBST([AM_CPPFLAGS])
   AC_SUBST(LIBTIRPC)
 

openSUSE Build Service is sponsored by