2.1.1.5 Per Stream

The object store MUST implement the following persistent attributes:

  • StreamType: The type of stream. This value MUST be DataStream, DirectoryStream, or ViewIndexStream. <34>

  • Name: A Unicode string of less than 256 characters specifying the name of the stream. Valid characters for a stream name are specified in [MS-FSCC] section 2.1.5.3. If StreamType is DataStream, Name could be empty; this case indicates the default data stream. If StreamType is DirectoryStream, Name MUST be empty.

  • Size: A 64-bit unsigned integer containing the size of the stream, in bytes.

  • AllocationSize: A 64-bit unsigned integer containing the size, in bytes, of space reserved on the disk. This value MUST be a multiple of File.Volume.ClusterSize.

  • ValidDataLength: A 64-bit unsigned integer containing the size, in bytes, of valid data in the stream. Not all file systems support this field, and implementation of this field is optional. If implemented, all data beyond this value MUST be returned as zero. For a DataStream, this value MUST be less than or equal to Size. For a DirectoryStream, this value MUST be equal to Size.

  • File: The File in which the stream resides.

  • IsCompressed: A Boolean that is TRUE if the contents of the stream are compressed.<35>

  • ChecksumAlgorithm: A 16-bit unsigned integer that contains the integrity state of the stream as defined by [MS-FSCC] section 2.3.20.<36>

  • IsChecksumEnforcementOff: A Boolean that is TRUE if the stream is a DataStream and CHECKSUM_ENFORCEMENT_OFF is specified.<37>

  • IsSparse: A Boolean that is TRUE if the object store is storing a sparse representation of the stream.<38>

  • IsTemporary: A Boolean that is TRUE if the object store optimizes its management of the stream because it is pending deletion.

  • IsEncrypted: A Boolean that is TRUE if the contents of the stream are encrypted.<39>

  • ExtentList: A list containing zero or more EXTENTS elements as defined by [MS-FSCC] section 2.3.32.1, ordered by NextVcn.

  • ExtentAndRefCountList: A list containing zero or more EXTENT_AND_REFCOUNTS elements and their reference counts as defined by [MS-FSCC] section 2.3.34.1, ordered by NextVcn.

Volatile Fields:

  • Oplock: An Oplock describing the opportunistic lock state of the stream. If Oplock is empty, there is no opportunistic lock on the stream.

  • ByteRangeLockList: A list of zero or more ByteRangeLocks describing the bytes ranges of this stream that are currently locked.

  • IsDeleted: A Boolean that is TRUE if there is a pending delete operation on the Stream. New opens to Stream MUST NOT be allowed.

  • IsDefectManagementDisabled: A Boolean that is TRUE if software defect management is disabled on this stream. Not all file systems support this field; implementation of this field is optional.

  • PendingNotifications: A 32-bit unsigned integer composed of flags indicating types of changes to stream attributes for which directory change notifications are pending, as specified in [MS-SMB2] section 2.2.35, CompletionFilter field.

  • ZeroOnDeallocate: A Boolean that is TRUE when the object store MUST write zeroes to any range of the stream that is to be deallocated, prior to performing the deallocation. This helps to protect data in the stream from discovery by examining free space on the storage media. Not all file systems support this field, and implementation of this field is optional.