Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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

I am behind a proxy which requires users to login during the first connection with a username and password with a HTML form. Thus, it is not handled with usual and any attempt to access the internet from this setting falls into the login form.

How could I automatically login to the proxy? In linux, what manages proxy stuffs when a command tries to access the internet?

Thank you.

share|improve this question

If the HTML form doesn't have any JavaScript involved, you could send a HTTP POST request with wget (see --post-data option). You could stick a wget call to your ~/.bash_profile (if bash is your shell), so it gets executed everytime you login. The drawback is that you'll have a plain text password (the proxy password) in a config file.

share|improve this answer
Nice option but it does use javascrit :( – Julio Guerra Jun 27 '13 at 13:35
you could still log in using a browser, try to intercept HTTP requests, find the HTTP POST that's being sent to the proxy and try to craft it the same way – AnonymousLurker Jun 28 '13 at 23:36
up vote 0 down vote accepted

I have been successfully using tinyproxy so far to talk with the proxy by sending it a cookie it gives me when I log in. I then configure my clients to talk with tinyproxy (export http_proxy=http://localhost:8080/) and it works. See upstream and AddCookie options of tinyproxy.conf.

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.