On Mon, Apr 14, 2014 at 11:12 AM, xunxun <xunxun1...@gmail.com> wrote:
> I want to use a configurable way like > https://developer.mozilla.org/en-US/docs/Midas/Security_preferences, > which can solve some strange issues on a single js, NoScript is too big for > the problem. > > For example, I use the policy by default on my custom build: > > pref("capability.policy.policynames", "pcxnojs"); > pref("capability.policy.pcxnojs.sites", "http://nsclick.baidu.com"); > pref("capability.policy.pcxnojs.javascript.enabled", "noAccess"); > > nsclick.baidu.com can cause firefox tab closing costs too much time, so I > use the policy to avoid it. > NoScript has the capability to do exactly that. You're also welcome to write an extension that uses the same API, though you should know that only one extension may use the API at a given time (so your users would not be able to install NoScript). See the API here: http://mxr.mozilla.org/mozilla-central/source/caps/idl/nsIScriptSecurityManager.idl#221 _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform