Export (0) Print
Expand All

2.2.4.19.2 Response

SMB_Parameters
  {
  UCHAR WordCount;
  Words
    {
    ULONG Offset;
    }
  }
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 0x0002.

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

Offset

Offset (4 bytes): A 32-bit unsigned value indicating the absolute file position relative to the start of the file at which the file pointer is currently set. The value of Offset ranges from 0 to 4 gigabytes (0 to 2**32 - 1 bytes).

A seek that results in a file position value that cannot be expressed in 32 bits MUST set Offset to the least significant 32 bits.<31>

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.

The response returns the new file pointer in Offset, expressed as the number of bytes from the start of the file. The Offset MAY be beyond the current end of file. An attempt to seek to before the start of file sets the current file pointer to the start of the file (0x00000000).

Error Codes

SMB error class

SMB error code

NT status code

POSIX equivalent

Description

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)

ERReof

(0x0026)

STATUS_END_OF_FILE

(0xC0000011)

EEOF

The end of the file is beyond where the client can read; file is larger than 4GB.

ERRDOS (0x01)

ERRinvalidparam

(0x0057)

STATUS_INVALID_PARAMETER

(0xC000000D)

EEOF

The Mode field value is out of range.

ERRDOS (0x01)

ERRinvalidseek

(0x0083)

STATUS_OS2_NEGATIVE_SEEK

(0x00830001)

 

An attempt was made to seek to a negative absolute offset within a file.

ERRSRV (0x02)

ERRerror

(0x0001)

STATUS_INVALID_SMB

(0x00010002)

 

A corrupt SMB request was received.

ERRSRV (0x02)

ERRinvtid

(0x0005)

STATUS_SMB_BAD_TID

(0x00050002)

 

Invalid TID in request.

ERRSRV (0x02)

ERRinvdevice (0x0007)

STATUS_BAD_DEVICE_TYPE

(0xC00000CB)

 

Invalid file type. Attempt to seek in a non-regular file.

ERRSRV (0x02)

ERRbaduid

(0x005B)

STATUS_SMB_BAD_UID

(0x005B0002)

 

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

 
Show:
© 2015 Microsoft