2.2.42 SMB2 COMPRESSION_TRANSFORM_HEADER

The SMB2 COMPRESSION_TRANSFORM_HEADER is used by the client or server when sending compressed messages. This optional header is only valid for the SMB 3.1.1 dialect<69>.


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

ProtocolId

OriginalCompressedSegmentSize

CompressionAlgorithm

Flags

Offset/Length

ProtocolId (4 bytes): The protocol identifier. The value MUST be set to 0x424D53FC, also represented as (in network order) 0xFC, 'S', 'M', and 'B'.

OriginalCompressedSegmentSize (4 bytes): The size, in bytes, of the uncompressed data segment.

CompressionAlgorithm (2 bytes): This field MUST contain one of the algorithms used to compress the SMB2 message as specified in the CompressionAlgorithms field of section 2.2.3.1.3, except “NONE”.

Flags (2 bytes): This field MUST be set to one of the following values:

Value

Meaning

SMB2_COMPRESSION_FLAG_NONE

0x0000

Chained compression is not supported.

SMB2_COMPRESSION_FLAG_CHAINED

0x0001

The Compressed message is chained with multiple compressed payloads.

Offset/Length (4 bytes): If SMB2_COMPRESSION_FLAG_CHAINED is set in Flags field, this field MUST be interpreted as Length. The length, in bytes, of the compressed payload. Otherwise, this field MUST be interpreted as Offset. The offset, in bytes, from the end of this structure to the start of compressed data segment.