diff options
author | Andrew Tridgell <tridge@samba.org> | 2001-12-21 11:58:30 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2001-12-21 11:58:30 +0000 |
commit | 384ce26f5bdf27aadaea967b17ee6ca8549aca5a (patch) | |
tree | b46a49fddeb45596c4dd5fce8ff8ac9e669fa34c /source3 | |
parent | 65ad38f6f7b91b326276d305463e48af861c5cb2 (diff) | |
download | samba-384ce26f5bdf27aadaea967b17ee6ca8549aca5a.tar.gz samba-384ce26f5bdf27aadaea967b17ee6ca8549aca5a.tar.bz2 samba-384ce26f5bdf27aadaea967b17ee6ca8549aca5a.zip |
try to handle end of packet for not null terminated domain strings
(This used to be commit 1da988456dbd885820093ae43c74e0ac66f72802)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/libsmb/cliconnect.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source3/libsmb/cliconnect.c b/source3/libsmb/cliconnect.c index fc50e8e02f..d636e7e839 100644 --- a/source3/libsmb/cliconnect.c +++ b/source3/libsmb/cliconnect.c @@ -372,7 +372,9 @@ static DATA_BLOB cli_session_setup_blob(struct cli_state *cli, DATA_BLOB blob) p += blob2.length; p += clistr_pull(cli, cli->server_os, p, sizeof(fstring), -1, STR_TERMINATE); p += clistr_pull(cli, cli->server_type, p, sizeof(fstring), -1, STR_TERMINATE); - p += clistr_pull(cli, cli->server_domain, p, sizeof(fstring), -1, STR_TERMINATE); + p += clistr_pull(cli, cli->server_domain, p, sizeof(fstring), + smb_buflen(cli->inbuf) - PTR_DIFF(p, smb_buf(cli->inbuf)), + 0); return blob2; } |