summaryrefslogtreecommitdiff
path: root/tirpc/rpc/svc_auth.h
diff options
context:
space:
mode:
Diffstat (limited to 'tirpc/rpc/svc_auth.h')
-rw-r--r--tirpc/rpc/svc_auth.h18
1 files changed, 12 insertions, 6 deletions
diff --git a/tirpc/rpc/svc_auth.h b/tirpc/rpc/svc_auth.h
index 659e90c..14269d1 100644
--- a/tirpc/rpc/svc_auth.h
+++ b/tirpc/rpc/svc_auth.h
@@ -44,17 +44,23 @@
/*
* Interface to server-side authentication flavors.
*/
-typedef struct {
+typedef struct SVCAUTH {
struct svc_auth_ops {
- int (*svc_ah_wrap)(void);
- int (*svc_ah_unwrap)(void);
- int (*svc_ah_destroy)(void);
+ int (*svc_ah_wrap)(struct SVCAUTH *, XDR *, xdrproc_t,
+ caddr_t);
+ int (*svc_ah_unwrap)(struct SVCAUTH *, XDR *, xdrproc_t,
+ caddr_t);
+ int (*svc_ah_destroy)(struct SVCAUTH *);
} *svc_ah_ops;
caddr_t svc_ah_private;
} SVCAUTH;
-#define SVCAUTH_DESTROY(cred) ((*(cred)->svc_ah_ops->svc_ah_destroy)())
-#define svcauth_destroy(cred) ((*(cred)->svc_ah_ops->svc_ah_destroy)())
+#define SVCAUTH_WRAP(auth, xdrs, xfunc, xwhere) \
+ ((*((auth)->svc_ah_ops->svc_ah_wrap))(auth, xdrs, xfunc, xwhere))
+#define SVCAUTH_UNWRAP(auth, xdrs, xfunc, xwhere) \
+ ((*((auth)->svc_ah_ops->svc_ah_unwrap))(auth, xdrs, xfunc, xwhere))
+#define SVCAUTH_DESTROY(auth) \
+ ((*((auth)->svc_ah_ops->svc_ah_destroy))(auth))
/*
* Server side authenticator