Apple today posted a Q&A piece on their website, outlining exactly what location information the iPhone stores and how it is used. The short version is that the iPhone maintains a cache of wifi hotspots and cell towers in the area to help better assist apps that use location services. This allows your phone to find your location much faster than if it used GPS alone. So even though the tracking is no where near as invasive and sinister as many media outlets have incorrectly reported, Apple will be making some changes in an update in the near future. They will no longer store a backup of this cached data on your computer and fix the supposed bug that when you turn off location services, the location data cache will be permanently deleted.
Why is my iPhone logging my location?
The iPhone is not logging your location. Rather, it’s maintaining a database of Wi-Fi hotspots and cell towers around your current location, some of which may be located more than one hundred miles away from your iPhone, to help your iPhone rapidly and accurately calculate its location when requested.
Can Apple locate me based on my geo-tagged Wi-Fi hotspot and cell tower data?
No. This data is sent to Apple in an anonymous and encrypted form. Apple cannot identify the source of this data.
Why is Apple tracking the location of my iPhone?
Apple is not tracking the location of your iPhone. Apple has never done so and has no plans to ever do so.