_FILE_OBJECTID_INFORMATION structure

The FILE_OBJECTID_INFORMATION structure is used to query for object ID information for the files in a directory on an NTFS volume.

Syntax

typedef struct _FILE_OBJECTID_INFORMATION {
  LONGLONG FileReference;
  UCHAR    ObjectId[16];
  union {
    struct {
      UCHAR BirthVolumeId[16];
      UCHAR BirthObjectId[16];
      UCHAR DomainId[16];
    } DUMMYSTRUCTNAME;
    UCHAR ExtendedInfo[48];
  } DUMMYUNIONNAME;
} FILE_OBJECTID_INFORMATION, *PFILE_OBJECTID_INFORMATION;

Members

FileReference

The 8-byte file reference number for the file. NTFS generates this number and assigns it to the file automatically when the file is created.

ObjectId

The 16-byte file object ID for the file. NTFS generates this number and assigns it to the file at the request of a driver or application. File object IDs are guaranteed to be unique only within the volume where the file resides.

DUMMYUNIONNAME.ExtendedInfo

User-provided data. You can use it to contain the BirthVolumeID, BirthObjectID, and DomainID members, or you can define a different data structure.

Remarks

This information can be queried in either of the following ways:

  • Call ZwQueryDirectoryFile, passing FileObjectIdInformation as the value of FileInformationClass and passing a caller-allocated, FILE_OBJECTID_INFORMATION-structured buffer as the value of FileInformation.

  • Create an IRP with major function code IRP_MJ_DIRECTORY_CONTROL and minor function code IRP_MN_QUERY_DIRECTORY.

No special access rights are required to query for this information.

Support for file reference numbers and file object IDs is file system-specific. File object IDs are supported only on NTFS volumes on Microsoft Windows 2000 and later. NTFS allows files to be opened by object ID as well as by file reference number.

File system filter drivers that use file object IDs should be tested for interoperability with DFS, the Replicator service, and the Distributed Link Tracking service, all of which use and manipulate file object IDs.

This structure must be aligned on a LONG (4-byte) boundary.

Requirements

   
Windows version This structure is available on Microsoft Windows 2000 and later. This structure is available on Microsoft Windows 2000 and later.
Header ntifs.h (include Ntifs.h, Fltkernel.h)

See Also

FILE_INTERNAL_INFORMATION

IRP_MJ_DIRECTORY_CONTROL

ZwQueryDirectoryFile