WRITE_PRINT_FILE: Write to Print File

This message is sent to write bytes into a print spool file.

Client Request
==================================
Description
=================================
UCHAR WordCount; Count of parameter words = 1
USHORT Fid; File handle
USHORT ByteCount; Count of data bytes; min = 4
UCHAR BufferFormat; 0x01 -- Data block
USHORT DataLength; Length of data
UCHAR Data[]; Data

fid indicates the print spool file to be written, it must refer to a print spool file.

bytecount specifies the number of bytes to be written, and must be less than maxbuffersize for the Tid specified.

data contains the bytes to append to the print spool file. The first setuplength bytes in the resulting print spool file contain printer setup data. setuplength is specified in the SMB_COM_OPEN_PRINT_FILE SMB request.

Server Response
==================================
Description
=================================
UCHAR WordCount; Count of parameter words = 0
USHORT ByteCount; Count of data bytes = 0

Servers which negotiate a protocol dialect of LANMAN1.0 or later also support the application of normal write requests to print spool files.