Using PAC file does not set http_proxy env variable

Bug #1175479 reported by NeilGreenwood
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
libproxy (Ubuntu)
New
Undecided
Unassigned

Bug Description

I have a moderately complicated (66 line) PAC file, configured in the Network Settings applet using the automatic method with a HTTP URL. I've seen the same/similar behaviour on previous versions of Ubuntu.

This doesn't set the http_proxy environment variable, so I am unable to access the internet as all applications try to connect directly. I'm attaching an obfuscated version of the PAC file, and I'm keen to help debug this issue.

I've worked around the problem to gain internet access by setting the proxy manually, but this doesn't set up the exceptions specified by the PAC.

ProblemType: Bug
DistroRelease: Ubuntu 13.04
Package: libproxy1 0.4.11-0ubuntu1
ProcVersionSignature: Ubuntu 3.8.0-19.29-generic 3.8.8
Uname: Linux 3.8.0-19-generic x86_64
NonfreeKernelModules: nvidia
ApportVersion: 2.9.2-0ubuntu8
Architecture: amd64
Date: Thu May 2 07:55:08 2013
EcryptfsInUse: Yes
InstallationDate: Installed on 2012-04-27 (369 days ago)
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Beta amd64 (20120328)
MarkForUpload: True
SourcePackage: libproxy
UpgradeStatus: Upgraded to raring on 2013-04-26 (5 days ago)

Revision history for this message
NeilGreenwood (neil-greenwood) wrote :
Revision history for this message
NeilGreenwood (neil-greenwood) wrote :

I've just found that the file is served from the URL as MIME type "text/plain". Would this affect things?

Revision history for this message
Andras Mocsary (amocsy) wrote :

Hi Neil,

I don't know why that "Network Settings applet" wouldn't set the http_proxy environment variable,
but:
 a PAC file should be run for each url, because you can have different proxies for each and one of them
 the http_proxy variable can not handle this, it's used for "one proxy-rules-all" setups

In my opininon the two things are not compatible, http_proxy and it's kind is not able to handle your exceptions from your PAC.

Regards,
András

Revision history for this message
NeilGreenwood (neil-greenwood) wrote :

Thanks for the reply.

I am not positive that it should set the http_proxy environment variable, but I am definitely seeing applications not seeming to use the PAC file when trying to connect to the internet.

I've downloaded the source for libproxy, but I can't really see how the tests work in order to make a start on debugging the problem. I'm not a C++ developer and I'm not familiar with CMake, but I am a professional developer. Any guidance you can provide would be appreciated.

Revision history for this message
Domen Puncer (domen) wrote :

Chromium uses auto_proxy variable with .pac URL. Maybe some other application also follows the same scheme.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.