How to use wget behind a TMG proxy?

9,368

For having authentication with wget you can use:

wget --proxy-user=user --proxy-password=pass http//someurl.com/file

If you want to set this as variable in the profile use:

export http_proxy="http://username:[email protected]:8080"

Those are all you need. Of course, you should have a username:password for this proxy.

You could add the last line to your ~/.bashrc or ~/.profile or any script that executes at starting a prompt. If you want only wget knowing of this, you should modify ~/.wgetrc (only for the user) or /etc/wgetrc (globally for all the users) and add:

proxy_password = pass
proxy_user = user
Share:
9,368

Related videos on Youtube

ubuntu-user-83
Author by

ubuntu-user-83

Updated on September 18, 2022

Comments

  • ubuntu-user-83
    ubuntu-user-83 over 1 year

    I need to issue a HTTP request from the command line, but am behind a Forefront TMG Proxy. The environment variable http_proxy doesn't work.

    I still get the error:

    ERROR 407: Proxy Authentication Required ( Forefront TMG requires authorization to fulfill the request. Access to the Web Proxy filter is denied.  ).
    

    I have no GUI (no X) on this PC.

    How can I make a simple http request and bypass this proxy?