From 1bdee1756e70ec2611e568776dd93c70f5e6feef Mon Sep 17 00:00:00 2001 From: Raghavendra G Date: Mon, 6 Sep 2010 05:44:14 +0000 Subject: rpc-clnt: fix memory corruption happening while encoding auth data. - buffer containing authdata pointed by rpc-request was allocated on stack of procedure rpc_clnt_fill_request, but was being used as source for xdr-encoding in rpc_clnt_record_build_record. Hence by the time auth-data is being copied during encoding of request, it might've been freed and hence contain garbage. Signed-off-by: Raghavendra G Signed-off-by: Vijay Bellur BUG: 875 (Implement a new protocol to provide proper backward/forward compatibility) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=875 --- rpc/rpc-lib/src/rpc-clnt.h | 1 + 1 file changed, 1 insertion(+) (limited to 'rpc/rpc-lib/src/rpc-clnt.h') diff --git a/rpc/rpc-lib/src/rpc-clnt.h b/rpc/rpc-lib/src/rpc-clnt.h index a0251c7c551..ab95608adb7 100644 --- a/rpc/rpc-lib/src/rpc-clnt.h +++ b/rpc/rpc-lib/src/rpc-clnt.h @@ -32,6 +32,7 @@ typedef enum { } rpc_clnt_event_t; #define AUTH_GLUSTERFS 5 +#define RPC_CLNT_MAX_AUTH_BYTES 1024 struct xptr_clnt; struct rpc_req; -- cgit