1

I installed a Safari extension. I need to allow this extension to access files on mu system. Chrome has option looking like this:

enter image description here

I want the same for Safari. Where can I do this?

2

There is no way to enable this. Safari extensions are restricted to accessing the extensions folder and nowhere else.

If you need to access local resources, use safari.extension.baseURI + “relative path and filename”. You cannot access resources on the user’s hard drive outside of the extensions folder.

Source: Injecting Scripts - Safari Extensions Development Guide

  • Thank you. I am indeed trying to inject user script. For that I use Tampermonkey. Could you provide an example of how to use safari.extension.baseURI? I do not know what baseURI is for this extension. Where can I learn it? – sanjihan May 22 '16 at 17:00
  • @sanjihan I don't know how to do this since Tampermonkey scripts are injected on to the page and run as if the page executes them, and pages can't access safari.extension (only the extension code itself). You could look into creating a new extension which would give you access? – grg May 22 '16 at 18:03

You must log in to answer this question.

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