aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/sunrpc/svcauth.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/sunrpc/svcauth.h')
-rw-r--r--include/linux/sunrpc/svcauth.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/include/linux/sunrpc/svcauth.h b/include/linux/sunrpc/svcauth.h
index 548790e9113b..dd74084a9799 100644
--- a/include/linux/sunrpc/svcauth.h
+++ b/include/linux/sunrpc/svcauth.h
@@ -15,14 +15,23 @@
15#include <linux/sunrpc/msg_prot.h> 15#include <linux/sunrpc/msg_prot.h>
16#include <linux/sunrpc/cache.h> 16#include <linux/sunrpc/cache.h>
17#include <linux/hash.h> 17#include <linux/hash.h>
18#include <linux/cred.h>
18 19
19#define SVC_CRED_NGROUPS 32
20struct svc_cred { 20struct svc_cred {
21 uid_t cr_uid; 21 uid_t cr_uid;
22 gid_t cr_gid; 22 gid_t cr_gid;
23 struct group_info *cr_group_info; 23 struct group_info *cr_group_info;
24 u32 cr_flavor; /* pseudoflavor */
25 char *cr_principal; /* for gss */
24}; 26};
25 27
28static inline void free_svc_cred(struct svc_cred *cred)
29{
30 if (cred->cr_group_info)
31 put_group_info(cred->cr_group_info);
32 kfree(cred->cr_principal);
33}
34
26struct svc_rqst; /* forward decl */ 35struct svc_rqst; /* forward decl */
27struct in6_addr; 36struct in6_addr;
28 37
@@ -131,7 +140,7 @@ extern struct auth_domain *auth_domain_lookup(char *name, struct auth_domain *ne
131extern struct auth_domain *auth_domain_find(char *name); 140extern struct auth_domain *auth_domain_find(char *name);
132extern struct auth_domain *auth_unix_lookup(struct net *net, struct in6_addr *addr); 141extern struct auth_domain *auth_unix_lookup(struct net *net, struct in6_addr *addr);
133extern int auth_unix_forget_old(struct auth_domain *dom); 142extern int auth_unix_forget_old(struct auth_domain *dom);
134extern void svcauth_unix_purge(void); 143extern void svcauth_unix_purge(struct net *net);
135extern void svcauth_unix_info_release(struct svc_xprt *xpt); 144extern void svcauth_unix_info_release(struct svc_xprt *xpt);
136extern int svcauth_unix_set_client(struct svc_rqst *rqstp); 145extern int svcauth_unix_set_client(struct svc_rqst *rqstp);
137 146