[Q] Problem with Proxy Pac, in rooted Phone - Android Q&A, Help & Troubleshooting

To access the Internet using Wifi I need to go through the proxy server of our organization. Usually in a Windows Desktop we configure to get the DNS server automatically and use a proxy.pac (some thing like: http: //SSS.SSS.SS.SSS/proxy.pac).
I have rooted my Xperia X10 mini and tried anProxy and TransProxy, but failed to go through the proxy server.
Is there any way out or work around to access the Internet through our proxy server?
Thanks in advance!

I know this is old, but this is an ongoing problem and I figured out how to use a .pac proxy file! After reading about proxy's and what .pac files are, I stumbled upon a little hint and after a little tinkering I was able to use my work's wifi that uses an auto-config .pac file and my phone and tablet has full internet access with browser, apps etc including Netflix for example.
Here are the steps you need:
1) Your phone has to be rooted to take advantage of the proxy apps on the market, I personally use ProxyDroid, which is free and has a feature to bind certain proxy profiles to automatically turn on when a certain wifi network is connected.
2) Usually there is an option that gives you an http proxy pac file to manually input to your browsers or what not, so whatever the link is, put it an active internet browser to download the pac file (an example of the url with the pac file would be something like http://internet.xxxxx.com/proxy.pac)
3) Where ever you download the pac file, open it with notepad or wordpad and this will reveal all the proxy info you need in order to access the proxy enable wifi. What the ProxyDroid app needs from the PAC file is the Host url and Port number. When you open a PAC file in notepad, you'll see something like this near the top along with a bunch of other things under it:
"Cisco Remote Envelope Service
if (dstHost=="internet.e-mail") {
return "PROXY internet-x-x.xxxxxx.com:9090""
- So in "Host" under Proxy Settings in the ProxyDroid app you would input: internet-x-x.xxxx.com
- For the "Port" you would put input: 9090
4) After inputting those 2 pieces of info into the ProxyDroid app, turn the wifi on for your Android Device then enable to ProxyDroid app, you should able to connect to the proxy enabled wifi!
*Some notes for the ProxyDroid app.
- It allows for Authentication, but since my work wifi does not use that, I'm not sure how it would work
- For Proxy type, I set it as an HTTP
- I binded the specific proxy profile to my work wifi so it would ProxyDroid would automatically enable when work wifi was detected
Hope this bit of info helps other that have Android devices and were unable to use a proxy enable wifi to finally access them. Hopefully in the future, Android will make using proxy and pac files a lot easier like how it's done on the ipad where they allow you to manually set up proxy settings by having the device download the PAC file.
This works on both a rooted AT&T HTC Inspire and a HP Touchpad running CM7 Alpha

This looks like a resolved issue, but if anyone else is reading this, there is an easier way. Check out Autoproxy on the market. You can add a new proxy, put in the address to the proxy.pac file, and it will connect to the current proxy.
That's also good if you're on a network where they keep changing the proxy (like the place I work).

Related

[UPDATED 2/25/2009] SocksProxy v1.0: Free SOCKS proxy for internet sharing

I have created an SOCKS proxy server application to run on Windows Mobile phones. A SOCKS proxy is a proxy server that is capable of forwarding nearly all types of network traffic, similar to a NAT router. It is very simple to use. Simply type in the port you would like the proxy server to listen on (defaults is 1080), then click the large "Start Proxy" button.
In order to run this application you will need the .NET Compact Framework 3.5 installed on your device.
Some applications are SOCKS-ready and others are not. You can use FreeCap (freeware) to SOCKS enable any Windows application. ** FreeCap seems to have problems connecting to SocksProxy. Let me know if it works or doesn't work for you. **
I am *NOT* responsible for any fees charged to anyone for the use of this software. There is no warranty and no guarantee.
[UPDATE 2/25/2009]
I've completed the new version of SocksProxy. It implements socks version 4a. There is no security, so it will allow anyone to connect with any user id.
Please let me know of any issues you find.
[UPDATE 2/24/2009]
SocksProxy v1.0 Reboot
--------------------------------------------------------------------------------
I've completed the new proxy server. It looks pretty much like the old one, but I've anchored the controls to the edges so it should scale properly with VGA devices.
I've written a new Socks 4a proxy from scratch and completed ditched all the old code. It seems to be working pretty well, though a bit slow. I think I need to increase the size of my read buffers. I will have to write a smarter heuristic for determining the size of the buffer per connection though. I have them at 128 Kb now. I need to grow each buffer dynamically according to how it's being used, that way I don't create large buffers for connections that are only transfering small amounts before closing (downloading a small gif or javascript file, for example).
I'll probably release it tomorrow after some more testing.
BTW: I'm posting this through the proxy right now!
[UPDATE 2/24/2009]
I've decided not to move forward with the J2ME version of SocksProxy. I will however be writing a new .NET CF version. The current version's proxy is based on code I ported from a proxy targeted to the standard .NET framework. Some features in the standard framework are absent in the compact framework. When porting the proxy I pretty much just did it as quick and dirty as I could because I really wanted something that just got the job done. I didn't care how stable or 'good' it was because I hadn't even intended on releasing it to anyone. Since it looks like there's still a lot of interest I will be writing a new one from scratch. Don't expect too much; It'll be the simplest thing that possibly works, but it'll be stable and reliable.
I'll be naming this version SocksProxy 1.0 Reboot. I'm not upping the version number because I'm really not going to be adding any new features.
[UPDATE 11/4/2008]
I am working on a J2ME version of this application. I will no longer be maintaining the .NET version of the application. The SVN repository for the .NET version will continue to be available. I have no plans on taking it down.
I have decided to switch to J2ME because I will be able to reuse source code in a future Android release -- that is, if Google or someone adds the ability for Android to have more than one IP address.
[UPDATE 10/27/2008]
There is a usage issue with the application with certain configurations of Windows Mobile and Activesync. It seems that when the Activesync host (your PC) has a connection to the internet the handheld device will prefer to connect to the internet via the PC's connection rather than its cellular connection. This completely eliminates any benefit to using the proxy. Does anyone know how to prevent the handheld from routing its internet traffic back through Activesync? Note that this is NOT solved by setting the "Allow data connections" setting in Activesync.
[UPDATE 10/27/2008]
I have updated the SVN respository (https://pchasco.homedns.org/svn/SocksProxy/trunk). Here are the changes:
* Changed "Listening on" box to list all IPs on the handheld
* Added an IP box. Enter an IP to listen on that IP or leave blank to listen on all.
* Rearranged form
* Added "Use selected IP" button to insert into the IP box the IP selected in the list of available IP addresses.
You can enter any IP address in the IP box, but the proxy will fail to start if the IP is not valid for your device.
Hi pchasco,
Could you explain a bit more what this does (and how it works)?
The reason I ask is that I'm looking for an application for the PPC which allows me to share its internet connection by pointing the Desktop browser' proxy to the PPC.
This allows me to be connected to the wired network and using this proxied browser to browse even the blocked sites ...
Can your application be used for this?
If so could you also explain how it works..
I've ran the App on my PPC, and clicked start, this gave me an IP address
next i hooked it up to USB and pointed IE's proxy to that address...didn't work
I also tried to activate the 3G first and/or with ICS activated
but both times I didn't see a IP address...
I'm probably doing something wrong..
Thanks
This is a SOCKS proxy, so it does not work in quite the same way that a normal HTTP proxy does. For internet explorer you'll have to open the advanced proxy options and fill in the information for the SOCKS hostort entry.
Can someone please explain a sample usage of this software on Windows Mobile?
pchasco said:
This is a SOCKS proxy, so it does not work in quite the same way that a normal HTTP proxy does. For internet explorer you'll have to open the advanced proxy options and fill in the information for the SOCKS hostort entry.
Click to expand...
Click to collapse
Have you used this with ICS? In other words, share your internet connection with a computer and then have the computer connect via your sock proxy to the internet?
abdulzis said:
Can someone please explain a sample usage of this software on Windows Mobile?
Click to expand...
Click to collapse
I'm not sure what you mean. An example of how to use it or an example describing why someone would want to use it?
hoopsbwc34 said:
Have you used this with ICS? In other words, share your internet connection with a computer and then have the computer connect via your sock proxy to the internet?
Click to expand...
Click to collapse
I am not sure why you would need to use both SOCKS proxy and ICS at the same time. They are both means to provide internet connectivity through your phone to another device. If ICS were an option on my phone, I would use it over SOCKS unless the client device did not support it.
pchasco said:
I am not sure why you would need to use both SOCKS proxy and ICS at the same time. They are both means to provide internet connectivity through your phone to another device. If ICS were an option on my phone, I would use it over SOCKS unless the client device did not support it.
Click to expand...
Click to collapse
Basically, I'm trying to allow access to two networks at the same time. So I want to adjust my settings in firefox to point to my WM phone and your socks proxy. Then my other applications and IE can use my LAN. Otherwise, to get my WM ICS to work I have to disable my LAN connection which I need for certain apps.
edit... I'm good with using it without ICS, but that doesn't seem to work either. No matter when I click start proxy, I get an IP of 0.0.0.0 and if I connect my computer via USB I can't ping that address.
hoopsbwc34 said:
Basically, I'm trying to allow access to two networks at the same time. So I want to adjust my settings in firefox to point to my WM phone and your socks proxy. Then my other applications and IE can use my LAN. Otherwise, to get my WM ICS to work I have to disable my LAN connection which I need for certain apps.
Click to expand...
Click to collapse
Then setting the SOCKS proxy setting without setting any other proxy settings should work in Internet Explorer. I've been trying to test it, but my phone refuses to access the internet through the cellular connection right now; it's always going through my PC while activesync is connected. I can't get it to stop! The funny thing is IE on my PC is making its HTTP requests through my phone, then my phone is going right back through my PC to the internet!
pchasco said:
Then setting the SOCKS proxy setting without setting any other proxy settings should work in Internet Explorer. I've been trying to test it, but my phone refuses to access the internet through the cellular connection right now; it's always going through my PC while activesync is connected. I can't get it to stop! The funny thing is IE on my PC is making its HTTP requests through my phone, then my phone is going right back through my PC to the internet!
Click to expand...
Click to collapse
That's what I tried... but the IP address I get is 0.0.0.0 from your app. What IP do you usually get back when you run it? Do you just connect via USB? If ActiveSync is running is that an issue?
pchasco said:
Then setting the SOCKS proxy setting without setting any other proxy settings should work in Internet Explorer. I've been trying to test it, but my phone refuses to access the internet through the cellular connection right now; it's always going through my PC while activesync is connected. I can't get it to stop! The funny thing is IE on my PC is making its HTTP requests through my phone, then my phone is going right back through my PC to the internet!
Click to expand...
Click to collapse
I think there is a setting in ActiveSync that says "allow wireless connections when connected" sounds like that might be your problem.
Mr_Gee said:
Hi pchasco,
Could you explain a bit more what this does (and how it works)?
The reason I ask is that I'm looking for an application for the PPC which allows me to share its internet connection by pointing the Desktop browser' proxy to the PPC.
This allows me to be connected to the wired network and using this proxied browser to browse even the blocked sites ...
Can your application be used for this?
If so could you also explain how it works..
I've ran the App on my PPC, and clicked start, this gave me an IP address
next i hooked it up to USB and pointed IE's proxy to that address...didn't work
I also tried to activate the 3G first and/or with ICS activated
but both times I didn't see a IP address...
I'm probably doing something wrong..
Thanks
Click to expand...
Click to collapse
Sounds like the same thing that is happening to me. I finally got it to give me an IP address, but only if my data connection is inactive. As soon as the data connection is active it becomes a 0.0.0.0 IP address. Bug?
I tried to establish the IP, then activate the data connection... still doesn't work when I enter the IPort into my proxy list for firefox.
hoopsbwc34 said:
That's what I tried... but the IP address I get is 0.0.0.0 from your app. What IP do you usually get back when you run it? Do you just connect via USB? If ActiveSync is running is that an issue?
Click to expand...
Click to collapse
I am not sure why you are receiving 0 as your IP address. Check in Settings->Connections->USB to PC that "Enable advanced network functionality" is selected.
Gave it another try
Connected to ActiveSync (AS) loaded the application
removed the AS connection, started the application
It showed me the IP address op 127.0.0.1 (localhost)
Stopped the App, initiated the gprs and started the App again.
now i'm getting an IP of 0.0.0.0, I restarted the App a couple of times but no dice
I also checked if the advanced network functionality was enabled and it was..
Mr_Gee said:
Gave it another try
Connected to ActiveSync (AS) loaded the application
removed the AS connection, started the application
It showed me the IP address op 127.0.0.1 (localhost)
Stopped the App, initiated the gprs and started the App again.
now i'm getting an IP of 0.0.0.0, I restarted the App a couple of times but no dice
I also checked if the advanced network functionality was enabled and it was..
Click to expand...
Click to collapse
Hmm... I'm not sure what's going on here. 127.0.0.1 is the loopback interface-- It is only valid for your phone to connect to itself. If your computer attempted to connect to 127.0.0.1 it would connect to itself, not your phone.
pchasco said:
Hmm... I'm not sure what's going on here. 127.0.0.1 is the loopback interface-- It is only valid for your phone to connect to itself. If your computer attempted to connect to 127.0.0.1 it would connect to itself, not your phone.
Click to expand...
Click to collapse
Yes I know... :-/
Well, if I have time in the next few days I will take a look and see whether there is anything I can do. Maybe there is another IP address available on your device but for whatever reason I'm displaying the loopback instead of the external interface.
What happens when you set your proxy client up to go to 169.254.2.1:1080?
Mr_Gee said:
Gave it another try
Connected to ActiveSync (AS) loaded the application
removed the AS connection, started the application
It showed me the IP address op 127.0.0.1 (localhost)
Stopped the App, initiated the gprs and started the App again.
now i'm getting an IP of 0.0.0.0, I restarted the App a couple of times but no dice
I also checked if the advanced network functionality was enabled and it was..
Click to expand...
Click to collapse
Sounds like the same bug I am getting.
An example describing why someone would want to use it?
abdulzis said:
An example describing why someone would want to use it?
Click to expand...
Click to collapse
If you can't use ICS and want to connect to the internet from your desktop, you can connect your phone using USB and start this proxy, then you can setup your desktop connection to use the proxy to get internet access.

How do I connect LG Vortex-VZ's Optimus One-to my company Wifi and use apps over it?

I have recently purchased an LG Vortex (from what I read is Verizon Wireless's Optimus One) that comes with the Android 2.2 operating system installed. I have looked into rooting my phone with z4root and have successfully temporarily rooted my phone. I would rather keep my phone unrooted, but if it is absolutely necessary I will root it permanently with z4root.
My question is this: How can I connect to my company wifi and use apps that require wifi?
I can successfully connect to my corporate wifi through the 802.1x EAP protocol. The problem comes when trying to access any of the apps that require internet (I am forcing Verizon's data plan not to be used--using wifi only due to 150MB limit on my data to save $$ per month). None of my apps seem to work--internet browser, Market, Gmail, Google Calendar, etc...
On my company pc I know that within internet explorer the box is checked that says "Use automatic configuration script" and gives an "Address" that is in the format of "..../proxy.pac" It looks like my work uses a proxy for things to connect to the internet. I have no such place to put this information in my LG Vortex. I downloaded an app that seemed promising called "Proxy Settings" which will allow me to enter in the following Hostname and Port. When I tried to enter the "..../proxy.pac" as the hostname it gave me an error stating "The hostname you typed is not valid."
Is there an app or something that will allow me to use my apps when connecting to my corporate wifi? Is it a proxy setting thing or a VPN thing? I am not sure. I am open to any and every idea so that I can use my phone's online features while connected to my company's wifi.
FYI - I have friends that have iPod touches and they are able to connect to the internet with some apps internet browsing and downloading apps, but they have a similar issue of not being able to use all of their apps as well. I believe they were able to put the "..../proxy.pac" address in their devices somewhere.
Thanks!
I am a new member on this forum but I decided to reply because I have a question and a possible solution for you:
-solution:try to download the *.pac file.You will see that it is probably a script that defines your actual proxy's ip.So you could try and figure out which is your actual proxy's ip.Then use this ip for the proxy-app. (However I am afraid that only browser will connect properly,not every app)
-and now the question:how did you manage to connect to the network?I have trouble connecting because the wifi settings menu doesn't seem to help.
I try to connect to a 802.1x EAP network and I have installed the required certificates but I don't know what to fill to username,password fiels.
--
lampros

[Q] New question... Do any of the ROMs support Proxy wifi settings?

I didn't get much response on my previous question about proxy support for the stock rom, so I was wondering if any of the alternate roms include it. I would very much like to have access to the internet at work, but the school district requires loggon through a proxy server (content filter) before you can access the WiFi network. I realize that port restrictions that the district places on the network will likely prevent me from accessing the market, gmail, or voice search. But at school, I would most like to just access flash based educational website for kids.
Any thoughts on this? The district is moving toward ipads as the tablet platform of choice because of the lack of proxy support with Android. But the ipads lack of support for flash really hinders what I want a tablet to be able to do for me. (Yes, I want my cake and eat it too!) Is this too much to ask?
I connect my gtab to my schools wirelesss that is using 802.1x EAP for wireless security. I had to install a mod that changed the settings app and allowed advanced wireless settings. That allowed me to put in the authentication type, domain name, password, etc. Once connected, I ran a mod that set it back to the original settings apps. I asked in your previous post as to whether you are having problems actually getting on the wireless or once on, you can't bet by the web filter. We use websense here. Once I got on the wireless, there was an websense authentication dialog that popped up. Once I put my domain\username and password in, it works fine.
It won't even let me connect to the district network because I don't have anywhere to enter the proxy settings in the wifi set up box.
Assuming you have Pershoot's or Clemsyn's Kernel (or one of the better ROMs), you need something like ASProxy. I use it at work all the time and it does the job. There is a free program called TransParentProxy which is more limited but does allow you to quickly test settings without spending any money.
I do not see a proxy settings in the wpa_supplicant.conf file. My understanding of this file is it lists all possible settings settings available for Wi-Fi configurations.
# This file describes configuration file format and lists all available option.
Click to expand...
Click to collapse
Previously I've only needed to access a proxy after connecting to the network. Perhaps you have run into a problem getting connected to your network using the tablets Wi-Fi settings manager. So connecting to the network might be your first step and then connecting to the proxy your 2nd.
I found the free Wifi Advanced Config Editor (WifiACE on the Android Market) to have a GUI to easily configure advanced Wi-Fi settings not found in the tablet's settings. I realized when trying to set up an advanced configuration I needed to create a new connection in the tablets WiFi Settings with the security of NONE to avoid having some of the wrong settings configured by default. Then using the information from the my network admin I manually set the options via the WifACE GUI, un-checking NONE, and bingo I got connected.
I recommend WiFiACe with one caveat: make sure you have a way (like adb) working and know how to backup, delete, and restore files and that you make a back up of all wpa_supplicant.conf files on your tablet.
My caveat comes because my first reboot after I got connected to the Enterprise network at work the Wifi would not start or run. It would only display "error" and do nothing. Several reboots later it still wouldn't start and without Wi-Fi running there is no way to make configuration changes either through WifiACE or the tablets Wi-Fi Settings. I had to use the adb shell to delete the newly configured wap_supplicant.conf and create a new connection via the tablets Wi-Fi Settings and then make the necessary changes through WifiACE. Once that was done it ran and connected. Now after multiple reboots it still works and connects. Without the ability to delete the file I'm afraid I would have had to re-flash my tablet to get Wi-Fi to work again.
I don't think you've ever mentioned what ROM you're running. If you're running stock, you will have a very difficult time, in fact it may be impossible. If you're running a different mod, there's hope. Now, assuming that you got ClockWordMod (CWM) installed, you can probably be successful in at least connecting to the wireless. If you don't have CWM installed, here's a good place to start:
http://forum.xda-developers.com/showthread.php?t=865245
Once you have CWM installed, go to this thread:
http://forum.xda-developers.com/showthread.php?t=857939
This will give you the zips for installing a differernt wireless config tool that will allow you to put in the 802.1x EAP config. Once you can successfully connect, you back out the the tool you installed.

[Q] What's the best wifi proxy app?

Does anyone know of a good app for setting different network/proxy settings per wifi connection? I need a proxy setup for one wifi network and not for another but I don't see anyway to make that setting permanent in UnNamed ROM so time for an app.
It would be great if the app also had per-app proxy settings or intelligent features like FoxyProxy.
I use Auto Proxy for the WIFI at my office. It lets me set it so that it will only connect to the proxy if a certain subnet.
Thanks. I'm actually watching that thread currently. It looks promising but it has one major problem for me.....no proxy.pac support yet.
Any other programs?
There seems to be a solution to the .pac issue here
Thanks for the link. That helps determining what happens in the pac file.
I've tried Autoproxy and ProxyDroid using what I found in the pac file but neither is working quite right for me. They say they're connected but then I'm unable to actually browse anywhere through the default web browser or Dolphin HD. Market place also doesn't work.
I pinged the server name from my computer where the pac file says it's going and got the IP address. I then used the IP address from the pac file to fill in the host destination and port info. It's weird because it says it's connected but traffic doesn't flow. There isn't any authentication that I'm aware of so I'm stuck on what to try next.
Does anyone know of a good external proxy that's safe and reliable that I can do some testing with?
Knips178 said:
Thanks for the link. That helps determining what happens in the pac file.
I've tried Autoproxy and ProxyDroid using what I found in the pac file but neither is working quite right for me. They say they're connected but then I'm unable to actually browse anywhere through the default web browser or Dolphin HD. Market place also doesn't work.
I pinged the server name from my computer where the pac file says it's going and got the IP address. I then used the IP address from the pac file to fill in the host destination and port info. It's weird because it says it's connected but traffic doesn't flow. There isn't any authentication that I'm aware of so I'm stuck on what to try next.
Does anyone know of a good external proxy that's safe and reliable that I can do some testing with?
Click to expand...
Click to collapse
Knips178, try the newest version of Autoproxy. If your network is on a windows domain, it may be using your domain username and password as NTLM authentication, so you can also try that with the IP address you extracted from the proxy.pac

[Q] Tethering with proxy redirect ICS

I have a very nice 3G plan on my Samsung Galaxy Tab 2 (P3100) with Ice Cream Sandwich and i want to use the tethering option to share my internet connection and advertise my business through it. I can successfully share my 3G over wifi but i wanna go a step further and install a proxy on my tablet (or something similar) so when someone accesses my tethering wifi connection gets redirected to a webpage of my choise before being able to access any other websites (just like most proxies work in Hotels/Airports etc but without the need of any password, maybe just pushing an "Accept" button after a few lines of info)
I have done a quick search and all i could find is how to connect to a proxy for internet use at my android device or how to setup a proxy server for USB tethering (with software installed at the PC) but i need a softwareless wifi solution based on http headers so that any device can use it.
I don't expect there is an app for what i wanna do but any direction to it, perhaps the source of a proxy server i could try to build under android SDK, would be greatly appreciated.
A 3G wireless router with OpenWrt installed is more suitable for you than an android phone:>

Categories

Resources