Changes by: antona
Update of /cvsroot/linux-ntfs/linux-ntfs/include
In directory usw-pr-cvs1:/tmp/cvs-serv21985
Modified Files:
attrib.h
Log Message:
Finished entering security related headers.
Index: attrib.h
===================================================================
RCS file: /cvsroot/linux-ntfs/linux-ntfs/include/attrib.h,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -r1.10 -r1.11
*** attrib.h 2001/03/03 00:11:17 1.10
--- attrib.h 2001/03/03 06:52:39 1.11
***************
*** 58,61 ****
--- 58,84 ----
/*
* The collation rules for sorting views/indexes/etc (32-bit).
+ *
+ * COLLATION_NTOFS_ULONG - Sorting is done according to ascending __u32 key
+ * values. E.g. used for $SII index in FILE_$Secure, which sorts by
+ * security_id (__u32).
+ * COLLATION_NTOFS_SID - Sorting is done according to ascending SID values.
+ * E.g. used for $O index in FILE_$Extend/$Quota.
+ * COLLATION_NTOFS_SECURITY_HASH - Sorting is done first by ascending hash
+ * values and second by ascending security_id values. E.g. used for $SDH
+ * index in FILE_$Secure.
+ * COLLATION_NTOFS_ULONGS - Sorting is done according to a sequence of ascending
+ * __u32 key values. E.g. used for $O index in FILE_$Extend/$ObjId, which
+ * sorts by object_id (16-byte), by splitting up the object_id in four
+ * __u32 values and using them as individual keys. E.g. take the following
+ * two security_ids, stored as follows on disk:
+ * 1st: a1 61 65 b7 65 7b d4 11 9e 3d 00 e0 81 10 42 59
+ * 2nd: 38 14 37 d2 d2 f3 d4 11 a5 21 c8 6b 79 b1 97 45
+ * To compare them, they are split into four __u32 values each, like so:
+ * 1st: 0xb76561a1 0x11d47b65 0xe0003d9e 0x59421081
+ * 2nd: 0xd2371438 0x11d4f3d2 0x6bc821a5 0x4597b179
+ * Now, it is apparent why the 2nd object_id collates after the 1st: the
+ * first __u32 value of the 1st object_id is less than the first __u32 of
+ * the 2nd object_id. If the first __u32 values of both object_ids were
+ * equal then the second __u32 values would be compared, etc.
*/
typedef enum {
***************
*** 72,85 ****
case value collates before
the lower case one. */
! COLLATION_NTOFS_ULONG = cpu_to_le32(16), /* ??? */
! COLLATION_NTOFS_SID = cpu_to_le32(17), /* ??? */
! COLLATION_NTOFS_SECURITY_HASH = cpu_to_le32(18), /* ??? */
! COLLATION_NTOFS_ULONGS = cpu_to_le32(19), /* ??? */
} COLLATION_RULE;
/*
* The flags (32-bit) describing attribute properties in the attribute
! * definition structure. This information is not certain and probably
! * incomplete.
*/
typedef enum {
--- 95,108 ----
case value collates before
the lower case one. */
! COLLATION_NTOFS_ULONG = cpu_to_le32(16),
! COLLATION_NTOFS_SID = cpu_to_le32(17),
! COLLATION_NTOFS_SECURITY_HASH = cpu_to_le32(18),
! COLLATION_NTOFS_ULONGS = cpu_to_le32(19),
} COLLATION_RULE;
/*
* The flags (32-bit) describing attribute properties in the attribute
! * definition structure. FIXME: This information is not certain and probably
! * incomplete. (AIA)
*/
typedef enum {
***************
*** 277,290 ****
/* 40*/ __s64 allocated_size; /* Byte size of disk space allocated to hold
the attribute value. Always is a multiple of
! the cluster size. */
/* 48*/ __s64 data_size; /* Byte size of the attribute value. Can be
larger than allocated_size if attribute
value is compressed or sparse. */
/* 56*/ __s64 initialized_size; /* Byte size of initialized portion of the
! attribute value. FIXME: Multiple of cluster
! size? (AIA) */
/* 64*/ __s64 compressed_size; /* Byte size of the attribute value after
compression. Only present when compressed.
! FIXME: Multiple of cluster size? (AIA) */
/* sizeof() = 72 bytes (when compressed, otherwise = 64 bytes) */
} __attribute__ ((__packed__)) NONRESIDENT_ATTRIBUTE_RECORD_HEADER;
--- 300,319 ----
/* 40*/ __s64 allocated_size; /* Byte size of disk space allocated to hold
the attribute value. Always is a multiple of
! the cluster size. When a file is compressed,
! this field is a multiple of the compression
! block size (2^compression_unit) and it
! represents the logically allocated space
! rather than the actual on disk usage. For
! this use the compressed_size (see below). */
/* 48*/ __s64 data_size; /* Byte size of the attribute value. Can be
larger than allocated_size if attribute
value is compressed or sparse. */
/* 56*/ __s64 initialized_size; /* Byte size of initialized portion of the
! attribute value. Usually equals data_size. */
/* 64*/ __s64 compressed_size; /* Byte size of the attribute value after
compression. Only present when compressed.
! Always is a multiple of the cluster size.
! Represents the actual amount of disk space
! being used on the disk. */
/* sizeof() = 72 bytes (when compressed, otherwise = 64 bytes) */
} __attribute__ ((__packed__)) NONRESIDENT_ATTRIBUTE_RECORD_HEADER;
***************
*** 317,323 ****
FILE_ATTRIBUTE_COMPRESSED = cpu_to_le32(0x00000800),
! FILE_ATTRIBUTE_OFFLINE = cpu_to_le32(0x00001000),
! FILE_ATTRIBUTE_NOT_CONTENT_INDEXED = cpu_to_le32(0x00002000),
! FILE_ATTRIBUTE_ENCRYPTED = cpu_to_le32(0x00004000),
FILE_ATTRIBUTE_VALID_FLAGS = cpu_to_le32(0x00007fb7),
--- 346,352 ----
FILE_ATTRIBUTE_COMPRESSED = cpu_to_le32(0x00000800),
! FILE_ATTRIBUTE_OFFLINE = cpu_to_le32(0x00001000),
! FILE_ATTRIBUTE_NOT_CONTENT_INDEXED = cpu_to_le32(0x00002000),
! FILE_ATTRIBUTE_ENCRYPTED = cpu_to_le32(0x00004000),
FILE_ATTRIBUTE_VALID_FLAGS = cpu_to_le32(0x00007fb7),
***************
*** 400,423 ****
/* 42*/ __u32 class_id; /* Class id from bidirectional class id
index (?). */
! /* 46*/ __u32 owner_id; /* Id for file owner, from bidir security
! index. This is also used to find the quota
! associated with this file, as an index into
! FILE_$Extend/$Quota. Is zero if quotas are
! disabled. */
! /* 50*/ __u32 security_id; /* Security id for the file. Translate via
$SII index and $SDS data stream in
FILE_$Secure to the security descriptor. */
/* 54*/ __u64 quota_charged; /* Byte size of the charge to the quota for
! all streams of the file. Is zero if quotas
! are disabled. */
/* 62*/ __u64 usn; /* Last update sequence number of the file. This
! is a direct index into the change (aka Usn)
! journal file. It is zero if the journal is
! disabled.
NOTE: To disable the journal need to delete
the journal file itself and to then walk the
whole mft and set all Usn entries in all mft
records to zero! (This can take a while!)
! The journal is /$Extend/UsnJrnl. Windows 2k
will recreate the journal and initiate
logging if necessary when mounting the
--- 429,452 ----
/* 42*/ __u32 class_id; /* Class id from bidirectional class id
index (?). */
! /* 46*/ __u32 owner_id; /* Owner_id of the user owning the file.
! Translate via $Q index in FILE_$Extend/
! $Quota to the quota control entry for the
! user owning the file. Note: Is zero if
! quotas are disabled. */
! /* 50*/ __u32 security_id; /* Security_id for the file. Translate via
$SII index and $SDS data stream in
FILE_$Secure to the security descriptor. */
/* 54*/ __u64 quota_charged; /* Byte size of the charge to the quota for
! all streams of the file. Note: Is zero if
! quotas are disabled. */
/* 62*/ __u64 usn; /* Last update sequence number of the file. This
! is a direct index into the change (aka usn)
! journal file. It is zero if the usn journal
! is disabled.
NOTE: To disable the journal need to delete
the journal file itself and to then walk the
whole mft and set all Usn entries in all mft
records to zero! (This can take a while!)
! The journal is FILE_$Extend/$UsnJrnl. Win2k
will recreate the journal and initiate
logging if necessary when mounting the
***************
*** 583,608 ****
} __attribute__ ((__packed__)) GUID;
/*
! * Attribute: Object id (0x40).
*
* NOTE: Always resident.
*/
typedef struct {
- //MFT_REFERENCE file_system_reference; /* Is it this structure or */
- //__u8 extended_info[48]; /* the one declared below?!? */
- //} __attribute__ ((__packed__)) OBJECT_ID_ATTRIBUTE;
- // It is the one below. The thing above is one of the keys in an index in the
- // FILE_$Secure. (?) (AIA)
GUID object_id; /* Unique id assigned to the
file.*/
union {
struct {
GUID birth_volume_id; /* Unique id of volume on which
! the file was first created.
! NOTE: Optional. */
GUID birth_object_id; /* Unique id of file when it was
! first created.
! NOTE: Optional. */
! GUID domain_id; /* Reserved. NOTE: Optional. */
} __attribute__ ((__packed__));
__u8 extended_info[48];
--- 612,660 ----
} __attribute__ ((__packed__)) GUID;
+ /*
+ * This is the index entry key of the $O index in FILE_$Extend/$ObjId.
+ */
+ typedef struct {
+ GUID object_id; /* The object_id assigned to the mft record. */
+ } __attribute__ ((__packed__)) OBJ_ID_INDEX_KEY;
+
/*
! * This is the index entry data part of the $O index in FILE_$Extend/$ObjId.
! */
! typedef struct {
! MFT_REFERENCE mft_reference; /* Mft record containing this object_id. */
! union {
! struct {
! GUID birth_volume_id; /* object_id of FILE_$Volume of
! the volume on which the file
! was first created. Optional
! (can be zero). */
! GUID birth_object_id; /* object_id of file when it was
! first created. Usually equals
! the object_id. Optional (can
! be zero). */
! GUID domain_id; /* Reserved (always zero). */
! } __attribute__ ((__packed__));
! __u8 extended_info[48];
! } __attribute__ ((__packed__));
! } __attribute__ ((__packed__)) O_INDEX_DATA;
!
! /*
! * Attribute: Object id (NTFS 3.0+) (0x40).
*
* NOTE: Always resident.
*/
typedef struct {
GUID object_id; /* Unique id assigned to the
file.*/
+ /* The following fields are optional. The object_id attribute value
+ size is 16 bytes, i.e. sizeof(GUID), if these are not present. */
union {
struct {
GUID birth_volume_id; /* Unique id of volume on which
! the file was first created.*/
GUID birth_object_id; /* Unique id of file when it was
! first created. */
! GUID domain_id; /* Reserved. */
} __attribute__ ((__packed__));
__u8 extended_info[48];
***************
*** 771,782 ****
* revision = 1,
* sub_authority_count = 2,
! * identifier_authority = 5, // SECURITY_NT_AUTHORITY
! * sub_authority[0] = 32, // SECURITY_BUILTIN_DOMAIN_RID
! * sub_authority[1] = 544 // DOMAIN_ALIAS_RID_ADMINS
*/
typedef struct {
__u8 revision;
__u8 sub_authority_count;
! SID_IDENTIFIER_AUTHORITY identifier_autority;
__u32 sub_authority[1]; /* At least one sub_authority. */
} __attribute__ ((__packed__)) SID;
--- 823,834 ----
* revision = 1,
* sub_authority_count = 2,
! * identifier_authority = {0,0,0,0,0,5}, // SECURITY_NT_AUTHORITY
! * sub_authority[0] = 32, // SECURITY_BUILTIN_DOMAIN_RID
! * sub_authority[1] = 544 // DOMAIN_ALIAS_RID_ADMINS
*/
typedef struct {
__u8 revision;
__u8 sub_authority_count;
! SID_IDENTIFIER_AUTHORITY identifier_authority;
__u32 sub_authority[1]; /* At least one sub_authority. */
} __attribute__ ((__packed__)) SID;
***************
*** 894,898 ****
* The generic mapping array. Used to denote the mapping of each generic
* access right to a specific access mask.
! * FIXME: WTH does this mean?!? (AIA)
*/
typedef struct {
--- 946,951 ----
* The generic mapping array. Used to denote the mapping of each generic
* access right to a specific access mask.
! *
! * FIXME: What exactly is this and what is it for? (AIA)
*/
typedef struct {
***************
*** 1050,1059 ****
SID is present in the descriptor. */
__u32 sacl; /* Byte offset to a system ACL. Only valid, if
! SE_DACL_PRESENT is set in the control field. If
! SE_DACL_PRESENT is set but sacl is NULL, a NULL ACL
is specified. */
__u32 dacl; /* Byte offset to a discretionary ACL. Only valid, if
! SE_SACL_PRESENT is set in the control field. If
! SE_SACL_PRESENT is set but dacl is NULL, a NULL ACL
(unconditionally granting access) is specified. */
} __attribute__ ((__packed__)) SECURITY_DESCRIPTOR_RELATIVE;
--- 1103,1112 ----
SID is present in the descriptor. */
__u32 sacl; /* Byte offset to a system ACL. Only valid, if
! SE_SACL_PRESENT is set in the control field. If
! SE_SACL_PRESENT is set but sacl is NULL, a NULL ACL
is specified. */
__u32 dacl; /* Byte offset to a discretionary ACL. Only valid, if
! SE_DACL_PRESENT is set in the control field. If
! SE_DACL_PRESENT is set but dacl is NULL, a NULL ACL
(unconditionally granting access) is specified. */
} __attribute__ ((__packed__)) SECURITY_DESCRIPTOR_RELATIVE;
***************
*** 1078,1087 ****
present in the descriptor. */
ACL *sacl; /* Points to a system ACL. Only valid, if
! SE_DACL_PRESENT is set in the control field. If
! SE_DACL_PRESENT is set but sacl is NULL, a NULL ACL
is specified. */
ACL *dacl; /* Points to a discretionary ACL. Only valid, if
! SE_SACL_PRESENT is set in the control field. If
! SE_SACL_PRESENT is set but dacl is NULL, a NULL ACL
(unconditionally granting access) is specified. */
} __attribute__ ((__packed__)) SECURITY_DESCRIPTOR;
--- 1131,1140 ----
present in the descriptor. */
ACL *sacl; /* Points to a system ACL. Only valid, if
! SE_SACL_PRESENT is set in the control field. If
! SE_SACL_PRESENT is set but sacl is NULL, a NULL ACL
is specified. */
ACL *dacl; /* Points to a discretionary ACL. Only valid, if
! SE_DACL_PRESENT is set in the control field. If
! SE_DACL_PRESENT is set but dacl is NULL, a NULL ACL
(unconditionally granting access) is specified. */
} __attribute__ ((__packed__)) SECURITY_DESCRIPTOR;
***************
*** 1167,1171 ****
* manager). Each security descriptor is contained in a SDS_ENTRY structure.
* Also, each security descriptor is stored twice in the $SDS stream with a
! * fixed offset of XYZ bytes between them.
*/
typedef struct {
--- 1220,1224 ----
* manager). Each security descriptor is contained in a SDS_ENTRY structure.
* Also, each security descriptor is stored twice in the $SDS stream with a
! * fixed offset of ??? bytes between them.
*/
typedef struct {
***************
*** 1176,1180 ****
/*
! * The index entry key used in the $SII index.
*/
typedef struct {
--- 1229,1234 ----
/*
! * The index entry key used in the $SII index. The collation type is
! * COLLATION_NTOFS_ULONG.
*/
typedef struct {
***************
*** 1183,1188 ****
/*
! * The index entry key used in the $SDH index. The keys are sorted by first by
! * hash and then by security_id.
*/
typedef struct {
--- 1237,1243 ----
/*
! * The index entry key used in the $SDH index. The keys are sorted first by
! * hash and then by security_id. The collation rule is
! * COLLATION_NTOFS_SECURITY_HASH.
*/
typedef struct {
***************
*** 1344,1347 ****
--- 1399,1494 ----
/*
+ * The system file FILE_$Extend/$Reparse contains an index named $R listing
+ * all reparse points on the volume. The index entry keys are as defined
+ * below. Note, that there is no index data associated with the index entries.
+ *
+ * The index entries are sorted by the index key file_id. The collation rule is
+ * COLLATION_NTOFS_ULONGS. FIXME: Verify whether the reparse_tag is not the
+ * primary key / is not a key at all. (AIA)
+ */
+ typedef struct {
+ __u32 reparse_tag; /* Reparse point type (inc. flags). */
+ MFT_REFERENCE file_id; /* Mft record of the file containing the
+ reparse point attribute. */
+ } __attribute__ ((__packed__)) REPARSE_INDEX_KEY;
+
+ /*
+ * The system file FILE_$Extend/$Quota contains two indexes $O and $Q. Quotas
+ * are on a per volume and per user basis.
+ *
+ * The $O index contains one entry for each user/group who has been assigned
+ * a quota on that volume. The index key holds the variable length SID of the
+ * user/group the entry belongs to. The collation rule is COLLATION_NTOFS_SID.
+ *
+ * The $O index entry data is the user_id of the user corresponding to the SID.
+ * The user_id is used as an index into $Q to find the quota control entry
+ * associated with the SID in the index key. The user_id is stored as the
+ * owner_id in the standard information attribute of each base mft record.
+ */
+ typedef struct {
+ SID sid; /* SID of the owner of the user_id. */
+ } __attribute__ ((__packed__)) QUOTA_O_INDEX_KEY;
+
+ /*
+ * Predefined user/owner_id values (32-bit).
+ */
+ typedef enum {
+ QUOTA_INVALID_ID = cpu_to_le32(0x00000000),
+ QUOTA_DEFAULTS_ID = cpu_to_le32(0x00000001),
+ QUOTA_FIRST_USER_ID = cpu_to_le32(0x00000100),
+ } PREDEFINED_OWNER_IDS;
+
+ /*
+ * Quota flags (32-bit).
+ */
+ typedef enum {
+ /* The user quota flags. Names explain meaning. */
+ QUOTA_FLAG_DEFAULT_LIMITS = cpu_to_le32(0x00000001),
+ QUOTA_FLAG_LIMIT_REACHED = cpu_to_le32(0x00000002),
+ QUOTA_FLAG_ID_DELETED = cpu_to_le32(0x00000004),
+
+ QUOTA_FLAG_USER_MASK = cpu_to_le32(0x00000007),
+ /* Bit mask for user quota flags. */
+
+ /* These flags are only present in the quota defaults index entry,
+ i.e. in the entry where owner_id = QUOTA_DEFAULTS_ID. */
+ QUOTA_FLAG_TRACKING_ENABLED = cpu_to_le32(0x00000010),
+ QUOTA_FLAG_ENFORCEMENT_ENABLED = cpu_to_le32(0x00000020),
+ QUOTA_FLAG_TRACKING_REQUESTED = cpu_to_le32(0x00000040),
+ QUOTA_FLAG_LOG_THRESHOLD = cpu_to_le32(0x00000080),
+ QUOTA_FLAG_LOG_LIMIT = cpu_to_le32(0x00000100),
+ QUOTA_FLAG_OUT_OF_DATE = cpu_to_le32(0x00000200),
+ QUOTA_FLAG_CORRUPT = cpu_to_le32(0x00000400),
+ QUOTA_FLAG_PENDING_DELETES = cpu_to_le32(0x00000800),
+ } QUOTA_FLAGS;
+
+ /*
+ * The $Q index in FILE_$Extend/$Quota contains one entry for each existing
+ * user/owner_id on the volume. The index key is the (32-bit) user/owner_id of
+ * the user/group to whom this quota control entry belongs (found in the
+ * standard information attribute). The collation rule is COLLATION_NTOFS_ULONG.
+ */
+ typedef union {
+ __u32 user_id;
+ __u32 owner_id;
+ } __attribute__ ((__packed__)) QUOTA_O_INDEX_KEY;
+
+ /*
+ * The $Q index entry data is defined as follows:
+ */
+ typedef struct {
+ __u32 version; /* Currently equals 2. */
+ QUOTA_FLAGS flags; /* Flags describing this quota entry. */
+ __u64 bytes_used; /* How many bytes of the quota are in use. */
+ __u64 change_time; /* Last time this quota entry was changed. */
+ __s64 threshold; /* Soft quota (-1 if not limited). */
+ __s64 limit; /* Hard quota (-1 if not limited). */
+ __u64 exceeded_time; /* How long the soft quota has been exceeded. */
+ SID sid; /* The SID of the user/object associated with
+ this quota entry. Equals zero for the quota
+ defaults entry. */
+ } __attribute__ ((__packed__)) QUOTA_CONTROL_ENTRY, QUOTA_INDEX_DATA;
+
+ /*
* Index entry flags (16-bit).
*/
***************
*** 1359,1373 ****
/*
- * The system file FILE_$Extend/$Reparse contains an index listing all reparse
- * points on the volume. The index entry keys are as defined below.
- * Note: There is no data associated with the index entries.
- */
- typedef struct {
- __u32 reparse_tag; /* Reparse point type (inc. flags). */
- MFT_REFERENCE file_id; /* Mft record of the file containing the
- reparse point attribute. */
- } __attribute__ ((__packed__)) REPARSE_INDEX_KEY;
-
- /*
* This is an index entry. A sequence of such entries follows each INDEX_HEADER
* structure. Together they make up a complete index. The index follows either
--- 1506,1509 ----
***************
*** 1383,1406 ****
indexes. */
struct { /* Used for views/indexes to find the entry's data. */
! __u16 data_offset; /* Data byte offset. */
__u16 data_length; /* Data length in bytes. */
__u32 reserved; /* Reserved (zero). */
} __attribute__ ((__packed__));
} __attribute__ ((__packed__));
! __u16 length; /* Byte size of this index entry. */
! __u16 attribute_length; /* Byte size of the attribute value,
! which is in the index entry. It
! starts just after reserved entry. */
! INDEX_ENTRY_FLAGS flags; /* Bit field of INDEX_ENTRY_* flags. */
! __u16 reserved; /* Reserved/align to 8-byte boundary. */
union { /* The key of the indexed attribute. NOTE: Only present
if INDEX_ENTRY_END bit in flags is not set. NOTE: On
NTFS versions before 3.0 the only valid key is the
! FILENAME_ATTRIBUTE. */
! FILENAME_ATTRIBUTE filename; /* Used in directory indexes. */
! SII_INDEX_KEY sii; /* Used in $SII index. */
! SDH_INDEX_KEY sdh; /* Used in $SDH index. */
! REPARSE_INDEX_KEY reparse; /* Used in $Reparse index. */
} __attribute__ ((__packed__));
// __s64 vcn; /* If INDEX_ENTRY_NODE bit in flags is set, the last
// eight bytes of this index entry contain the virtual
--- 1519,1548 ----
indexes. */
struct { /* Used for views/indexes to find the entry's data. */
! __u16 data_offset; /* Data byte offset from this
! INDEX_ENTRY. Follows the
! index key. */
__u16 data_length; /* Data length in bytes. */
__u32 reserved; /* Reserved (zero). */
} __attribute__ ((__packed__));
} __attribute__ ((__packed__));
! __u16 length; /* Byte size of this index entry. */
! __u16 key_length; /* Byte size of the key value, which is in the
! index entry. It follows field reserved. */
! INDEX_ENTRY_FLAGS flags; /* Bit field of INDEX_ENTRY_* flags. */
! __u16 reserved; /* Reserved/align to 8-byte boundary. */
union { /* The key of the indexed attribute. NOTE: Only present
if INDEX_ENTRY_END bit in flags is not set. NOTE: On
NTFS versions before 3.0 the only valid key is the
! FILENAME_ATTRIBUTE. On NTFS 3.0+ the following
! additional index keys are defined: */
! FILENAME_ATTRIBUTE filename; /* Directory indexes. */
! SII_INDEX_KEY sii; /* $SII index in $Secure. */
! SDH_INDEX_KEY sdh; /* $SDH index in $Secure. */
! OBJ_ID_INDEX_KEY obj_id; /* $O index in $ObjId. */
! REPARSE_INDEX_KEY reparse; /* $R index in $Reparse. */
! QUOTA_O_INDEX_KEY quota_o; /* $O index in $Quota. */
! QUOTA_Q_INDEX_KEY quota_q; /* $Q index in $Quota. */
} __attribute__ ((__packed__));
+ /* The (optional) index data is inserted here. */
// __s64 vcn; /* If INDEX_ENTRY_NODE bit in flags is set, the last
// eight bytes of this index entry contain the virtual
***************
*** 1432,1437 ****
* Attribute: Reparse point (0xc0).
*
! * FIXME: Describe more about reparse points here including the flags in the
! * ReparseTag.
*/
typedef struct {
--- 1574,1579 ----
* Attribute: Reparse point (0xc0).
*
! * FIXME: Describe more about reparse points here, including the flags in the
! * reparse_tag.
*/
typedef struct {
***************
*** 1494,1553 ****
*
* Operations on this attribute are logged to the journal ($LogFile) like
! * normal metadata changes. Used by the Encrypting File System (EFS).
*/
typedef struct {
/* Can be anything the creator chooses. */
! } __attribute__ ((__packed__)) LOGGED_UTILITY_STREAM;
!
! /*
! * Predefined owner_ids (32-bit).
! */
! typedef enum {
! QUOTA_INVALID_ID = cpu_to_le32(0x00000000),
! QUOTA_DEFAULTS_ID = cpu_to_le32(0x00000001),
! QUOTA_FIRST_USER_ID = cpu_to_le32(0x00000100),
! } PREDEFINED_OWNER_ID;
!
! /*
! * Quota flags (32-bit).
! */
! typedef enum {
! /* The user quota flags. Names, explain meaning. */
! QUOTA_FLAG_DEFAULT_LIMITS = cpu_to_le32(0x00000001),
! QUOTA_FLAG_LIMIT_REACHED = cpu_to_le32(0x00000002),
! QUOTA_FLAG_ID_DELETED = cpu_to_le32(0x00000004),
!
! QUOTA_FLAG_USER_MASK = cpu_to_le32(0x00000007),
! /* Bit mask for user quota flags. */
!
! /* These flags are only present in the quota defaults index entry,
! i.e. in the entry where owner_id = QUOTA_DEFAULTS_ID. */
! QUOTA_FLAG_TRACKING_ENABLED = cpu_to_le32(0x00000010),
! QUOTA_FLAG_ENFORCEMENT_ENABLED = cpu_to_le32(0x00000020),
! QUOTA_FLAG_TRACKING_REQUESTED = cpu_to_le32(0x00000040),
! QUOTA_FLAG_LOG_THRESHOLD = cpu_to_le32(0x00000080),
! QUOTA_FLAG_LOG_LIMIT = cpu_to_le32(0x00000100),
! QUOTA_FLAG_OUT_OF_DATE = cpu_to_le32(0x00000200),
! QUOTA_FLAG_CORRUPT = cpu_to_le32(0x00000400),
! QUOTA_FLAG_PENDING_DELETES = cpu_to_le32(0x00000800),
! } QUOTA_FLAGS;
!
! /*
! * The system file FILE_$Extend/$Quota contains an index listing all quota
! * entries (one for each user/object being subject to a quota) for the volume.
! * The index entry data is defined as below and the key for the index entries
! * is the owner_id (found in the standard information attribute).
! */
! typedef struct {
! __u32 version; /* Currently equals 2. */
! QUOTA_FLAGS flags; /* Flags describing this quota entry. */
! __u64 bytes_used; /* How many bytes of the quota are in use. */
! __u64 change_time; /* Last time this quota entry was changed. */
! __u64 threshold; /* Soft quota. */
! __u64 limit; /* Hard quota. */
! __u64 exceeded_time; /* How long the soft quota has been exceeded. */
! SID sid; /* The SID of the user/object associated with
! this quota data. */
! } QUOTA_USER_DATA;
/* min macro used in attrib.c */
--- 1636,1649 ----
*
* Operations on this attribute are logged to the journal ($LogFile) like
! * normal metadata changes.
! *
! * Used by the Encrypting File System (EFS). All encrypted files have this
! * attribute with the name $EFS.
*/
typedef struct {
/* Can be anything the creator chooses. */
! /* EFS uses it as follows: */
! // FIXME: Type this info, verifying it along the way. (AIA)
! } __attribute__ ((__packed__)) LOGGED_UTILITY_STREAM, EFS_ATTRIBUTE;
/* min macro used in attrib.c */
|