Solved

http_proxy in solaris10 sparc?

Posted on 2009-07-02
22
2,739 Views
Last Modified: 2013-12-19
Hi,
   Can someone help me on configuring the proxy login from the solaris 10 (sparc)? I need to setup the http proxy so the box can reach internet doing some download and other things.

   Is there similar thing like http_proxy i can do for solaris? Would be appreciated if someone can show me the step on configuring it.  By the way, is there anyway i can make it prompt user to enter password (or/and username) upon access internet from shell?

ps: would prefer to do it on command line
   
0
Comment
Question by:stock99
  • 11
  • 8
  • 3
22 Comments
 
LVL 40

Accepted Solution

by:
omarfarid earned 138 total points
ID: 24765325
are you going t use gui browser ? if yes then you can set it to use proxy. if you want to use tools like wget then it supports http_proxy
0
 

Author Comment

by:stock99
ID: 24767705
so there is no environment variable like linux's http_proxy where you can set it and let other applications using http traffic to go through proxy server ? I mean, configure individual package using http to go through proxy is kinda not as convenient.
0
 

Author Comment

by:stock99
ID: 24767716
Forgot to mention i only have ssh access.
0
 
LVL 40

Assisted Solution

by:omarfarid
omarfarid earned 138 total points
ID: 24770852
I am not sure if other applications use http_proxy on solaris. When you say you only have ssh access, do you mean from the system?
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24772367
export http_proxy=http://user:password@proxy.host:port/
-"- ftp_proxy
-"- https_proxy

Does not work with GNOME-JDS breed but that does not seem to be of concern.
Works with lynx, pkg etc.
0
 

Author Comment

by:stock99
ID: 24778530
Hi Gheist,


does that export mean I going to allow system wide accessing using that single username/password? is there anyway to limit the access of proxy for per user credential basis(ie. each user have to use their own login and password to get through proxy to internet)?
 
0
 
LVL 40

Assisted Solution

by:omarfarid
omarfarid earned 138 total points
ID: 24778792
The export command will make env variables available to sub processes of the current shell for that user and not all users.
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24792437
command line tools have no intrumentation to get passwords.
graphical browsers do PAC/WPAD
0
 

Author Comment

by:stock99
ID: 24846094
hmm i tried the http approach, but not sure if it is because the last character of my password is '@' , or sth else causing issue. I doesn't seem to able to get anything download using pca "http://www.par.univie.ac.at/solaris/pca/installation.html"

bash-3.00$ pca -l all
Downloading xref file to /var/tmp/patchdiag.xref
Trying https://sunsolve.sun.com/patchdiag.xref (1/1)
Failed
Failed (patchdiag.xref not found)

ERROR: Can't open xref file /var/tmp/patchdiag.xref (No such file or directory)


0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24846939
http://www.par.univie.ac.at/solaris/pca/usage.html

it uses wget configuration, not environment. get wget right first.
0
 

Author Comment

by:stock99
ID: 24875079
my wget work with normal http download but not https download. Not too sure what's wrong here. My web browser has no trouble to access https site.

bash-3.00# echo $http_proxy
http://username:password@companyproxy.com:8080
bash-3.00# echo $https_proxy
http://username:password@companyproxy.com:8080
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:stock99
ID: 24875082
forgot to paste the error message when trying to download file from https

Connecting to companyproxy.com[x.x.x.x]:8080... connected.
Proxy request sent, awaiting response... 400 Bad Request
11:22:23 ERROR 400: Bad Request.
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24878165
You missed last slash in variable content.
0
 

Author Comment

by:stock99
ID: 24885093
i tried added that, but still got the same result..
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24887606
Works for me for last 10 years, you are special - does not for you.
0
 

Author Comment

by:stock99
ID: 24888058
Can someone else with more knowledge able to help me for this issue?


From the error log, it had probably already pass the authentication stage (hence the work 'connected').  But somehow, it doens't get pass the https for the proxy? During my normal browsing, I don't usually enter credential twice.

Btw, what would the error 400 stand for proxy error return ?
bash-3.00# echo $http_proxy

http://username:password@company_proxy.com:8080/

bash-3.00# echo $https_proxy

http://username:password@company_proxy.com:8080/

bash-3.00# wget https://sunsolve.sun.com/patchdiag.xref

--12:33:21--  https://sunsolve.sun.com/patchdiag.xref

           => `patchdiag.xref'

Resolving company_proxy.com... some_internal_dns_ip

Connecting to company_proxy.com[some_internal_dns_ip]:8080... connected.

Proxy request sent, awaiting response... 400 Bad Request

12:33:21 ERROR 400: Bad Request.

Open in new window

0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24888440
Look at proxy logs. HTTP error 400 is generated by HTTP server or proxy, not by client like the error you posted previously.
Are you able ot download with lynx or wget in current setup?
0
 

Author Comment

by:stock99
ID: 24891642
i dont' have access to proxy server unfortunately.  because of the company bureaucracy, i can't get any info from them..

I am able to download via wget via http but not via https . I can go try lynx but not so sure where to config the ssl (seldom use lynx)
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24892787
Then go with http. Your wget may not support ssl as well.
0
 

Author Comment

by:stock99
ID: 24910579
well.. the problem is when going thro http, most pacakge are not found. Not sure if it is because i use "--noreboot" and "--safe".  But only 10% of package get update make me wonder if http access allow all the update package to be done.
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 362 total points
ID: 24910603
Ask your proxy admin - really...
0
 

Author Closing Comment

by:stock99
ID: 31599272
no
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. jgh@FreeBSD.org Please see http://www.freebsd.org/doc/en_US.ISO8859-1/articles/freebsd-update-server/ for the updated article. It is avail…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now