Pardon my simple question, I'm new to XUL. If there's a good reference
material elsewhere, please point me to it. Whatever I can scour from
the net is quite limited.
Problem:
I am sitting behind a proxy and I can't get XULRunner to access
external site, or rather, I don't know how to properly configure it to
go out via the proxy. What few pages I can find through google points
me towards using the interface nsIHttpAuthManager, like so:
proxyAuthenticationComponent = Components.classes["@mozilla.org/
network/httpauth-manager;1"].getService
(Components.interfaces.nsIHttpAuthManager);
proxyAuthenticationComponent.setAuthIdentity
('http','secret.proxy.host',8888,"","","","","username","password");
// load default URL into browser
$('browser').loadURI('http://www.google.com');
www.google.com needs to be accessed via proxy, and I haven't been able
to access it after calling setAuthIdentity()
I can access pages that is running locally (http://localhost:8080
works).
Is setAuthIdentity() the interface I need to invoke to set the proxy
settings? Is there anything else I need to call/invoke/configure to
make the change take effect?
>I am sitting behind a proxy and I can't get XULRunner to access external site, or rather, I don't know how to properly configure it to go out via the proxy.
>
I'm assuming that you have no problem configuring Firefox or other
Gecko-based browser to use the proxy, in which case all you need to do
is to copy the relevant preferences (you'll find them in prefs.js).
--
Warning: May contain traces of nuts.
Neil,
Yeah, was asking around in #xul channel in irc.mozilla this morning,
got the tip from Mooks_sb, tried it and it works. I tried prefs.js
yesterday, set the network.proxy.http and network.proxy.http_port, but
not network.proxy.type :-p
Thanks