public inbox for linux-nfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Chuck Lever <chuck.lever@oracle.com>
To: Steve Dickson <steved@redhat.com>
Cc: Olga Kornievskaia <olga.kornievskaia@gmail.com>,
	linux-nfs@vger.kernel.org
Subject: Re: [PATCH 6/6] configure: check for rpc_gss_seccreate
Date: Fri, 8 Dec 2023 10:22:24 -0500	[thread overview]
Message-ID: <ZXM0sJ7SOqlkurlf@tissot.1015granger.net> (raw)
In-Reply-To: <687d51fc-fc87-40a1-80c8-9261fcb8dd7a@redhat.com>

On Fri, Dec 08, 2023 at 10:01:29AM -0500, Steve Dickson wrote:
> 
> 
> On 12/8/23 9:26 AM, Olga Kornievskaia wrote:
> > On Thu, Dec 7, 2023 at 5:27 PM Chuck Lever <chuck.lever@oracle.com> wrote:
> > > 
> > > On Thu, Dec 07, 2023 at 05:21:50PM -0500, Olga Kornievskaia wrote:
> > > > On Thu, Dec 7, 2023 at 9:44 AM Chuck Lever <chuck.lever@oracle.com> wrote:
> > > > > 
> > > > > On Wed, Dec 06, 2023 at 04:33:32PM -0500, Olga Kornievskaia wrote:
> > > > > > From: Olga Kornievskaia <kolga@netapp.com>
> > > > > > 
> > > > > > If we have rpc_gss_sccreate in tirpc library define
> > > > > > HAVE_TIRPC_GSS_SECCREATE, which would allow us to handle bad_integrity
> > > > > > errors.
> > > > > > 
> > > > > > Signed-off-by: Olga Kornievskaia <kolga@netapp.com>
> > > > > > ---
> > > > > >   aclocal/libtirpc.m4 | 5 +++++
> > > > > >   1 file changed, 5 insertions(+)
> > > > > > 
> > > > > > diff --git a/aclocal/libtirpc.m4 b/aclocal/libtirpc.m4
> > > > > > index bddae022..ef48a2ae 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)
> > > > > 
> > > > > It would be better for distributors if this checked that the local
> > > > > version of libtirpc has the rpc_gss_seccreate fix that you sent.
> > > > > The PKG_CHECK_MODULES macro should work for that, once you know the
> > > > > version number of libtirpc that will have that fix.
> > > > > 
> > > > > Also, this patch should come either before "gssd: switch to using
> > > > > rpc_gss_seccreate()" or this change should be squashed into that
> > > > > patch, IMO.
> > > > 
> > > > I can certainly re-arrange the order (if Steve wants me to re-send an
> > > > ordered list).  I attempted to address your comment to  check for
> > > > existence of the function or fallback to the old way.
> > > 
> > > A comment that I made when I thought no changes to rpc_gss_seccreate(3t)
> > > would be needed.... But you found and fixed a bug there.
> > > 
> > > 
> > > > I'm not sure I'm
> > > > capable of producing something that depends on distro versioning (or
> > > > am I supposed to be)?
> > > 
> > > I think this series truly needs to check the libtirpc version.
> > > Otherwise the build will complete successfully, gssd will use
> > > rpc_gss_seccreate(), but it will be broken.
> > > 
> > > Grep for PKG_CHECK_MODULES in the other files in aclocal/ and you
> > > should find a pattern to use.
> > 
> > Yes but I won't know the version number of libtirpc (version or rpm
> > package) for which to check? It seems like libtirpc changes needs to
> > be checked in (btw I'm assuming a new version would need to be
> > generated), then (if that's it or libtirpc version and package version
> > are different things there might be more) this particular patch could
> > be generated. Isn't that correct?

1. Commit the reverts to nfs-utils, and cut a release. This enables
   nfs-utils to build everywhere again -- it addresses an immediate
   bug.

2. Commit your libtirpc patches, and cut a release. This fixes the
   ABI issue in libtirpc, and you now have a known-good library
   release version number to use.

3. Update the libtirpc aclocal check in nfs-utils to use that
   version number, and commit the rest of your fixes. This fix will
   then appear in the next nfs-utils release.


> > Steve, I could really use your guidance on steps to be done here.
> Again... The versions "on who is on first and what is on second" :-)
> Is not an upstream problem... It is a distro problem...

I think distros will be less likely to upgrade if there are LEGO
blocks laying on the floor that they accidentally step on. And my
impression is that distros want the config to break rather than
that hidden bugs leak into their production builds.

This is clearly something upstream can flag, and we should because
otherwise, the breakage can be silent or frustrating to debug. This
is a security issue, really, since it directly involves gssd.

I mean, why bother to have all of the autoconf machinery if upstream
doesn't care about checking library versions?


> Let me take a closer look...
> 
> > 
> > Thank you.
> > 
> > > 
> > > 
> > > > I think this goes back to me hoping that a
> > > > distro would create matching set of libtirpc and nfs-utils rpms...
> We do... upstream creates tar balls... distros create rpm
> that have requirements for certain versions of things.

That is typically the case. I'm concerned about the few times
it isn't, or if there are testing gaps.


-- 
Chuck Lever

  reply	other threads:[~2023-12-08 15:22 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-06 21:33 [PATCH 0/6] nfs-utils: handle BAD_INTEGRITY ERROR Olga Kornievskaia
2023-12-06 21:33 ` [PATCH 1/6] gssd: revert commit a5f3b7ccb01c Olga Kornievskaia
2024-01-04 14:52   ` Petr Vorel
2023-12-06 21:33 ` [PATCH 2/6] gssd: revert commit 513630d720bd Olga Kornievskaia
2024-01-04 14:46   ` Petr Vorel
2023-12-06 21:33 ` [PATCH 3/6] gssd: switch to using rpc_gss_seccreate() Olga Kornievskaia
2023-12-06 21:33 ` [PATCH 4/6] gssd: handle KRB5_AP_ERR_BAD_INTEGRITY for machine credentials Olga Kornievskaia
2023-12-06 21:33 ` [PATCH 5/6] gssd: handle KRB5_AP_ERR_BAD_INTEGRITY for user credentials Olga Kornievskaia
2023-12-06 21:33 ` [PATCH 6/6] configure: check for rpc_gss_seccreate Olga Kornievskaia
2023-12-07 14:44   ` Chuck Lever
2023-12-07 22:21     ` Olga Kornievskaia
2023-12-07 22:27       ` Chuck Lever
2023-12-08 14:26         ` Olga Kornievskaia
2023-12-08 15:01           ` Steve Dickson
2023-12-08 15:22             ` Chuck Lever [this message]
2023-12-08 14:54     ` Steve Dickson
2023-12-07 14:50 ` [PATCH 0/6] nfs-utils: handle BAD_INTEGRITY ERROR Chuck Lever
2024-01-04  0:38 ` Steve Dickson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZXM0sJ7SOqlkurlf@tissot.1015granger.net \
    --to=chuck.lever@oracle.com \
    --cc=linux-nfs@vger.kernel.org \
    --cc=olga.kornievskaia@gmail.com \
    --cc=steved@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox