When a client connects to a server resource, an SMB_COM_TREE_CONNECT message is generated to the server. This command is almost exactly like SMB_COM_TREE_CONNECT_ANDX, except that no AndX command may follow; see section 4.1.4.
Client Request ================================== |
Description ================================= |
UCHAR WordCount; | Count of parameter words = 0 |
USHORT ByteCount; | Count of data bytes; min = 4 |
UCHAR BufferFormat1; | 0x04 |
STRING Path[]; | Server name and share name |
UCHAR BufferFormat2; | 0x04 |
STRING Password[]; | Password |
UCHAR BufferFormat3; | 0x04 |
STRING Service[]; | Service name |
The CIFS server responds with:
Server Response ================================ |
Description ================================= |
UCHAR WordCount; | Count of parameter words = 2 |
USHORT MaxBufferSize; | Max size message the server handles |
USHORT Tid; | Tree ID |
USHORT ByteCount; | Count of data bytes = 0 |
If the negotiated dialect is MICROSOFT NETWORKS 1.03
or earlier, MaxBufferSize in the response message indicates the maximum size message that the server can handle. The client should not generate messages, nor expect to receive responses, larger than this. This must be constant for a given server. For newer dialects, this field is ignored.
tid should be included in any future SMBs referencing this tree connection.