linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Justin Mitchell <jumitche@redhat.com>
To: Matthias Gerstner <matthias.gerstner@nefkom.net>
Cc: linux-nfs@vger.kernel.org
Subject: Re: nfs-utils: rpc.svcgssd segmentation fault in nss_gss_princ_to_ids()
Date: Wed, 21 Feb 2018 16:49:01 +0000	[thread overview]
Message-ID: <1519231741.7497.18.camel@redhat.com> (raw)
In-Reply-To: <20180220224858.GA14972@q910.gerrit.home>

On Tue, 2018-02-20 at 23:48 +0100, Matthias Gerstner wrote:
> Hello!
> 
> I hope I have found the right place to report this.
> 
> I have recently upgraded from nfs-utils-1.3.4 to nfs-utils-2.3.1 on a Gentoo
> Linux (hardened) system. After this upgrade the rpc.svcgssd crashes on my
> kerberized NFS server each time a client tries to mount an NFS export.
<snip>
>   
> I debugged this a bit and strange things came about. There seem to be
> duplicate instances of the local_realms variable in the
> support/nfsidmap/nfsidmap_common.c compilation unit:
<snip>
> So there's one instance of the variable that was actually assigned the
> expected data. And there's another one that is at NULL and returned from
> get_local_realms().
> 
> This is related to the "#pragma GCC visibility push(hidden)" in the
> compilation unit. Moving it after the local_realms variable declaration fixes
> the issue. I've attached a patch that does just this.
> 
> I am not quite sure whether this is a compiler issue or an invalid use of the
> visibility hidden pragma. The compiler used is:

This is part of my previous work to fold libnfsidmap into the nfs-utils
tree, in this case the #pragma is used to make the local_realms global
accessible only by other parts of the library that need it, external
users such as the nss plugin get access to it via the get_local_realms()
function.

I will run some tests to see if this is isolated to certain compiler
versions, or if the pragma isnt working as I expected.

However simply moving the #pragma hidden will change the ABI which is a
problem for some, so if necessary I will instead reorganise the code to
achieve the same functionality without using the pragma


  parent reply	other threads:[~2018-02-21 16:49 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-20 22:48 nfs-utils: rpc.svcgssd segmentation fault in nss_gss_princ_to_ids() Matthias Gerstner
2018-02-21 16:08 ` Steve Dickson
2018-02-22  8:17   ` Matthias Gerstner
2018-02-21 16:49 ` Justin Mitchell [this message]
2018-02-22  8:18   ` Matthias Gerstner
2018-02-22 23:10   ` matthias.gerstner

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=1519231741.7497.18.camel@redhat.com \
    --to=jumitche@redhat.com \
    --cc=linux-nfs@vger.kernel.org \
    --cc=matthias.gerstner@nefkom.net \
    /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;
as well as URLs for NNTP newsgroup(s).