summaryrefslogtreecommitdiff
path: root/source4/librpc/rpc/dcerpc.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-08-24 23:56:59 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:58:18 -0500
commit5e122da65593b64dbd6be239e44f540bb35affd7 (patch)
tree136b667e038d1fd44f737bd2643d36ad9973082c /source4/librpc/rpc/dcerpc.c
parent13c899de96a751bf38aef6818aaca72a9fd5ccee (diff)
downloadsamba-5e122da65593b64dbd6be239e44f540bb35affd7.tar.gz
samba-5e122da65593b64dbd6be239e44f540bb35affd7.tar.bz2
samba-5e122da65593b64dbd6be239e44f540bb35affd7.zip
r2029: changed our client side dcerpc padding to match what w2k3 does - a 16
byte padding of the payload portion of the packet. (This used to be commit 271831f97f3952838557bf5034c1e435b33cb14a)
Diffstat (limited to 'source4/librpc/rpc/dcerpc.c')
-rw-r--r--source4/librpc/rpc/dcerpc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source4/librpc/rpc/dcerpc.c b/source4/librpc/rpc/dcerpc.c
index 0e8828acbd..31db6df738 100644
--- a/source4/librpc/rpc/dcerpc.c
+++ b/source4/librpc/rpc/dcerpc.c
@@ -245,8 +245,10 @@ static NTSTATUS dcerpc_push_request_sign(struct dcerpc_pipe *p,
return status;
}
- /* pad to 8 byte multiple */
- p->security_state.auth_info->auth_pad_length = NDR_ALIGN(ndr, 8);
+ /* pad to 16 byte multiple in the payload portion of the
+ packet. This matches what w2k3 does */
+ p->security_state.auth_info->auth_pad_length =
+ (16 - (pkt->u.request.stub_and_verifier.length & 15)) & 15;
ndr_push_zero(ndr, p->security_state.auth_info->auth_pad_length);
/* sign or seal the packet */