Reply
Thread Tools
Posts: 115 | Thanked: 342 times | Joined on Dec 2010
#1
I am surprised that it isn't that easy as you would expect(especially when some firefox plugins don't work), but anyway.

First, there isn't much on that topic, or at least, not the full info. Most of the few posts out there tell you to go about:config and edit some stuff. This is correct, but only half of the truth, because once you close your browser windows the values there will be gone. Or in particular one value we care about. "network.proxy.type". Normally, you can persist some values by editing prefs.js in /home/user/.mozilla/microb/ (after stopping browserd, browser). Another way is to create a user.js in the same directory. Which I did:
Code:
user_pref("network.proxy.socks", "localhost");
user_pref("network.proxy.socks_port", 5500);
user_pref("network.proxy.socks_remote_dns", true);
user_pref("network.proxy.type", 1);


I don't think this requires explaination(except of network.proxy.type)

You'll realize quite fast that microb doesn't use your proxy. Why? Well, that was the big question.

Turns it overwrites the network.proxy.type to 0 if you have no proxies configured for your connection. Note that you can't use the the GUI to configure socks proxies, but is actually supported, see this bug. But I am still surprised that user.js seems to work, given what unbelievable mess microb actually is with the overwriting of pref.js, and crap in /usr/lib/microb-engine and /usr/lib/microb-engine/. Obscure.

So, microb takes a look at the gconf value /system/osso/connectivity/IAP/[IAP_ID]/proxytype.
If NONE = don't use proxy
if MANUAL = use manually configured proxy
And depending on what it finds there, it sets network.proxy.type.

To find out the IAP id for your connection: gconftool -R /system/osso/connectivity/IAP. Shouldn't be the most difficult thing on earth to find the ID you need...



Disconnect. Close all browser windows.
Code:
gconftool-2 -s /system/osso/connectivity/IAP/[IAP_ID]proxytype --type string MANUAL
Connect. Start your proxy (e. g. some ssh -D stuff or whatever)

And now it should work.



Some scripts like those below be quite handy, so
Code:
dbus-send --print-reply --system --dest=com.nokia.icd2 /com/nokia/icd2 com.nokia.icd2.disconnect_req uint32:0x8000
gconftool-2 -s /system/osso/connectivity/IAP/[IAP_ID]/proxytype --type string MANUAL
dbus-send --system --type=method_call --dest=com.nokia.icd /com/nokia/icd com.nokia.icd.connect string:"[IAP_ID]" uint32:0
Again, replace [IAP_ID] with the id of your connection...

and the disabler script
Code:
dbus-send --print-reply --system --dest=com.nokia.icd2 /com/nokia/icd2 com.nokia.icd2.disconnect_req uint32:0x8000
gconftool-2 -s /system/osso/connectivity/IAP/[IAP_ID]/proxytype --type string NONE
dbus-send --system --type=method_call --dest=com.nokia.icd /com/nokia/icd com.nokia.icd.connect string:"[IAP_ID]" uint32:0

Last edited by NIN101; 2012-07-14 at 12:25.
 

The Following 4 Users Say Thank You to NIN101 For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 08:07.