summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>2000-03-17 17:48:19 +0000
committerLuke Leighton <lkcl@samba.org>2000-03-17 17:48:19 +0000
commit06a3ad85122ec5e741425f7c539c8c884a432a52 (patch)
tree33eda7a1d154803c0e08048763e0cb9410469b3f
parent1b358673fb57d771d0463a85193ed4911971dbae (diff)
downloadsamba-06a3ad85122ec5e741425f7c539c8c884a432a52.tar.gz
samba-06a3ad85122ec5e741425f7c539c8c884a432a52.tar.xz
samba-06a3ad85122ec5e741425f7c539c8c884a432a52.zip
making sure that req chal would not be affected by having prs_align()
added to *inside* smb_io_unistr2(). this is the _only_ place where alignment rules are broken.
-rw-r--r--source/rpc_parse/parse_net.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/source/rpc_parse/parse_net.c b/source/rpc_parse/parse_net.c
index acb31380f6a..aed01c40703 100644
--- a/source/rpc_parse/parse_net.c
+++ b/source/rpc_parse/parse_net.c
@@ -338,13 +338,16 @@ BOOL net_io_q_req_chal(char *desc, NET_Q_REQ_CHAL * q_c, prs_struct * ps,
prs_uint32("undoc_buffer", ps, depth, &(q_c->undoc_buffer));
- smb_io_unistr2("", &(q_c->uni_logon_srv), True, ps, depth); /* logon server unicode string */
- smb_io_unistr2("", &(q_c->uni_logon_clnt), True, ps, depth); /* logon client unicode string */
+ smb_io_unistr2("logon_srv", &(q_c->uni_logon_srv), True, ps, depth);
+ prs_align(ps);
+ /* client challenge is _not_ aligned after the unicode strings */
old_align = ps->align;
ps->align = 0;
- /* client challenge is _not_ aligned after the unicode strings */
- smb_io_chal("", &(q_c->clnt_chal), ps, depth); /* client challenge */
+
+ smb_io_unistr2("logon_clnt", &(q_c->uni_logon_clnt), True, ps, depth);
+ smb_io_chal("clnt_chal", &(q_c->clnt_chal), ps, depth);
+
ps->align = old_align;
return True;