次の方法で共有


2.2.7.1.2 Server Response Extensions

When a client requests extended information by setting NT_CREATE_REQUEST_EXTENDED_RESPONSE, a successful response takes the following format.

Aside from ResponseType, NMPipeStatus_or_FileStatusFlags, VolumeGUID, FileId, MaximalAccessRights, and GuestMaximalAccessRights fields, all other fields are as specified in [MS-CIFS] section 2.2.7.1.2.

            
 NT_Trans_Parameters
   {
   UCHAR         OpLockLevel;
   UCHAR         ResponseType;
   USHORT        FID;
   ULONG         CreateAction;
   ULONG         EAErrorOffset;
   FILETIME      CreationTime;
   FILETIME      LastAccessTime;
   FILETIME      LastWriteTime;
   FILETIME      LastChangeTime;
   SMB_EXT_FILE_ATTR ExtFileAttributes;
   LARGE_INTEGER AllocationSize;
   LARGE_INTEGER EndOfFile;
   USHORT        ResourceType;
   SMB_NMPIPE_STATUS NMPipeStatus_or_FileStatusFlags;
   UCHAR         Directory;
   GUID          VolumeGUID;
  ULONGLONG     FileId;
  ACCESS_MASK   MaximalAccessRights;
   ACCESS_MASK   GuestMaximalAccessRights;
   }

NT_Trans_Parameters (69 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

OpLockLevel

ResponseType

FID

CreateAction

EAErrorOffset

CreationTime (variable)

...

LastAccessTime (variable)

...

LastWriteTime (variable)

...

LastChangeTime (variable)

...

ExtFileAttributes

AllocationSize (variable)

...

EndOfFile (variable)

...

ResourceType

NMPipeStatus_or_FileStatusFlags

Directory

VolumeGUID (16 bytes)

...

...

...

FileId

...

...

MaximalAccessRight

...

GuestMaximalAccessRights

...

ResponseType (1 byte):  The response type received. This field MUST be set to any one of the following values, based on the response type.

Name & bitmask

Meaning

NON_EXTENDED_RESPONSE

0x00

Response received is not an extended response.

EXTENDED_RESPONSE

0x01

Response received is an extended response.

NMPipeStatus_or_FileStatusFlags (2 bytes): A union between the NMPipeStatus field and the new FileStatusFlags field. If the ResourceType field is a named pipe (FileTypeByteModePipe or FileTypeMessageModePipe), then this field MUST be the NMPipeStatus field:


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

NMPipeStatus

FileStatusFlags

NMPipeStatus (2 bytes): A 16-bit field that shows the status of the opened named pipe. This field is formatted as an SMB_NMPIPE_STATUS ([MS-CIFS] section 2.2.1.3).

If the ResourceType field is FileTypeDisk, then this field MUST be the FileStatusFlags field.

FileStatusFlags (2 bytes): A 16-bit field that shows extra information about the opened file or directory. Any combination of the following flags is valid. Unused bit fields SHOULD be set to zero by the server and MUST be ignored by the client.

Name & bitmask

Meaning

NO_EAS

0x0001

The file or directory has no extended attributes.

NO_SUBSTREAMS

0x0002

The file or directory has no data streams other than the main data stream.

NO_REPARSETAG

0x0004

The file or directory is not a reparse point.

For all other values of ResourceType, this field SHOULD be set to zero by the server when sending a response and MUST be ignored when received by the client.

VolumeGUID (16 bytes): This field MUST be a GUID value that uniquely identifies the volume on which the file resides. This field MUST be zero if the underlying file system does not support volume GUIDs.<60>

FileId (8 bytes): This field MUST be a 64-bit opaque value that uniquely identifies this file on a volume. This field MUST be set to zero if the underlying file system does not support unique FileId numbers on a volume. If the underlying file system does support unique FileId numbers, then this value SHOULD<61> be set to the unique FileId for this file.

MaximalAccessRight (4 bytes): The maximum access rights that the user opening the file has been granted for this file open. This field MUST be encoded in an ACCESS_MASK format, as specified in section 2.2.1.4.

GuestMaximalAccessRights (4 bytes): The maximum access rights that the guest account has when opening this file. This field MUST be encoded in an ACCESS_MASK format, as specified in section 2.2.1.4. Note that the notion of a guest account is implementation-specific<62>. Implementations that do not support the notion of a guest account MUST set this field to zero.

If the FILE_OPEN_REPARSE_POINT flag bit is set in CreateOptions, and there is a symbolic link error, the server MUST return STATUS_STOPPED_ON_SYMLINK to the client.