I use net connection that needs proxy, user name and password, I can access to the net by firefox, but I can't update my system or use Ubuntu software center.

I setup the proxy and username/password in Synaptic and in Network Proxy and i edit apt.conf bu this command :

sudo gedit /etc/apt/apt.conf

but update dos not work

I already did the steps mentioned in the answer about the Ubuntu forums posts.

How to use apt-get/synaptic behind proxy ?

link|improve this question
1  
Have you used the global network proxy under system --> preferences --> network proxy, and applyed the settings globaly? – DemonWareXT May 3 '11 at 9:49
Possible Duplicate: apt-get does not work with proxy – Marco Ceppi Jun 6 '11 at 12:11
feedback

4 Answers

I'm behind MS ISA PROXY and I'm using Cntlm Authentication Proxy soft and in the apt.conf I have 4 lines, I've read somewhere, that the last line must be empty, but I'm not sure about it. It works perfect:

Acquire::http::proxy "http://127.0.0.1:3128/";
Acquire::ftp::proxy "ftp://127.0.0.1:3128/";
Acquire::https::proxy "https://127.0.0.1:3128/";
link|improve this answer
feedback

I have found that USERNAME and PASSWORD entered into the "Network Proxy" applet does not get stored into the apt.conf file you must manually add the username and password in the /etc/apt/apt.conf file.

The "Network Proxy" applet only stores the hostname and the port.

The basic syntax is

Acquire::http::proxy "http://User:Password@host:port/";

Acquire::ftp::proxy "ftp://User:Password@host:port/";

Acquire::https::proxy "https://User:Password@host:port/";

If you are using Windows usernames and password follow this advice:

User = Domain/Username

(windows users use / not \)

If you are using Windows strong/complex password with special characters you must use the URL encoding for the values, for example an "@" in the password would be "%40".

link|improve this answer
(windows users use / not ) So THAT's why I'm stuck :) Thanks! – GaiusSensei May 19 at 5:35
feedback

With a BlueCoat proxy, for me the format of the apt.conf file was required to look like:

Acquire::http::proxy "http://Domain%5cUserID:Password@proxy.name.whatever:80/"; Acquire::ftp::proxy "ftp://Domain%5cUserID:Password@proxy.name.whatever:80/"; Acquire::https::proxy "https://Domain%5cUserID:Password@proxy.name.whatever:80/";

^ ^ ^ ^ Blank line after 3rd proxy line, do not enter this line. ^ ^ ^ ^

link|improve this answer
feedback

there was discussion about this on ubuntu forums

http://ubuntuforums.org/showpost.php?p=535438&postcount=10

http://ubuntuforums.org/showpost.php?p=3340662&postcount=25

you can try it

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.