From: Mark Goodman <mgoodman@CSUA.Berkeley.EDU>
To: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] Make locks work on NFS3 krb5 mounts
Date: Thu, 23 Sep 2004 13:48:26 -0700 [thread overview]
Message-ID: <4153369A.2030804@csua.berkeley.edu> (raw)
This patch makes locks work on NFS3 krb5 mounts. In particular, it makes
gconf-sanity-check-1 succeed when my home directory is a NFS3 krb5
mount. gconf-sanity-check-1 is part of GConf. It applies to 2.6.9-rc2.
Please consider applying.
Signed-off-by: Mark Goodman <mgoodman@csua.berkeley.edu>
--- linux-2.6.9-rc2/net/sunrpc/clnt.c.orig 2004-09-12
22:32:17.000000000 -0700
+++ linux-2.6.9-rc2/net/sunrpc/clnt.c 2004-09-23 13:35:12.028606648 -0700
@@ -425,6 +425,16 @@ rpc_call_setup(struct rpc_task *task, st
{
task->tk_msg = *msg;
task->tk_flags |= flags;
+
+ /*
+ * For a nfs3 krb5 mount, lockd tries to use a RPCSEC cred with UNIX
+ * auth. If that's the case, get a UNIX cred.
+ */
+ if (task->tk_msg.rpc_cred != NULL &&
+ task->tk_msg.rpc_cred->cr_auth->au_ops != task->tk_auth->au_ops) {
+ task->tk_msg.rpc_cred = NULL;
+ }
+
/* Bind the user cred */
if (task->tk_msg.rpc_cred != NULL) {
rpcauth_holdcred(task);
reply other threads:[~2004-09-23 20:55 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=4153369A.2030804@csua.berkeley.edu \
--to=mgoodman@csua.berkeley.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=trond.myklebust@fys.uio.no \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.