views:

86

answers:

2

I am developing a widget (HTML, JavaScript) for a platform which allows the (trusted) widget to make XSS calls.

I can test the code by packaging the widget, and using the emulator, but that takes 2 or 3 minutes to reboot every time I make a simple JavaScript code-change.

Is there a way to turn ON XSS support in Firefox, or any other browser that will run in Linux? I only want it locally for me personally of course, so settings, plugins, hacks, or anything else is acceptable.

A: 

You can make cross-site calls using an extension on Google Chrome. See here for more details. Of course this means having a special "debug path" in your application which might not be acceptable... can always yank it out afterwards ;-)

jldupont
Because I didn't have google chrome installed (and it's only beta for Linux anyway), and since the fix suggested by KennyTM worked for me, I didn't actually give this a try, but thanks for the response.Barry
barryred
+1  A: 

For XMLHttpRequest, insert this before calling open:

netscape.security.PrivilegeManager.enablePrivilege('UniversalBrowserRead');

See http://www.zachleat.com/web/2007/08/30/cross-domain-xhr-with-firefox/ for detail. (Might not apply to Fx 3)

KennyTM
It would be better if I didn't have to put any JavaScript into the code which won't be used by the actual application, but ... it's only one line, so can be easily removed, and it works perfectly.My development is progressing much quicker now!Thank you,Barry
barryred