Skip to content

Firefox disk cache format

There are multiple versions of the Firefox Disk Cache format:

  • Cache version 1
  • Cache version 2 - default as of firefox 32 1

Cache version 1

The Cache directory contains the multiple type of cache files:

  • Cache Map File
  • Cache Block File
  • Cache Data File

Cache Map file

File named CACHE_MAP

Contains:

  • Cache Map file header
  • An array of Cache Map buckets

There are 32 buckets in the Cache map file. Within each bucket, there are 256 records inside each bucket, hence the Cache Map file contains 8192 records in total.

Each record contains the information for one instance of cache data. A record contains four 32-bit integers:

  • A Hash Number
  • An Eviction Rank
  • The Data Location
  • The Metadata Location

Cache Block file

File named CACHE_00#, where # is a number ranging from [1-3].

Cache Data File

File named:

<hash number><type><generation number>

Where , , are placeholders for the corresponding values.

Cache version 2

cache2/index
cache2/doomed/*
cache2/entries/*

See Also