2.2.4.26.2 Response

 SMB_Parameters
   {
   UCHAR  WordCount;
   Words
     {
     ULONG ResponseMask;
     }
   }
 SMB_Data
   {
   USHORT ByteCount;
   }


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

...

SMB_Data

SMB_Parameters (5 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

...

WordCount (1 byte): This field MUST be 0x02.

Words (4 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

ResponseMask

ResponseMask (4 bytes): This field is the logical OR-ing of the RequestMask value contained in each SMB_COM_WRITE_MPX (section 2.2.4.26) received since the last sequenced SMB_COM_WRITE_MPX. The server responds only to the final (sequenced) command. This response contains the accumulated ResponseMask from all successfully received requests. The client uses the ResponseMask received to determine which packets, if any, MUST be retransmitted.

SMB_Data (2 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

ByteCount

ByteCount (2 bytes): This field MUST be 0x0000. No data is sent by this message.

Error Codes

If the WritethroughMode flag is clear in the client requests (particularly the sequenced request), the server SHOULD return a response upon receiving the sequenced request. Any data not yet written MUST be written after the response has been sent. Any errors generated after the server has sent the SMB_COM_WRITE_MPX response MUST be saved and returned the next time that the FID is referenced.

SMB error class

SMB error code

NT status code

POSIX equivalent

Description

SUCCESS (0x00)

SUCCESS

(0x0)

STATUS_SUCCESS

(0x00000000)

EFBIG

The file has grown too large and no more data can be written to the file. A Count of zero (0x0000) MUST be returned to the client in the server response. This indicates to the client that the file system is full.

SUCCESS (0x00)

SUCCESS

(0x0)

STATUS_SUCCESS

(0x00000000)

NOSPC

No space on the file system. The server MUST return a zero (0x0000) in the Count field of the response. This indicates that the file system is full.

ERRDOS (0x01)

ERRnoaccess

(0x0005)

EAGAIN

Resources for I/O on the server are temporarily exhausted.

ERRDOS (0x01)

ERRnoaccess

(0x0005)

STATUS_ACCESS_DENIED

(0xC0000022)

The client does not have write permission.

ERRDOS (0x01)

ERRbadfid

(0x0006)

STATUS_INVALID_HANDLE

(0xC0000008)

STATUS_SMB_BAD_FID

(0x00060001)

ENFILE

Invalid FID, or FID mapped to a valid server FID but it was not acceptable to the operating system.

ERRDOS (0x01)

ERRnomem

(0x0008)

STATUS_INSUFF_SERVER_RESOURCES

(0xC0000205)

ENOMEM

The server is out of resources.

ERRDOS (0x01)

ERRbadaccess

(0x000C)

STATUS_ACCESS_DENIED

(0xC0000022)

Write permission required.

ERRDOS (0x01)

ERRlock

(0x0021)

STATUS_FILE_LOCK_CONFLICT

(0xC0000054)

The requested byte range was already locked by a different process (PID).

ERRSRV (0x02)

ERRerror

(0x0001)

EDEADLK

The write would block due to locking and deadlock would result.

ERRSRV (0x02)

ERRerror

(0x0001)

ERANGE

Attempted write size is outside of the minimum or maximum ranges that can be written to the supplied FID.

ERRSRV (0x02)

ERRerror

(0x0001)

STATUS_INVALID_SMB

(0x00010002)

A corrupt or invalid SMB request was received.

ERRSRV (0x02)

ERRinvtid

(0x0005)

STATUS_SMB_BAD_TID

(0x00050002)

Invalid TID in request.

ERRSRV (0x02)

ERRqfull

(0x0031)

STATUS_PRINT_QUEUE_FULL

(0xC00000C6)

Print queue is full - too many queued items.

ERRSRV (0x02)

ERRqtoobig

(0x0032)

STATUS_NO_SPOOL_SPACE

(0xC00000C7)

Print queue is full - too many queued items.

ERRSRV (0x02)

ERRbaduid

(0x005B)

STATUS_SMB_BAD_UID

(0x005B0002)

The UID specified is not known as a valid ID on this server session, or the user identified by the UID does not have sufficient privileges.

ERRSRV (0x02)

ERRuseSTD

(0x00FB)

STATUS_SMB_USE_STANDARD

(0x00FB0002)

Not a datagram or connectionless transport OR the FID is not a disk file OR print queue client MUST use standard write commands.

ERRHRD (0x03)

ERRdata

(0x0017)

STATUS_DATA_ERROR

(0xC000003E)

EIO

A problem has occurred in the physical I/O.

ERRHRD (0x03)

ERRwrite

(0x001D)

ENXIO

The device associated with the file descriptor is a block-special or character-special file and the value of the file pointer is out of range.

ERRHRD (0x03)

ERRgeneral

(0x001F)

STATUS_CANCELLED

(0xC0000120)

A transport error occurred and the request was canceled.

ERRHRD (0x03)

ERRdiskfull

(0x0027)

STATUS_DISK_FULL

(0xC000007F)

ENOSPC

The file system is full.