Guide To Computer Forensics: 6 Edition
Guide To Computer Forensics: 6 Edition
6TH EDITION
CHAPTER 5
WORKING WITH WINDOWS AND CLI SYSTEMS
OBJECTIVES
File system
Gives OS a road map to data on a disk
On older disks, the space between tracks was wider, which allowed heads to wander
This made it possible for specialists to retrieve data from previous writes to a
platter, even after erasure
– Using an electron microscope
A single pass of zeroes erases all data on a disk so it cannot be recovered by any
currently known technique
Flash memory:
Partition gap
Unused space between partitions
HIDING DATA
Create a partition
Add data to it
Remove references to the partition
Data hidden in partition gap
a disk editor utility could be used to access it
Another technique is to hide incriminating digital evidence at the end of a disk by declaring
a smaller number of bytes than the actual drive size
With disk editing tools, however, you can access these hidden or empty areas of the disk
DISK EDITOR
Maintained by OS
Outlines and describes the partitions on the disk
Two partitioning schemes:
MBR
GPT
MBR PARTITION TABLE
8 0 0 0 0 8 2 1 8 0 0 0 0 4 0 0
0 2 3 0 7 0 7 9 0 0 0 0 0 0 6 0
HPC (Heads per Cylinder) is the number of heads per cylinder. Generally the
manufacturer uses 8 bits to address the number of heads per cylinder. So the
value of HPC is 2^8 – 1 = 255
SPT (Sectors per Track) is the number of sectors on a track. Generally the
manufacturer uses 6 bits to address the sectors in one track. So the value of SPT
is 2^6 – 1 = 63
LBA TO CHS
The file system’s hexadecimal code is offset 3 bytes from 0x1BE for the first partition
The sector address of where this partition starts on the drive is offset 8 bytes from 0x1BE
The number of sectors assigned to the partition are offset 12 bytes for position 0x1BE
HEXADECIMAL CODES OF FILE SYSTEMS
Examining FAT Disks
• FAT versions
– FAT12, FAT16, FAT32, FATX (for Xbox), and VFAT
FAT VERSIONS
An unintentional side effect of FAT16 allowing large clusters was that it reduced
fragmentation
As cluster size increased
EXAMINING FAT DISKS
EXAMINING FAT DISKS
• When the OS stores data in a FAT file system, it assigns a starting cluster
position to a file
– Data for the file is written to the first sector of the first assigned cluster
• When this first assigned cluster is filled and runs out of room
– FAT assigns the next available cluster to the file
• With the HEX E5 (σ) character replacing the first letter of the filename
• Area of the disk where the deleted file resides becomes unallocated disk
space
– Available to receive new data from newly created files or other files needing more space
EXAMINING NTFS DISKS
In the MFT, the first 15 records are reserved for system files
Records in the MFT are called metadata
NTFS FILE SYSTEM
NTFS FILE SYSTEM
MFT AND FILE ATTRIBUTES
Files larger than 512 bytes are stored outside the MFT
MFT record provides cluster addresses where the file is stored on the drive’s partition
Referred to as data runs
Each MFT record starts with a header identifying it as a resident or nonresident attribute
Resident
File in a
MFT
Record
RESIDENT FILE DATA IN THE MFT
When data is first written to nonresident files, an LCN address is assigned to the file
This LCN becomes the file’s virtual cluster number (VCN0)
VCN(1) and other VCNs are the offset of the cluster’s number from the previous VCN
cluster position in the data run
VCNs are signed integers
if the next largest unused disk space is at a lower address than the previous VCN, the lower value address
can be computed by simply adding a negative number to the VCN
MFT STRUCTURES FOR FILE DATA
For the header of all MFT records, the record fields of interest are as follows:
At offset 0x00 - the MFT record identifier FILE
At offset 0x1C to 0x1F - size of the MFT record
At offset 0x14 - length of the header (indicates where the next attribute starts)
At offset 0x32 and 0x33 - the update sequence array, which stores the last 2 bytes of the first
sector of the MFT record. It’s used only when MFT data exceeds 512 bytes. The update sequence
array is used as a checksum for record integrity validation
MFT HEADER FIELDS
ATTRIBUTE 0X10: STANDARD INFORMATION
• For files with filenames of eight or fewer characters, the MFT record has only one
attribute 0x30.
• If a filename is longer than eight characters, there are two attribute
0x30s.
• Offset 0x04 and 0x05 from beginning of attribute 0x30—Size of attribute 0x30.
• Offset 0x20 to 0x27— File’s create date and time; in Win32 Filetime format.
• Offset 0x28 to 0x2F— Last modified date and time for file.
• Offset 0x1FE and 0x1FF from beginning of MFT header— Sector checksum value, used to
validate first 512 bytes of MFT record. Break between the first and second sectors is referred to
as sector boundary. The 2 bytes at positions 0x32 and 0x33 of MFT header in the update
sequence array field are where the actual values for these bytes are stored.
• End of the MFT record is indicated by the hexadecimal values FF FF FF FF at the end of
the record.
ATTRIBUTE 0X80: DATA FOR A RESIDENT
FILE
ATTRIBUTE 0X80: DATA FOR NONRESIDENT
FILE
first data run for a nonresident attribute 0x80 field starts at offset 0x40 from the beginning
of the attribute
Data runs have three components:
The first component declares how many bytes in the attribute field are needed to store the values
for the second and third components.
The second component stores the number of clusters assigned to the data run
The third component contains the starting cluster address value (the LCN or the VCN)
INTERPRETING A DATA RUN
INTERPRETING DATA RUN
You can only tell whether a file has a data stream attached by examining that file’s MFT
entry
NTFS COMPRESSED FILES
Users can apply EFS to files stored on their local workstations or a remote server
EFS RECOVERY KEY AGENT
Commands:
cipher
copy
DELETING NTFS FILES
78
DELETING NTFS FILES
When you delete a file in Windows or File Explorer, you can restore it from the Recycle Bin.
The OS takes the following steps when you delete a file or a folder in Windows or File
Explorer:
Windows changes the filename and moves the file to a subdirectory with a unique identity in the
Recycle Bin.
Windows stores information about the original path and filename in the Info2 file, which is the
control file for the Recycle Bin. It contains ASCII data, Unicode data, and the date and time of
deletion for each file or folder.
DELETING NTFS FILES
NTFS files deleted at a command prompt function much like FAT files.
The following steps also apply when a user empties the Recycle Bin:
The associated clusters are designated as free—that is, marked as available for new data.
The $Bitmap file attribute in the MFT is updated to reflect the file’s deletion, showing that this space
is available.
The file’s record in the MFT is marked as being available.
VCN/LCN cluster locations linked to deleted nonresident files are then removed from the original
MFT record.
A run list is maintained in the MFT of all cluster locations on the disk for nonresident files. When the
list of links is deleted, any reference to the links is lost.