다음을 통해 공유


2.2.4.63.1 Request

The SMB_COM_NT_TRANSACT_SECONDARY request message has the same purpose as the other secondary transaction messages used in SMB. The fields are in a different order to provide better alignment, and the Count, Offset, and Displacement fields are 32 bits wide instead of 16.

 SMB_Parameters
   {
   UCHAR  WordCount;
   Words
     {
     UCHAR Reserved1[3];
     ULONG TotalParameterCount;
     ULONG TotalDataCount;
     ULONG ParameterCount;
     ULONG ParameterOffset;
     ULONG ParameterDisplacement;
     ULONG DataCount;
     ULONG DataOffset;
     ULONG DataDisplacement;
     UCHAR Reserved2;
     }
   }
 SMB_Data
   {
   USHORT ByteCount;
   Bytes
     {
     UCHAR Pad1[];
     UCHAR Parameters[ParameterCount];
     UCHAR Pad2[];
     UCHAR Data[DataCount];
     }
   }
            

SMB_Header:

This command MUST be sent following a successful SMB_COM_NT_TRANSACT Intermediate Response from the server. The PID, MID, TID, and UID MUST be the same for all requests and responses that are part of the same transaction.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

SMB_Parameters (37 bytes)

...

...

...

SMB_Data (variable)

...

SMB_Parameters (37 bytes):


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

WordCount

Words (36 bytes)

...

...

...

WordCount (1 byte): This value represents the total number of SMB parameter words and MUST be 0x12.

Words (36 bytes):


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

Reserved1

TotalParameterCount

...

TotalDataCount

...

ParameterCount

...

ParameterOffset

...

ParameterDisplacement

...

DataCount

...

DataOffset

...

DataDisplacement

...

Reserved2

Reserved1 (3 bytes): Reserved. Used to align the following fields to a 32-bit boundary. This field MUST contain null padding bytes in the server response. The client MUST ignore the contents of this field.

TotalParameterCount (4 bytes): The total number of transaction parameter bytes to be sent to the server over the course of this transaction. This value MAY be less than or equal to the TotalParameterCount in preceding request messages that are part of the same transaction. This value represents transaction parameter bytes, not SMB parameter words.

TotalDataCount (4 bytes): The total number of transaction data bytes to be sent to the server over the course of this transaction. This value MAY be less than or equal to the TotalDataCount in preceding request messages that are part of the same transaction. This value represents transaction data bytes, not SMB data bytes.

ParameterCount (4 bytes): The number of transaction parameter bytes being sent in the SMB message. This value MUST be less than TotalParameterCount. The sum of the ParameterCount values across all of the request messages in a transaction MUST be equal to the TotalParameterCount reported in the last request message of the transaction.

ParameterOffset (4 bytes): The offset, in bytes, from the start of the SMB_Header to the transaction parameter bytes contained in this SMB message. This MUST be the number of bytes from the start of the SMB message to the start of the SMB_Data.Bytes.Parameters field. Server implementations MUST use this value to locate the transaction parameter block within the SMB message. If ParameterCount is zero, the client/server MAY set this field to zero.<117>

ParameterDisplacement (4 bytes): The offset, relative to all of the transaction parameter bytes sent to the server in this transaction, at which this block of parameter bytes MUST be placed. This value can be used by the server to correctly reassemble the transaction parameters even if the SMB request messages are received out of order.

DataCount (4 bytes): The number of transaction data bytes being sent in this SMB message. This value MUST be less than the value of TotalDataCount. The sum of the DataCount values across all of the request messages in a transaction MUST be equal to the smallest TotalDataCount value reported to the server.

DataOffset (4 bytes): The offset, in bytes, from the start of the SMB_Header to the transaction data bytes contained in this SMB message. This MUST be the number of bytes from the start of the SMB message to the start of the SMB_Data.Bytes.Data field. Server implementations MUST use this value to locate the transaction data block within the SMB message. If DataCount is zero, the client/server MAY set this field to zero.<118>

DataDisplacement (4 bytes): The offset, relative to all of the transaction data bytes sent to the server in this transaction, at which this block of parameter bytes MUST be placed. This value can be used by the server to correctly reassemble the transaction data block even if the SMB request messages are received out of order.

Reserved2 (1 byte): Reserved. MUST be 0x00. The server MUST ignore the contents of this field.

SMB_Data (variable):

The SMB_Data section of the SMB_COM_NT_TRANSACT_SECONDARY request contains parameters and data bytes being sent to the server.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

ByteCount

Bytes (variable)

...

ByteCount (2 bytes): The number of bytes in the SMB_Data.Bytes array, which follows.

Bytes (variable):


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

Pad1 (variable)

...

Parameters (variable)

...

Pad2 (variable)

...

Data (variable)

...

Pad1 (variable): This field SHOULD be used as an array of padding bytes to align the following field to a 4-byte boundary relative to the start of the SMB Header (section 2.2.3.1). This constraint can cause this field to be a zero-length field. This field SHOULD be set to zero by the client/server and MUST be ignored by the server/client.

Parameters (variable): Transaction parameter bytes.

Pad2 (variable): This field SHOULD be used as an array of padding bytes to align the following field to a 4-byte boundary relative to the start of the SMB Header. This constraint can cause this field to be a zero-length field. This field SHOULD be set to zero by the client/server and MUST be ignored by the server/client.

Data (variable): Transaction data bytes.