Skip to content

LocationSecurity & malware

locationd: cache_encryptedB.db and clients.plist

iOS locationd data: which apps used Location Services in clients.plist, and cell and Wi-Fi location caches in cache_encryptedB.db, with caveats.

Location
/private/var/root/Library/Caches/locationd/ (cache_encryptedA.db, cache_encryptedB.db, cache_encryptedC.db, clients.plist); clients.plist in backups: RootDomain, Library/Caches/locationd/clients.plist
Proves
clients.plist: which apps and system services were authorised to use location and when they last did. Caches: cell towers and Wi-Fi access points the device looked up or harvested, with their estimated positions
Timestamps
Cocoa time in seconds in the caches and in most clients.plist values, UTC
Acquisition
clients.plist reaches an iTunes / Finder backup (RootDomain), as MVT's backup module relies on. The cache databases need a full file system extraction
Retention
clients.plist keeps one entry per client while it exists. Cache tables are short-lived, typically days, and their content varies by release
Collection
idevicebackup2, Full file system extraction

What it is

locationd is the iOS daemon behind Location Services. It keeps two kinds of forensic data in /private/var/root/Library/Caches/locationd/:

  • clients.plist: the list of apps, extensions and system services that registered as location clients, with their authorisation and usage timestamps. It is the location counterpart of TCC.db.
  • cache_encryptedA/B/C.db: SQLite caches. Tables in cache_encryptedB.db (and in A on some builds) hold cell tower and Wi-Fi access point positions downloaded from Apple or harvested by the device to speed up positioning. cache_encryptedC.db has held motion and step history on some versions.

The caches are among the most misread artifacts on iOS. A row in a Wi-Fi location table is the estimated position of an access point, not a fix of the device. Many such rows come from a single download of the surrounding area.

Where it lives

FilePathNotes
clients.plist/private/var/root/Library/Caches/locationd/clients.plistSome parsers also look under /private/var/mobile/Library/Caches/locationd/
Location caches.../locationd/cache_encryptedB.db (+ -wal)Cell, LTE and Wi-Fi location tables; harvest tables on some builds
Other cachescache_encryptedA.db, cache_encryptedC.db, lockCache_encryptedA.dbContent varies strongly by release
BackupRootDomain, Library/Caches/locationd/clients.plistStored as a6/a690d7769cce8904ca2b67320b107c8fe5f79412

The cache databases are not in backups.

What it proves

  • clients.plist: that an app or service was a location client, its authorisation state, and the last times it received or requested location, depending on keys present.
  • Location caches: the positions of cell towers (with MCC, MNC, area and cell IDs) and Wi-Fi access points (MAC addresses) that the device's location stack dealt with.
  • Harvest tables (where present): observations the device collected to contribute to Apple's location database, which can include the device's own position at that time.

It does not prove, by itself, that the device was at a cached tower's or access point's coordinates.

Key fields

APOLLO and iLEAPP document the following for cache_encryptedB.db (verify on your build):

TableUseful columns
WifiLocationMAC, Timestamp, Latitude, Longitude, HorizontalAccuracy, Confidence, Channel
CellLocation, LteCellLocation, ScdmaCellLocation, CdmaCellLocationOperator and cell identifiers, Timestamp, Latitude, Longitude, HorizontalAccuracy
*Harvest tablesHarvested observations with device-side coordinates, speed and course

In clients.plist, each client dictionary carries keys such as the bundle ID or executable path, authorisation status and time values. MVT extracts it into readable records and checks the client names against indicators.

Timestamps

Cache timestamps are Cocoa time in seconds, UTC.

SELECT datetime(Timestamp + 978307200, 'unixepoch') AS cached_utc,
       MAC, Latitude, Longitude, HorizontalAccuracy, Confidence
FROM WifiLocation
ORDER BY Timestamp;

Many rows share one timestamp when a tile of data was downloaded at once. That pattern alone tells you the rows are not a track.

Retention

Cache rows are pruned quickly, typically after days. Harvest tables are flushed when data is uploaded. Several tables are reported empty on recent releases, and iLEAPP builds its column lists from the table because columns have moved over time (an AlsQueryTimestamp column appeared with iOS 26, for example). clients.plist entries persist while the client exists.

Collection

  • A standard backup gives clients.plist. Use MVT's check-backup or plutil to read it.
  • A full file system extraction from an AFU device is needed for the cache databases and their WAL files.
  • Collect Significant Locations at the same time: it is the better movement source.

Parsing

  • iLEAPP parses the cell and Wi-Fi tables of cache_encryptedB.db and adapts to per-release columns.
  • APOLLO has locationd_cacheencryptedAB_* and locationd_cacheencryptedC_* modules, tagged for older releases.
  • MVT extracts clients.plist in backup and file system modes.

Investigator tips

  • Never plot a Wi-Fi or cell cache table as the device's route. Use it as "the device was somewhere in this area around this time" at most, and prefer harvest tables or routined for device positions.
  • A location client with an unusual executable path in clients.plist deserves attention in compromise cases; see the spyware triage guide.
  • Compare clients.plist with TCC.db to build a complete picture of an app's permissions.
  • The location forensics guide ranks each location source by precision and retention.

See also