libtirpc: Add detection for new rpc_gss_sec members
Subsystems (2)
PATCH 1/1 libtirpc: Add detection for new rpc_gss_sec members
From: Petr Vorel <[email protected]>
4b272471 started to use struct rpc_gss_sec member minor_status, which was added in new libtirpc 1.3.4. Add check for the member to prevent failure on older libtirpc headers.
--- aclocal/libtirpc.m4 | 4 ++++ 1 file changed, 4 insertions(+)
aclocal/libtirpc.m4 +4 -0
@@ -25,6 +25,10 @@ AC_DEFUN([AC_LIBTIRPC], [ [AC_DEFINE([HAVE_LIBTIRPC_SET_DEBUG], [1], [Define to 1 if your tirpc library provides libtirpc_set_debug])],, [${LIBS}])]) + AS_IF([test "$enable_gss" = "yes"], + [AC_CHECK_MEMBER(struct rpc_gss_sec.minor_status,, + [AC_MSG_ERROR([Missing rpc_gss_sec.minor_status in <rpc/auth_gss.h>, update libtirpc or run with --disable-gss])], + [#include <rpc/auth_gss.h>])]) AC_SUBST([AM_CPPFLAGS]) AC_SUBST(LIBTIRPC)
Signature · 1 line
2.42.0
Hello,
Quoted 19 lines · Petr Vorel
From: Petr Vorel<[email protected]>
4b272471started to use structrpc_gss_secmemberminor_status, which was added in new libtirpc 1.3.4. Add check for the member to prevent failure on older libtirpc headers.Fixes 4b272471 ("gssd: handle KRB5_AP_ERR_BAD_INTEGRITY for machine credentials")Signed-off-by Petr Vorel<[email protected]>--- aclocal/libtirpc.m4 | 4 ++++ 1 file changed, 4 insertions(+)aclocal/libtirpc.m4 +0
-0@@ -25,6 +25,10 @@ AC_DEFUN([AC_LIBTIRPC], [ [AC_DEFINE([HAVE_LIBTIRPC_SET_DEBUG], [1],
aclocal/libtirpc.m4 AC_DEFUN([AC_LIBTIRPC], [
Quoted 10 lines
aclocal/libtirpc.m4 +4
-1[Define to 1 if your tirpc library provides libtirpc_set_debug])],, [${LIBS}])]) + AS_IF([test "$enable_gss" = "yes"], + [AC_CHECK_MEMBER(struct rpc_gss_sec.minor_status,, + [AC_MSG_ERROR([Missing rpc_gss_sec.minor_status in <rpc/auth_gss.h>, update libtirpc or run with --disable-gss])], + [#include <rpc/auth_gss.h>])]) AC_SUBST([AM_CPPFLAGS]) AC_SUBST(LIBTIRPC) -- 2.42.0
This does not work... since it is looking at that gssrpc/auth_gss.h instead of the tirpc/rpc/auth_gss.h so the check fails
I like the idea of having the check, but I'm not sure on how to point it in the right direction.
steved.
Hi Steve,
Thanks for having a look.
Quoted 25 lines
Hello,
Quoted 22 lines · Petr Vorel
From: Petr Vorel<[email protected]>
4b272471started to use structrpc_gss_secmemberminor_status, which was added in new libtirpc 1.3.4. Add check for the member to prevent failure on older libtirpc headers.Fixes 4b272471 ("gssd: handle KRB5_AP_ERR_BAD_INTEGRITY for machine credentials")Signed-off-by Petr Vorel<[email protected]>--- aclocal/libtirpc.m4 | 4 ++++ 1 file changed, 4 insertions(+)aclocal/libtirpc.m4 +2
-0@@ -25,6 +25,10 @@ AC_DEFUN([AC_LIBTIRPC], [ [AC_DEFINE([HAVE_LIBTIRPC_SET_DEBUG], [1], [Define to 1 if your tirpc library provides libtirpc_set_debug])],, [${LIBS}])]) + AS_IF([test "$enable_gss" = "yes"], + [AC_CHECK_MEMBER(struct rpc_gss_sec.minor_status,,
Quoted 8 lines
aclocal/libtirpc.m4 AC_DEFUN([AC_LIBTIRPC], [
Quoted 5 lines
aclocal/libtirpc.m4 +2
-1+ [AC_MSG_ERROR([Missing rpc_gss_sec.minor_status in <rpc/auth_gss.h>, update libtirpc or run with --disable-gss])], + [#include <rpc/auth_gss.h>])]) AC_SUBST([AM_CPPFLAGS]) AC_SUBST(LIBTIRPC) -- 2.42.0This does not work... since it is looking at that
gssrpc/auth_gss.hinstead of thetirpc/rpc/auth_gss.hso the check fails
Is it? There is no <gssrpc/auth_gss.h>. I suppose you test on some recent Fedora, I'll retest it.
I tested it on openSUSE Tumbleweed, where libtirpc-devel is installed into /usr/include/rpc/, thus /usr/include/rpc/auth_gss.h exists. But on Debian (and likely on RHEL/Fedora as you noticed it) is on /usr/include/tirpc/rpc/auth_gss.h.
I hoped that this is handled elsewhere via -I/usr/include/tirpc. So, I'm really confused why would have look at <gssrpc/auth_gss.h>.
Kind regards,
Petr
Quoted 4 lines
I like the idea of having the check, but I'm not sure on how to point it in the right direction.
steved.
Quoted 37 lines · Petr Vorel
Hi Steve,
Thanks for having a look.
Quoted 25 lines
Hello,
Quoted 22 lines · Petr Vorel
From: Petr Vorel<[email protected]>
4b272471started to use structrpc_gss_secmemberminor_status, which was added in new libtirpc 1.3.4. Add check for the member to prevent failure on older libtirpc headers.Fixes 4b272471 ("gssd: handle KRB5_AP_ERR_BAD_INTEGRITY for machine credentials")Signed-off-by Petr Vorel<[email protected]>--- aclocal/libtirpc.m4 | 4 ++++ 1 file changed, 4 insertions(+)aclocal/libtirpc.m4 +2
-0@@ -25,6 +25,10 @@ AC_DEFUN([AC_LIBTIRPC], [ [AC_DEFINE([HAVE_LIBTIRPC_SET_DEBUG], [1], [Define to 1 if your tirpc library provides libtirpc_set_debug])],, [${LIBS}])]) + AS_IF([test "$enable_gss" = "yes"], + [AC_CHECK_MEMBER(struct rpc_gss_sec.minor_status,,Quoted 8 lines
aclocal/libtirpc.m4 AC_DEFUN([AC_LIBTIRPC], [
Quoted 5 lines
aclocal/libtirpc.m4 +2
-1+ [AC_MSG_ERROR([Missing rpc_gss_sec.minor_status in <rpc/auth_gss.h>, update libtirpc or run with --disable-gss])], + [#include <rpc/auth_gss.h>])]) AC_SUBST([AM_CPPFLAGS]) AC_SUBST(LIBTIRPC) -- 2.42.0This does not work... since it is looking at that
gssrpc/auth_gss.hinstead of thetirpc/rpc/auth_gss.hso the check fails
Quoted 2 lines
Is it? There is no <
gssrpc/auth_gss.h>. I suppose you test on some recent Fedora, I'll retest it.
Yes... this is both an /usr/include/tirpc/rpc/auth_gss.h owned by krb5-devel and/usr/include/tirpc/rpc/auth_gss.h owned by libtirpc-devel
Quoted 5 lines
I tested it on openSUSE Tumbleweed, where libtirpc-devel is installed into
/usr/include/rpc/, thus/usr/include/rpc/auth_gss.hexists. But on Debian (and likely on RHEL/Fedora as you noticed it) is on/usr/include/tirpc/rpc/auth_gss.h.
Maybe krb5-devel was not installed??
Quoted 3 lines
I hoped that this is handled elsewhere via -I/usr/include/tirpc. So, I'm really confused why would have look at <
gssrpc/auth_gss.h>.
True, but I think -I only works during compilation, not configuration.
steved.
Quoted 9 lines
Kind regards,
PetrQuoted 4 lines
I like the idea of having the check, but I'm not sure on how to point it in the right direction.
steved.