Apple Inc.'s Macintosh OS X (pronounced "'''OS Ten'''") is the operating system distributed with Apple computers. It includes heavily used several programs by default, including [[Apple Mail]], a web browser called [[Apple Safari | Safari]], and an [[Apple Address Book]], and [[iCal]].

+

A Windows Prefetch file consists of one file header and multiple file sections with different content. Not all content has an obvious forensic value.

−

== Disk image types ==

+

As far as have been possible to ascertain, there is no public description of the format. The description below has been synthesised from examination

+

of multiple prefetch files.

−

Mac OS X has support for various disk image types build-in, some of which are:

| The name of the (original) executable as a Unicode (UTF-16 litte-endian string), up to 29 characters and terminated by an end-of-string character (U+0000). This name should correspond with the one in the prefetch file filename.

+

|-

+

| H6

+

|0x004C

+

|4

+

|DWORD

+

|The prefetch hash. This hash value should correspond with the one in the prefetch file filename.

In HFS+ date and time values are stored in an unsigned 32-bit integer containing the number of seconds since January 1, 1904 at 00:00:00 (midnight) UTC (GMT). This is slightly different from HFS where the date and time value are stored using the local time. The maximum representable date is February 6, 2040 at 06:28:15 UTC (GMT). The date values do not account for leap seconds. They do include a leap day in every year that is evenly divisible by four. This is sufficient given that the range of representable dates does not contain 1900 or 2100, neither of which have leap days. Also see: [http://web.archive.org/web/20090214212148/http://developer.apple.com/technotes/tn/tn1150.html Technical Note TN1150 - HFS Plus Volume Format]

+

==== File information - version 23 ====

+

The file information – version 23 is 156 bytes of size and consists of:

+

{| class="wikitable"

+

|-

+

! Field

+

! Offset

+

! Length

+

! Type

+

! Notes

+

|-

+

|

+

| 0x0054

+

| 4

+

| DWORD

+

| The offset to section A. The offset is relative from the start of the file.

+

|-

+

|

+

| 0x0058

+

| 4

+

| DWORD

+

| The number of entries in section A.

+

|-

+

|

+

| 0x005C

+

| 4

+

| DWORD

+

| The offset to section B. The offset is relative from the start of the file.

+

|-

+

|

+

| 0x0060

+

| 4

+

| DWORD

+

| The number of entries in section B.

+

|-

+

|

+

| 0x0064

+

| 4

+

| DWORD

+

| The offset to section C. The offset is relative from the start of the file.

+

|-

+

|

+

| 0x0068

+

| 4

+

| DWORD

+

| Length of section C.

+

|-

+

|

+

| 0x006C

+

| 4

+

| DWORD

+

| Offset to section D. The offset is relative from the start of the file.

+

|-

+

|

+

| 0x0070

+

| 4

+

| DWORD

+

| The number of entries in section D.

+

|-

+

|

+

| 0x0074

+

| 4

+

| DWORD

+

| Length of section D.

+

|-

+

|

+

| <b>0x0078</b>

+

| <b>8</b>

+

| <b>?</b>

+

| <b>Unknown</b>

+

|-

+

|

+

| 0x0080

+

| 8

+

| FILETIME

+

| Latest execution time (or run time) of executable (FILETIME)

+

|-

+

|

+

| 0x0088

+

| 16

+

| ?

+

| Unknown

+

|-

+

|

+

| 0x0098

+

| 4

+

| DWORD

+

| Execution counter (or run count)

+

|-

+

|

+

| 0x009C

+

| 4

+

| DWORD?

+

| Unknown

+

|-

+

|

+

| <b>0x00A0</b>

+

| <b>80</b>

+

| <b>?</b>

+

| <b>Unknown</b>

+

|-

+

|}

−

Converting HFS/HFS+ date and time values with Python:

+

==== File information - version 26 ====

−

<pre>

+

The file information – version 23 is 224 bytes of size and consists of:

−

import datetime

+

{| class="wikitable"

+

|-

+

! Field

+

! Offset

+

! Length

+

! Type

+

! Notes

+

|-

+

|

+

| 0x0054

+

| 4

+

| DWORD

+

| The offset to section A. The offset is relative from the start of the file.

+

|-

+

|

+

| 0x0058

+

| 4

+

| DWORD

+

| The number of entries in section A.

+

|-

+

|

+

| 0x005C

+

| 4

+

| DWORD

+

| The offset to section B. The offset is relative from the start of the file.

+

|-

+

|

+

| 0x0060

+

| 4

+

| DWORD

+

| The number of entries in section B.

+

|-

+

|

+

| 0x0064

+

| 4

+

| DWORD

+

| The offset to section C. The offset is relative from the start of the file.

+

|-

+

|

+

| 0x0068

+

| 4

+

| DWORD

+

| Length of section C.

+

|-

+

|

+

| 0x006C

+

| 4

+

| DWORD

+

| Offset to section D. The offset is relative from the start of the file.

If all the executables and libraries referenced in the C section are from one single disk volume, there will be only one section in the D section. If multiple volumes are referenced by section C, section D will contain multiple sections. (A simple way to force this situation is to copy, say, NOTEPAD.EXE to a USB drive, and start it from that volume. The corresponding prefetch file will have one D header referring to, e.g. \DEVICE\HARDDISK1\DP(1)0-0+4 (the USB drive), and one to, e.g. \DEVICE\HARDDISKVOLUME1\ (where the .DLLs and other support files were found).

−

* [[MacOS Process Monitoring]]

+

−

* [[Acquiring a MacOS System with Target Disk Mode]]

+

−

* [[Converting Binary Plists]]

+

−

* [[FileVault Disk Encryption]]

+

−

* [[File Vault]]

+

−

== External Links ==

+

In this section, all offsets are assumed to be counted from the start of the D section.

Prefetch file size (or length) (sometimes referred to as End of File (EOF)).

H5

0x0010

60

USTR

The name of the (original) executable as a Unicode (UTF-16 litte-endian string), up to 29 characters and terminated by an end-of-string character (U+0000). This name should correspond with the one in the prefetch file filename.

H6

0x004C

4

DWORD

The prefetch hash. This hash value should correspond with the one in the prefetch file filename.

Section B

The actual format and usage of these entry records is currently not known.

Section C - Filename strings

This section contains filenames strings, it consists of an array of UTF-16 little-endian formatted strings with end-of-string characters (U+0000).

At the end of the section there seems to be alignment padding that can contain remnant values.

Section D - Volumes information (block)

Section D contains one or more subsections, each subsection refers to directories on a volume.

If all the executables and libraries referenced in the C section are from one single disk volume, there will be only one section in the D section. If multiple volumes are referenced by section C, section D will contain multiple sections. (A simple way to force this situation is to copy, say, NOTEPAD.EXE to a USB drive, and start it from that volume. The corresponding prefetch file will have one D header referring to, e.g. \DEVICE\HARDDISK1\DP(1)0-0+4 (the USB drive), and one to, e.g. \DEVICE\HARDDISKVOLUME1\ (where the .DLLs and other support files were found).

In this section, all offsets are assumed to be counted from the start of the D section.

Volume information

The structure of the volume information is version dependent.

Volume information - version 17

The volume information – version 17 is 40 bytes in size and consists of: