[jcifs] Large Read/Write Patch
M. D.
moder at abv.bg
Wed Dec 17 06:30:34 MST 2014
Hi,
I'm uploading a new patch. It now contains checks if signatures are desired. If that's the case then the old buffer size is used.
Best regards,
M.D
>-------- Оригинално писмо --------
>От: M. D.
>Относно: Re: [jcifs] Large Read/Write Patch
>До: Robin Jansohn
>Изпратено на: Сряда, 2014, Декември 17 10:58:08 EET
>
>
> Hello,
>
>I also confirm that read/write operations with the patch applied are significantly faster.
>
>However, I think there is a problem with the patch:
>
>According to the official SMB documentation:
>http://download.microsoft.com/download/9/5/E/95EF66AF-9026-4BB0-A41D-A4F81802D92C/[MS-SMB].pdf
>
>... sections 2.2.4.5, 2.2.4.5.2:
>"Capabilities (4 bytes): A 32-bit field providing a set of server capability indicators. This bit field is
>used to indicate to the client which features are supported by the server. Any value not listed in the
>following table is unused. The server MUST set the unused bits to zero. The client MUST ignore
>these bits.".
>
>The CAP_LARGE_WRITEX flag that is part of the Capabilities (4 bytes) field is responsible for:
>
>"The server supports large write operations. This
>capability affects the maximum size, in bytes, of the
>server buffer for receiving an SMB_COM_WRITE_ANDX
>client request. When this capability is set by the server
>(and set by the client in the
>SMB_COM_SESSION_SETUP_ANDX request), then the
>maximum server buffer size of bytes it writes can
>exceed the MaxBufferSize field. Therefore, a client
>can send a single SMB_COM_WRITE_ANDX request up
>to this size.
>When signing is active on a connection, then clients
>MUST limit write lengths to the MaxBufferSize value
>negotiated by the server, irrespective of the value of
>the CAP_LARGE_WRITEX flag."
>
>... so it is true that we can safely ignore the MaxBufferSize and send larger chunks of data UNLESS signing is active on a connection. Therefore, I think checks for signing should be added to the patch.
>
>Hope that helps!
>
>
>Best regards,
>M.D
>
>
>
>
> >-------- Оригинално писмо --------
> >От: Robin Jansohn
> >Относно: Re: [jcifs] Large Read/Write Patch
> >До: jcifs at lists.samba.org
> >Изпратено на: Понеделник, 2014, Декември 15 09:08:49 EET
> >
> >
> >No, I'm using a Maven repository and although I explicitly excluded the
> >package it somehow did not work as expected. The test itself is run in a
> >simple Main class, no webapp or similar large application.
> >
> >
> >
> >--
> >View this message in context: http://samba.2283325.n4.nabble.com/Large-Read-Write-Patch-tp3674893p4677877.html
> >Sent from the Samba - jcifs mailing list archive at Nabble.com.
> >
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: LargeReadWrite.patch
Type: application/octet-stream
Size: 6732 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/jcifs/attachments/20141217/58761dc9/attachment.obj>
More information about the jCIFS
mailing list