Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We have a password policy that enforces the users to use special characters in their passwords. Hence some passwords will be Gt4@gj#k for example.

Now to specify the system wide proxy settings (Why isn't this done more intuitively like for instance the way it was done in synaptic; and why is synaptic not included by default anymore either...) you have to use username:password@host in the host field for authenticating proxies.

Our problem no is that some passwords have the @ sign in them so it breaks this simple system.

How can I employ a system wide proxy to work with apt and the system updater that allows real world passwords?

share|improve this question
up vote 3 down vote accepted

If a program asks you to enter the proxy configuration as an http URL, you will need to follow the conventions for structuring URLs.

And that means you can not include an @ character in the user name or password components unless you encode them. Characters can be encoded in URLs as a percent sign followed by the hexadecimal representation of the code point.

So for the password Gt4@gj#k, you could represent it as Gt4%40gj%23k (the hash symbol is used to delimit the fragment portion of a URL, so it is best to encode it as well).

share|improve this answer
Thanks, it seem to have worked for most application. Yet some like apt does not work still. – georgelappies Oct 24 '11 at 11:38

Please check the below URL

Duplicate question search before asking a question.

Apt-get with special character

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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