The Samba-Bugzilla – Attachment 10692 Details for
Bug 9702
Current crediting algorithm causes problems due to a Win7 client bug.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
reproducer patches for smbclient -mSMB2_02 or -mSMB3_00
reproduce-hacks-02.diff.txt (text/plain), 2.46 KB, created by
Stefan Metzmacher
on 2015-01-29 11:38:12 UTC
(
hide
)
Description:
reproducer patches for smbclient -mSMB2_02 or -mSMB3_00
Filename:
MIME Type:
Creator:
Stefan Metzmacher
Created:
2015-01-29 11:38:12 UTC
Size:
2.46 KB
patch
obsolete
>From ba8319e02c4e4291b749b4f16d7bbbff2c44f62c Mon Sep 17 00:00:00 2001 >From: Stefan Metzmacher <metze@samba.org> >Date: Wed, 28 Jan 2015 15:13:26 +0100 >Subject: [PATCH] debug credits client... reproduce > https://bugzilla.samba.org/show_bug.cgi?id=9702 > >--- > libcli/smb/smbXcli_base.c | 22 +++++++++++++++++++++- > source3/client/client.c | 2 +- > 2 files changed, 22 insertions(+), 2 deletions(-) > >diff --git a/libcli/smb/smbXcli_base.c b/libcli/smb/smbXcli_base.c >index 8aa6020..7453cc0 100644 >--- a/libcli/smb/smbXcli_base.c >+++ b/libcli/smb/smbXcli_base.c >@@ -2555,6 +2555,7 @@ void smb2cli_conn_set_max_credits(struct smbXcli_conn *conn, > uint16_t max_credits) > { > conn->smb2.max_credits = max_credits; >+ conn->smb2.max_credits = 128; > } > > static void smb2cli_req_cancel_done(struct tevent_req *subreq); >@@ -2934,11 +2935,25 @@ NTSTATUS smb2cli_req_compound_submit(struct tevent_req **reqs, > credits = state->conn->smb2.max_credits - > state->conn->smb2.cur_credits; > } >- if (state->conn->smb2.max_credits >= state->conn->smb2.cur_credits) { >+ if (state->conn->smb2.max_credits > state->conn->smb2.cur_credits) { > credits += 1; > } > >+ if (credits == 0) { >+ state->conn->smb2.max_credits = 0; >+ } >+ > mid = state->conn->smb2.mid; >+ if (state->conn->smb2.server.capabilities & SMB2_CAP_LARGE_MTU) { >+ if (avail > charge) { >+ charge++; >+ } >+ } >+ DEBUG(0,("opcode[%u] mid[%llu] requests credits[%u] charge[%u] max[%u] cur[%u] avail[%llu]\n", >+ opcode, (unsigned long long)mid, credits, charge, >+ state->conn->smb2.max_credits, >+ state->conn->smb2.cur_credits, >+ (unsigned long long)avail)); > state->conn->smb2.mid += charge; > state->conn->smb2.cur_credits -= charge; > >@@ -3375,6 +3390,11 @@ static NTSTATUS smb2cli_conn_dispatch_incoming(struct smbXcli_conn *conn, > const DATA_BLOB *signing_key = NULL; > bool was_encrypted = false; > >+ DEBUG(0,("opcode[%u] mid[%llu] RESPONSE credits[%u] max[%u] cur[%u] \n", >+ opcode, (unsigned long long)mid, credits, >+ conn->smb2.max_credits, >+ conn->smb2.cur_credits)); >+ > new_credits = conn->smb2.cur_credits; > new_credits += credits; > if (new_credits > UINT16_MAX) { >diff --git a/source3/client/client.c b/source3/client/client.c >index 5d70897..97cc6ca 100644 >--- a/source3/client/client.c >+++ b/source3/client/client.c >@@ -5138,7 +5138,7 @@ static void readline_callback(void) > clock_gettime_mono(&now); > t = now.tv_sec; > >- if (t - last_t < 5) >+ if (t - last_t < 1) > return; > > last_t = t; >-- >1.9.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 9702
:
8617
|
8984
|
10677
|
10680
|
10691
| 10692 |
10693
|
10694
|
10695
|
10697
|
10698