Host Protected Area
From Wikipedia, the free encyclopedia
Host Protected Area sometimes referred to as Hidden Protected Area[1] is an area of a hard drive that is not normally visible to an operating system(OS).
Contents |
[edit] History
HPA was first introduced in the ATA-4 standard (T13, 2001)[2].
[edit] How It Works
The IDE controller has registers that contain data that can be queried using ATA commands. The data returned gives information about the drive attached to the controller. There are three ATA commands involved in creating and utilizing a Hidden Protected Area. The commands are:
- IDENTIFY DEVICE
- SET MAX ADDRESS
- READ NATIVE MAX ADDRESS
Operating systems use the IDENTIFY DEVICE command to find out the addressable space of a hard drive. The IDENTIFY DEVICE command queries a particular register on the IDE controller to establish the size of a drive.
This register however can be changed using the SET MAX ADDRESS ATA command. If the value in the register is set to less than the actual hard drive size then effectively a Host Protected Area is created. It is protected because the OS will only work with the value in the register that is returned by the IDENTIFY DEVICE command and thus will never be able to address the parts of the drive that lie within the HPA.
The HPA is only useful if other software and or firmware (e.g. BIOS) is able to utilize it. Software and or firmware that are able to utilize the HPA are referred to as 'HPA aware'. The ATA command that these entities use is called READ NATIVE MAX ADDRESS. This command accesses a register that contains the true size of the hard drive. To use the area the controlling HPA aware program changes the value of the register read by IDENTIFY DEVICE with that found in the register read by READ NATIVE MAX ADDRESS, when its operations are complete the register read by IDENTIFY DEVICE is returned to its original fake value.
[edit] Use
- HPA can be used by various booting and diagnostic utilities, normally in conjunction with the BIOS. An example of this implementation is the Phoenix FirstBIOS, which utilizes BEER (Boot Engineering Extension Record) and PARTIES (Protected Area Run-Time Interface Extension Services).
- Computer manufacturers may use the area to contain a preloaded OS for install and recovery purposes (instead of providing DVD or CD media).
- HPA is also used by various theft recovery and monitoring service vendors. For example the laptop security firm Computrace use the HPA to load software that reports to their servers whenever the machine is booted on a network. HPA is useful to them because even when a stolen laptop has its hard drive formatted the HPA remains untouched.
- HPA can also be used to store data that is deemed illegal and is thus of interest to government and police computer forensics teams.
[edit] Identification and Manipulation
Identification of HPA on a hard drive can be achieved by a number of tools and methods.
- Tools
The Sleuth Kit by Brian Carrier.
The ATA Forensics Tool TAFT[3] by Arne Vidstrom.
EnCase by Guidance Software
- Methods
Using Linux, there are a couple of ways to detect the existence of an HPA. The latest Linux versions will print a message when the system is booting. For example:
dmesg | less [...] hdb: Host Protected Area detected.
current capacity is 12000 sectors (6 MB) native capacity is 120103200 sectors (61492 MB)
Another method involves comparing the number of sectors output from 'hdparm -I' with the number of sectors reported for the hard drive model's published statistics.