aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/sunrpc/svcsock.h
diff options
context:
space:
mode:
authorTrond Myklebust <trondmy@gmail.com>2019-04-09 12:13:37 -0400
committerJ. Bruce Fields <bfields@redhat.com>2019-04-24 09:46:35 -0400
commit4df493a260d4c1844437b28009013d5dc408d0df (patch)
tree82fe51b97a8743281bbf7d40cdbeef9af50614bf /include/linux/sunrpc/svcsock.h
parentnfsd: Allow containers to set supported nfs versions (diff)
downloadlinux-dev-4df493a260d4c1844437b28009013d5dc408d0df.tar.xz
linux-dev-4df493a260d4c1844437b28009013d5dc408d0df.zip
SUNRPC: Cache the process user cred in the RPC server listener
In order to be able to interpret uids and gids correctly in knfsd, we should cache the user namespace of the process that created the RPC server's listener. To do so, we refcount the credential of that process. Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'include/linux/sunrpc/svcsock.h')
-rw-r--r--include/linux/sunrpc/svcsock.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/sunrpc/svcsock.h b/include/linux/sunrpc/svcsock.h
index 119718a922f2..771baadaee9d 100644
--- a/include/linux/sunrpc/svcsock.h
+++ b/include/linux/sunrpc/svcsock.h
@@ -59,7 +59,8 @@ void svc_drop(struct svc_rqst *);
void svc_sock_update_bufs(struct svc_serv *serv);
bool svc_alien_sock(struct net *net, int fd);
int svc_addsock(struct svc_serv *serv, const int fd,
- char *name_return, const size_t len);
+ char *name_return, const size_t len,
+ const struct cred *cred);
void svc_init_xprt_sock(void);
void svc_cleanup_xprt_sock(void);
struct svc_xprt *svc_sock_create(struct svc_serv *serv, int prot);