Lines Matching refs:rqstp

659 gss_verify_header(struct svc_rqst *rqstp, struct rsc *rsci,  in gss_verify_header()  argument
666 struct kvec *argv = &rqstp->rq_arg.head[0]; in gss_verify_header()
683 if (rqstp->rq_deferred) /* skip verification of revisited request */ in gss_verify_header()
705 gss_write_null_verf(struct svc_rqst *rqstp) in gss_write_null_verf() argument
709 svc_putnl(rqstp->rq_res.head, RPC_AUTH_NULL); in gss_write_null_verf()
710 p = rqstp->rq_res.head->iov_base + rqstp->rq_res.head->iov_len; in gss_write_null_verf()
713 if (!xdr_ressize_check(rqstp, p)) in gss_write_null_verf()
719 gss_write_verf(struct svc_rqst *rqstp, struct gss_ctx *ctx_id, u32 seq) in gss_write_verf() argument
728 svc_putnl(rqstp->rq_res.head, RPC_AUTH_GSS); in gss_write_verf()
734 p = rqstp->rq_res.head->iov_base + rqstp->rq_res.head->iov_len; in gss_write_verf()
742 if (!xdr_ressize_check(rqstp, p)) in gss_write_verf()
827 unwrap_integ_data(struct svc_rqst *rqstp, struct xdr_buf *buf, u32 seq, struct gss_ctx *ctx) in unwrap_integ_data() argument
835 if (rqstp->rq_deferred) in unwrap_integ_data()
886 unwrap_priv_data(struct svc_rqst *rqstp, struct xdr_buf *buf, u32 seq, struct gss_ctx *ctx) in unwrap_priv_data() argument
891 clear_bit(RQ_SPLICE_OK, &rqstp->rq_flags); in unwrap_priv_data()
894 if (rqstp->rq_deferred) { in unwrap_priv_data()
946 svcauth_gss_set_client(struct svc_rqst *rqstp) in svcauth_gss_set_client() argument
948 struct gss_svc_data *svcdata = rqstp->rq_auth_data; in svcauth_gss_set_client()
962 rqstp->rq_gssclient = find_gss_auth_domain(rsci->mechctx, gc->gc_svc); in svcauth_gss_set_client()
963 if (rqstp->rq_gssclient == NULL) in svcauth_gss_set_client()
965 stat = svcauth_unix_set_client(rqstp); in svcauth_gss_set_client()
972 gss_write_init_verf(struct cache_detail *cd, struct svc_rqst *rqstp, in gss_write_init_verf() argument
979 return gss_write_null_verf(rqstp); in gss_write_init_verf()
983 return gss_write_null_verf(rqstp); in gss_write_init_verf()
985 rc = gss_write_verf(rqstp, rsci->mechctx, GSS_SEQ_WIN); in gss_write_init_verf()
1049 gss_read_proxy_verf(struct svc_rqst *rqstp, in gss_read_proxy_verf() argument
1054 struct kvec *argv = &rqstp->rq_arg.head[0]; in gss_read_proxy_verf()
1063 if (inlen > (argv->iov_len + rqstp->rq_arg.page_len)) in gss_read_proxy_verf()
1066 in_token->pages = rqstp->rq_pages; in gss_read_proxy_verf()
1100 static int svcauth_gss_legacy_init(struct svc_rqst *rqstp, in svcauth_gss_legacy_init() argument
1103 struct kvec *argv = &rqstp->rq_arg.head[0]; in svcauth_gss_legacy_init()
1104 struct kvec *resv = &rqstp->rq_res.head[0]; in svcauth_gss_legacy_init()
1107 struct sunrpc_net *sn = net_generic(rqstp->rq_xprt->xpt_net, sunrpc_net_id); in svcauth_gss_legacy_init()
1120 if (cache_check(sn->rsi_cache, &rsip->h, &rqstp->rq_chandle) < 0) in svcauth_gss_legacy_init()
1126 if (gss_write_init_verf(sn->rsc_cache, rqstp, in svcauth_gss_legacy_init()
1209 static int svcauth_gss_proxy_init(struct svc_rqst *rqstp, in svcauth_gss_proxy_init() argument
1212 struct kvec *resv = &rqstp->rq_res.head[0]; in svcauth_gss_proxy_init()
1218 struct net *net = rqstp->rq_xprt->xpt_net; in svcauth_gss_proxy_init()
1222 ret = gss_read_proxy_verf(rqstp, gc, authp, in svcauth_gss_proxy_init()
1254 if (gss_write_init_verf(sn->rsc_cache, rqstp, in svcauth_gss_proxy_init()
1397 svcauth_gss_accept(struct svc_rqst *rqstp, __be32 *authp) in svcauth_gss_accept() argument
1399 struct kvec *argv = &rqstp->rq_arg.head[0]; in svcauth_gss_accept()
1400 struct kvec *resv = &rqstp->rq_res.head[0]; in svcauth_gss_accept()
1402 struct gss_svc_data *svcdata = rqstp->rq_auth_data; in svcauth_gss_accept()
1408 struct sunrpc_net *sn = net_generic(rqstp->rq_xprt->xpt_net, sunrpc_net_id); in svcauth_gss_accept()
1418 rqstp->rq_auth_data = svcdata; in svcauth_gss_accept()
1447 if ((gc->gc_proc != RPC_GSS_PROC_DATA) && (rqstp->rq_proc != 0)) in svcauth_gss_accept()
1454 if (use_gss_proxy(SVC_NET(rqstp))) in svcauth_gss_accept()
1455 return svcauth_gss_proxy_init(rqstp, gc, authp); in svcauth_gss_accept()
1457 return svcauth_gss_legacy_init(rqstp, gc, authp); in svcauth_gss_accept()
1465 switch (gss_verify_header(rqstp, rsci, rpcstart, gc, authp)) { in svcauth_gss_accept()
1482 if (gss_write_verf(rqstp, rsci->mechctx, gc->gc_seq)) in svcauth_gss_accept()
1493 if (gss_write_verf(rqstp, rsci->mechctx, gc->gc_seq)) in svcauth_gss_accept()
1495 rqstp->rq_cred = rsci->cred; in svcauth_gss_accept()
1505 if (unwrap_integ_data(rqstp, &rqstp->rq_arg, in svcauth_gss_accept()
1508 rqstp->rq_auth_slack = RPC_MAX_AUTH_SIZE; in svcauth_gss_accept()
1514 if (unwrap_priv_data(rqstp, &rqstp->rq_arg, in svcauth_gss_accept()
1517 rqstp->rq_auth_slack = RPC_MAX_AUTH_SIZE * 2; in svcauth_gss_accept()
1524 rqstp->rq_cred.cr_flavor = gss_svc_to_pseudoflavor( in svcauth_gss_accept()
1536 xdr_ressize_check(rqstp, reject_stat); in svcauth_gss_accept()
1578 svcauth_gss_wrap_resp_integ(struct svc_rqst *rqstp) in svcauth_gss_wrap_resp_integ() argument
1580 struct gss_svc_data *gsd = (struct gss_svc_data *)rqstp->rq_auth_data; in svcauth_gss_wrap_resp_integ()
1582 struct xdr_buf *resbuf = &rqstp->rq_res; in svcauth_gss_wrap_resp_integ()
1625 svcauth_gss_wrap_resp_priv(struct svc_rqst *rqstp) in svcauth_gss_wrap_resp_priv() argument
1627 struct gss_svc_data *gsd = (struct gss_svc_data *)rqstp->rq_auth_data; in svcauth_gss_wrap_resp_priv()
1629 struct xdr_buf *resbuf = &rqstp->rq_res; in svcauth_gss_wrap_resp_priv()
1690 svcauth_gss_release(struct svc_rqst *rqstp) in svcauth_gss_release() argument
1692 struct gss_svc_data *gsd = (struct gss_svc_data *)rqstp->rq_auth_data; in svcauth_gss_release()
1694 struct xdr_buf *resbuf = &rqstp->rq_res; in svcauth_gss_release()
1696 struct sunrpc_net *sn = net_generic(rqstp->rq_xprt->xpt_net, sunrpc_net_id); in svcauth_gss_release()
1711 stat = svcauth_gss_wrap_resp_integ(rqstp); in svcauth_gss_release()
1716 stat = svcauth_gss_wrap_resp_priv(rqstp); in svcauth_gss_release()
1729 if (rqstp->rq_client) in svcauth_gss_release()
1730 auth_domain_put(rqstp->rq_client); in svcauth_gss_release()
1731 rqstp->rq_client = NULL; in svcauth_gss_release()
1732 if (rqstp->rq_gssclient) in svcauth_gss_release()
1733 auth_domain_put(rqstp->rq_gssclient); in svcauth_gss_release()
1734 rqstp->rq_gssclient = NULL; in svcauth_gss_release()
1735 if (rqstp->rq_cred.cr_group_info) in svcauth_gss_release()
1736 put_group_info(rqstp->rq_cred.cr_group_info); in svcauth_gss_release()
1737 rqstp->rq_cred.cr_group_info = NULL; in svcauth_gss_release()