Little background: I am behind a proxy, where we use "automatic proxy config URL" on
During typing of this question I also tried Chromium browser which seems to be working. However, Firefox and terminal seem to be not working properly:
Setup of my Ubuntu:
System Settings - Network Proxy - Configuration URL - applied system wide
Firefox:
Edit - Preferences - Network
Here I tried:
Note - the "no use" means = cannot connect outside mycompany.com intranet
- Automatic Proxy configuration URL - - no use
- Use system proxy settings - no use
- Autodetect - no use
The error I am getting when trying to reach askubuntu.com:
Unable to connect
Firefox can't establish a connection to the server at askubuntu.com.
The site could be temporarily unavailable or too busy. Try again in a few moments.
If you are unable to load any pages, check your computer's network connection.
If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web.Setup of Chromium- I am not that advanced user here, but it seems it takes system settings
system setup
/etc/environment
http_proxy=
https_proxy=
ftp_proxy=
no_proxy=.mycompany.comsudo visudo
Defaults env_keep = "http_proxy https_proxy ftp_proxy"In terminal, I can effectively run sudo apt-get update but pinging google says this:
PING (74.125.136.147) 56(84) bytes of data.
--- ping statistics ---
10 packets transmitted, 0 received, 100% packet loss, time 9070msHow to force Firefox and terminal to reach outside world?
Edit Firefox works on other machines in the same network, so it cannot be security setting on the proxy
5 Answers
I've been having a similar issue: http(s)_proxy are both set as environment variables, and pretty much all CLI-programs work.
But Firefox doesn't.
After many tries we figured out that while works fine most of the time, Firefox doesn't seem to like the leading http://. Setting a manual proxy to just proxy.mycompany.com:8080 makes Firefox behave as needed.
Not sure whether it's a bug in Firefox or what, but at the very least, it's a sensible workaround.
1I do not think that you are using automatic proxy but rather manual proxy, because that is what you fill into /etc/environment. Try to select "Manual Proxy Configuration", fill in the HTTP Proxy as webproxy.mycompany.com, Port 8080 and click "Use this proxy for all protocols". If proxy items in ypour /etc/environment do something, than this must work for Firefox.
Automatic proxy is URL path to the PAC file, which is something else than the actual proxy settings. For more details on Auto proxy configuration :
If I remember it correctly, there is software that wants the proxy environment variables to be uppercase. Have you tried to define the following?
export HTTP_PROXY=$http_proxy
export HTTPS_PROXY=$https_proxy
export FTP_PROXY=$ftp_proxy Make a new file /etc/profile.d/your_new_file.sh and put the below code in it
http_proxy=""
https_proxy=""
ftp_proxy=""
HTTP_PROXY=$http_proxy
HTTPS_PROXY=$http_proxy
FTP_PROXY=$http_proxy
no_proxy=localhost,127.0.0.0/8,192.168.0.0/16,10.0.0.0/8,172.16.0.0/12,updatesrv # enter your network
NO_PROXY=$no_proxy
export http_proxy ftp_proxy https_proxy HTTP_PROXY HTTPS_PROXY FTP_PROXY no_proxy NO_PROXY Save the file and reboot your system. Your firefox terminal and every service running on your computer will pass through the proxy.
Try editing the following files and enter your proxy details in them;
In /etc/bash.bashrc:
export http_proxy= export ftp_proxy=In /etc/environment:
http_proxy=yourproxy
https_proxy=yourproxy
ftp_proxy=yourproxyIn /etc/apt/apt.conf:
Acquire::http::proxy yourproxy
Acquire::https::proxy yourproxyThen restart the terminal and check. Hopefully, the issue will be resolved.