Explain how to write a file in NTFS
Explain how to Delete a file in NTFS
What is NTFS
NTFS - New Technology File System
What are the files that make up an NTFS File System
Where is $BOOT stored
$BOOT is stored in same location for every NTFS volume (Sector 0)
What endian are multi bytes stored in for NTFS
All multibyte structures are stored in LE for NTFS unless otherwise states
Explain how to identify $MFT starting location
Bytes per Sector / Sector Size: 0x0002 (LE) -> 0x0200 = 512 bytes per sector
Number of Sectors per Cluster = 0x08 (BE) -> 8 = 8 sectors per cluster
Cluster size = 512*8 = 4,096 bytes
Starting Cluster of MFT = 0x0400 0000 0000 0000 (LE) = 4
First cluster of MFT is at cluster 4
What is the $MFT file
$MFT - master file table
- Similar to FAT Directory entries
- Contains one file record entry for each file
- Each file entry is usually 1024 bytes
- File Record contains header, and then attributes (metadata)
Explain how to identify the number of attributes for a file
File Record Entry Example:
File Signature: 0x4649 = FILE0
Offset to first attribute: 0x3800 (LE) = 0x0038 (number of bytes in hex of header)
Allocation status: 0x0100 (LE) = 0x01 = Allocated
Number of Attributes: 0400 (LE) = 0x04 = 4 attributes
What are the two types of attributes in NTFS
What is a run list
tells how many clusters are in it and where they are located (by finding two byes at 0x20 in Non-Resident Attribute)
Interpret this run list:
21 03 03 22
21 - add the nibbles of the first byte to get the number of bytes in this portion
- 2 , 1 = nibbles
- 2+1 = 3
- 3 is the number of bytes of run list
The high order nibble(2) = number of bytes in starting cluster
Starting cluster = 03 22 -> (LE) -> 2203 -> 8707(decimal)
Low order nibble (1) = number of bytes in run list length
Number of clusters (length of run list) = 03
Run list contains 3 clusters beginning at 8707
- Would be 8707, 8708, 8709 in total
- Can check with istat ntfs.dd 65
What information is stored in $Standard_Information
-Creation: File creation time
- Modification: File content modification time
- Change: File metadata modification time
- Access: File access / read time