3.2.5.5 Receiving a Tunnel Operation Request

When the server receives a tunnel operation request, the server MUST locate the Open in the OpenTable where Open.LocalOpen matches the Open provided by the SMB2 server, as specified in [MS-SMB2] section 3.3.5.13.

If no Open is found, the server MUST fail the request and return STATUS_INVALID_PARAMETER.

If the size of the tunnel operation request including the header is less than 16, the server MUST fail the request with STATUS_BUFFER_TOO_SMALL.

If an Open is found and if the bitwise AND of the OperationCode value and 0xFF000000 is not equal to 0x02000000, the server MUST fail the request with STATUS_INVALID_DEVICE_REQUEST.

If any of the following conditions is TRUE, the server MUST construct the SVHDX_TUNNEL_OPERATION_HEADER with the OperationCode and RequestId fields set to the value received in the request, and with the Status field set as follows.

  • If ServerServiceVersion is equal to RSVD Protocol version 1(0x00000001) and the bitwise AND of the OperationCode value and 0x00FFF000 is not equal to 0x00001000, the Status field MUST be set to STATUS_SVHDX_VERSION_MISMATCH.

  • If ServerServiceVersion is equal to RSVD Protocol version 2(0x00000002) and the bitwise AND of the OperationCode value and 0x00FFF000 is not equal to 0x00001000 or 0x00002000, the Status field MUST be set to STATUS_SVHDX_VERSION_MISMATCH.

  • If the OperationCode value does not exist in the tunnel operation list as specified in section 2.2.2, the Status field MUST be set to STATUS_INVALID_PARAMETER.

The server MUST return SVHDX_TUNNEL_OPERATION_HEADER to the client.

Processing for a specific OperationCode is as specified in subsequent sections.