My codes are
nsresult rev;
nsCOMPtr<nsIPref> prefs(do_GetService(NS_PREF_CONTRACTID,
&rev));
if (NS_SUCCEEDED(rev))
{
prefs->SetIntPref( "network.proxy.type", 1 );
prefs->SetCharPref( "network.proxy.http", "192.168.1.47");
prefs->SetIntPref( "network.proxy.http_port", 8080 );
prefs->SetCharPref( "network.proxy.password","password");
prefs->SetCharPref( "network.proxy.login","username");
}
I can assure that all the setting proxy IP,port ,username and password
are correct.But when I compile and run this program.It returns "Proxy
Authentication Required" error.If I access local url.It's OK.No problem
happen! It seems the gecko does not konw network.proxy.login and
network.proxy.password parameters.
Does anybody know how to pass authentication information to proxy in
gecko?
Wayne
_______________________________________________
dev-embedding mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-embedding