X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?p=pandora-kernel.git;a=blobdiff_plain;f=net%2Fsunrpc%2Fauth_gss%2Fsvcauth_gss.c;h=81ae3d62a0cc9010d4cc1b6e5de130ae64ca2a57;hp=481f984e9a22278bc9ef1993bc3064c77fc65a51;hb=b620754bfeb8b0e0c6622b03d5ee2f1af1d3082f;hpb=d870ec7281d8429ab17d2e0324f4d8ca3f3de62d diff --git a/net/sunrpc/auth_gss/svcauth_gss.c b/net/sunrpc/auth_gss/svcauth_gss.c index 481f984e9a22..81ae3d62a0cc 100644 --- a/net/sunrpc/auth_gss/svcauth_gss.c +++ b/net/sunrpc/auth_gss/svcauth_gss.c @@ -1144,20 +1144,20 @@ svcauth_gss_accept(struct svc_rqst *rqstp, __be32 *authp) case RPC_GSS_SVC_NONE: break; case RPC_GSS_SVC_INTEGRITY: - if (unwrap_integ_data(&rqstp->rq_arg, - gc->gc_seq, rsci->mechctx)) - goto auth_err; /* placeholders for length and seq. number: */ svc_putnl(resv, 0); svc_putnl(resv, 0); + if (unwrap_integ_data(&rqstp->rq_arg, + gc->gc_seq, rsci->mechctx)) + goto garbage_args; break; case RPC_GSS_SVC_PRIVACY: - if (unwrap_priv_data(rqstp, &rqstp->rq_arg, - gc->gc_seq, rsci->mechctx)) - goto auth_err; /* placeholders for length and seq. number: */ svc_putnl(resv, 0); svc_putnl(resv, 0); + if (unwrap_priv_data(rqstp, &rqstp->rq_arg, + gc->gc_seq, rsci->mechctx)) + goto garbage_args; break; default: goto auth_err; @@ -1169,6 +1169,9 @@ svcauth_gss_accept(struct svc_rqst *rqstp, __be32 *authp) ret = SVC_OK; goto out; } +garbage_args: + ret = SVC_GARBAGE; + goto out; auth_err: /* Restore write pointer to its original value: */ xdr_ressize_check(rqstp, reject_stat);