Hacking T-Mobile Web Proxy
The subject is a little misleading, but I couldn’t remember what the datacard that I’ve borrowed from Vlad is called.
I’m connecting to the Internet from home via a T-Mobile PCCard, which uses some fangled 3g technology to give me a 1.8Mbps Interweb connection. Latency is a little higher than with conventional ‘broadband’, but the overall feel is good.
The big issue I have is with images… T-Mobile made a blanket decision to enable image compression by default. This means that I get garbled crappy images which are a pain in the backside.
After a little reading about I discovered that you could use a force reload (Shift+Ctrl+R in Firefox) to get the full-res samples. Yet more reading and I discovered that some people were setting a custom User Agent (appending “Blazer/4.0”) to fool the transparent proxy server into thinking the browser was incapable of page compression (although I don’t fully understand how this would help with inline JPEG compression, but anyway). Unfortunately this neat little trick didn’t work to me.
This got me thinking… if I can use my browser to force the proxy to send me a full-res image then it must be doing something special. A trip over to livehttpheaders.mozdev.org/, a new Firefox plugin and restart later and I was able to observe the HTTP headers that Firefox was sending to the server.
I quickly spotted that the following two extra headers were being sent on a force reload:
Pragma: no-cacheCache-Control: no-cache
So it looked as though the Pragma and Cache-Control force the proxy to send me the real deal. Now, time for another plugin, this time Modify Headers which I configured to be active at all times (“Always on”) and to send the exact two headers I mentioned in the last paragraph.
Modify Headers is a neat little plugin that allows the user to send any custom headers in a reasonably fine-grained way. But for me, I wanted the headers active for all requests.
The result? It was good… all of the pictures were now pretty. Of course, this isn’t without its drawbacks… all requests bypass the cache, which means I’ll be pulling more data down, but in exchange for the good images I guess I don’t have much other choice.
I’ve not played around much yet, but I’m sure there will be other issues. I’m a little curious as to how a regular page refresh is different to a forced page refresh… from what I’ve read there are a bunch of odd little things that go on, mostly historical.
But for now, I’m a happy bunny :)
January 16th, 2007 at 1:05 am
This is absolutely awesome. Thank you so much for blogging about you findings. Now I’m circumventing the T-mobile image compression too and I couldn’t be happier. I’m away from home and using my phone’s connection to browse Flickr is just not the same with fuzzy, mozaic images – but now it’s perfect. Thank you!
January 16th, 2007 at 9:01 am
Ace, see, you posting all this helped someone.
Anyway, for those of you that use Windows and not Linux. You can set the image compression using T-Mobile Communication Center. Options->Configuration->Connections->UMTS/GPRS->Properties->Applications->Speedmanager Plus->Settings There should be a nice drop down box, select whetever you want from that. I’d recommend keeping compression on GPRS though.
July 21st, 2007 at 1:36 am
Bliss!! Works a charm – and pretty easy to dissable for non-critical browsing on GPRS too! Thank you for publishing this. I tried all sorts of stuff before your solution.
July 21st, 2007 at 9:25 am
The compression option has been removed from the vista version of the tmobile software.
Is there a plugin or fix for IE?
July 22nd, 2007 at 1:08 am
I LOVE YOU, hehe :D I tried EVERYTHING to improve the image quality and NOTHING works, but this DOES, THANK YOU SOOOOOOOOOOOOOOOOOOOOOOOOOO MUCH!
But…. so much used to IE, rather than Firefox…. If you have any idea how to make that work for IE (7.0) on Vista (i use t-mobile web’n’walk with USB modem so don’t have t-mobile communication manager), would be even more grateful… before that I’ll be using firefox…
Anyway, thank you again:)
July 22nd, 2007 at 11:06 am
Sorry Paul & JWB, I’ve not used IE in a long time, so I’ve no idea how to do it.
That said, you could probably install some configurable web proxy on your machine, set IE up to connect to the Internet through that, and have the proxy send out the custom headers… but why go to so much hassle when Firefox is so much better than IE in the first place ;)
July 22nd, 2007 at 11:10 am
Lies! FF is horribly slow and crashy compared to ie, I can live without all that plugin stuff ;)
July 23rd, 2007 at 10:48 pm
ok, ok, I’m trying to make friends with firefox :) thanks again:)
July 31st, 2007 at 1:11 am
Thank you so much!
I ditched the control center software although working in windows as it was crashing my system several times a day. For 3 month I have been bothering t-mobile to tell me how to get rid off the image compression without using their software. Finally feel like I don’t need glasses any more. Fuzzy stuff all gone. Hurray!
August 27th, 2007 at 10:40 am
Great stuff, took a little while for me to figure out how to configure the headers (not being familiar with them in any way whatsoever!).
I surf at work via my phone and it’s easy enough just to turn off and on when i need it (it’s 3g, so ~400kbps).
Thanks again!
September 8th, 2007 at 3:54 pm
Have been searching forever for a hack like this.
Thank You!
I owe you a beer :-)
October 28th, 2007 at 9:51 am
Hi!
This sounds absolutely fabulous, unfortunately I cant get it to work :-( I think my settings in ‘Modify Headers’ is not right, could you please check them for me.
Action: ‘Add’
Name: ‘Pragma:’
Value: ‘no-cache’
Action: ‘Add’
Name: ‘Cache-control’
Value: ‘no-cache’
Your help would be much appreciated. Thanks!
November 30th, 2007 at 10:52 pm
Hi the correct settings for Headers to work with T-mobile
Name Value
Pragma no-cache
Cache-Control no-cahe
For IE and FireFox solution in one, you have to look for proximotron or privoxy ;)
December 13th, 2007 at 3:33 pm
For those looking for IE (or any other Win32 browser/app that can be told to use a proxy), get a copy of Fiddler from http://www.fiddlertool.com/fiddler/
You can play with the headers as much as you want.
January 1st, 2008 at 7:23 pm
A less drastic version that I’m using is to set the cache-control header to no-transform. This allows the image to be cached, but asks the proxy not to modify it.
January 2nd, 2008 at 4:06 pm
Hi Adrian,
Thanks for the info. I may do a re-post of this entry shortly with this update. It definitely seems like the right way to go.
Thanks, Lewis
January 6th, 2008 at 2:37 pm
Can anyone tell me how to configure Fiddler or Privoxy for this purpose ?
I managed to configure proximotron but for some reason it only worked for one session :S
March 14th, 2008 at 6:19 pm
Not sure if this has already been posted but T-Mobile have got a “T-Mobile Web Accelerator” programme that enables you to change image quality vs. download speed. Link is http://lastmile.t-mobile.co.uk/datacardhelp/user/page.phtml?page_id=97
March 19th, 2008 at 2:52 am
Hello everyone.
About a month ago I got a T-Mobile Web and Walk USB modem for my laptop.
I was happy with it (apart from not being able to use Skype…) until I realised T-Mobile were compressing pictures!!
I found this page and started the process of trying to set up Fiddler to disable image compression, when in my T-Mobile documentation I saw a link to a ‘secret’ T-Mobile website.
I was having a look at the downloads section when I saw the ‘Web’n’Walk Accelerator’.
It’s a utility that allows you to set the level of image compression!!!
I’ve just downloaded it and come straight back here to spread the good news.
I haven’t had chance to test it much but it seems to be working
– my IGoogle homepage still has some compressed images on it (some buttons and the logo) but I think that’s because they’re cached.
All the other sites I’ve been to have full quality images.
:)
The website address is
http://lastmile.t-mobile.co.uk/datacardhelp/user/page.phtml?page_id=98
select the device ‘Web’n’Walk device’,
the ‘T-Mobile’ manufacturer,
and the product ‘Web’n’Walk USB’ and click on the ‘Go’ button.
Then choose the ‘T-Mobile Web Accelerator’ zip file.
I hope this helps everyone.
We just need to work out how to use Skype now…
Sean.
:)
March 21st, 2008 at 7:01 pm
Hi, just thought I’d point out that when I posted my last message Seth’s message above mine one wasn’t there!
Hope you can fix the delay!
:)
Sean.
April 1st, 2008 at 9:23 am
While the configuration manager is indeed present on the Windows version, if you’re running on something other than Windows then the solution that Lewis presents is about as good as it gets. Well, until someone debugs the config utility on Windows, figures out what it’s doing and writes a Linux version.
April 16th, 2008 at 10:03 pm
That’s awesome, thanks! I hadn’t really used Firefox add-ons before, so it took me a little while to realise I had to open up the actual window from Tools and add the cache-control setting (I had been messing around in the options menu and trying to import xml).
I can live with other programs using the image compression, as long as Firefox is pretty. :)
Cheers.
May 3rd, 2008 at 2:24 pm
Thank you so much, a fantastic post and superb solution to a problem that has been bugging me for weeks. You cannot understand how relieve i feel right now!
God bless people like yourself and others who aim to help the lost and wounded.
Much much appreciated!