6

I'm trying to test the installation of an application which uses Location Services (Core Location) on Mac OS X 10.7.

At the moment, it never prompts me for permission to grant the application access to Location Services, because that bundle ID has already been granted permission in the past.

If I untick the box, it assumes I want to disable the application completely, and doesn't ask me again.

How do I remove an item from the Location Services to force it to ask me again?

1

1 Answer 1

7

Open a root shell in Terminal, and go to /var/folders/zz/. Run ls -l and enter the directory owned by _locationd.

Open the C subdirectory, and run the following command to convert the preferences file from binary to XML:

plutil -convert xml1 clients.plist

Now edit the file e.g. in vim from the command line, removing the application (both key and dict afterwards) you no longer want to have appear on the list.

Save, and killall locationd to have it reload from the settings file.


Chances are, that the PromptedSettings key is useful as well, if no authorization is given, but I leave figuring this out to the reader.

23
  • This seems to have got my current app into a bit of a pickle. Now it throws a long stack trace when initializing Core Location, even though [CLLocationManager locationServicesEnabled] returns YES. Is there another location where this might be cached?
    – tomtaylor
    May 27, 2012 at 18:27
  • Ignore my last comment, this was an unrelated bug with sandboxing.
    – tomtaylor
    Jun 13, 2012 at 9:13
  • @tomtaylor Sandboxing is the bug.
    – Daniel Beck
    Jun 13, 2012 at 18:00
  • @tomtaylor: I'm having exactly the same problem with sandboxing. How did you work around it? Jun 30, 2012 at 14:28
  • 1
    @Regis_AG Again, just chown -R _locationd C to revert what you broke earlier, and it should work again.
    – Daniel Beck
    Dec 21, 2012 at 20:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .