f



Openssl through HTTP Proxy (cUrl?)

Greetings all,

I need to get an SSL certificate from a server outside of my corporate
network. Inside the network, we use "openssl s_client -connect
host:port" to get that and then use other openssl commands to get some
information of interest. However, when accessing external sites, we
must pass through an NTLM authenticated proxy and therefore direct
connections simply give a connection refused. I Googled for some time
and found no resolution to using openssl over a proxy.

So I thought of using cUrl in some way, which can connect through the
proxy if provided with proper options and authentication. So this
allows me to connect to external sites and enabling "verbose" mode
will allow me to output some of the certificate info (issuer, exp
date, etc), but not all the info I can grab with openssl.

So the question is, is anyone aware of a way to either connect with
openssl over a NTLM authenticated proxy or retrieve all the SSL cert
info using cUrl or some other function (maybe a combination of opening
a connection with cUrl and having openssl commands run over this
connection)?
0
Daniel
9/7/2010 8:16:45 PM
comp.lang.php 32633 articles. 0 followers. Post Follow

1 Replies
994 Views

Similar Articles

[PageSpeed] 34

Hello,

on 09/07/2010 05:16 PM Daniel said the following:
> Greetings all,
> 
> I need to get an SSL certificate from a server outside of my corporate
> network. Inside the network, we use "openssl s_client -connect
> host:port" to get that and then use other openssl commands to get some
> information of interest. However, when accessing external sites, we
> must pass through an NTLM authenticated proxy and therefore direct
> connections simply give a connection refused. I Googled for some time
> and found no resolution to using openssl over a proxy.
> 
> So I thought of using cUrl in some way, which can connect through the
> proxy if provided with proper options and authentication. So this
> allows me to connect to external sites and enabling "verbose" mode
> will allow me to output some of the certificate info (issuer, exp
> date, etc), but not all the info I can grab with openssl.
> 
> So the question is, is anyone aware of a way to either connect with
> openssl over a NTLM authenticated proxy or retrieve all the SSL cert
> info using cUrl or some other function (maybe a combination of opening
> a connection with cUrl and having openssl commands run over this
> connection)?

You may want to try this HTTP client class. It supports SSL and several
authentication mechanisms including NTLM.

http://www.phpclasses.org/httpclient

You also need this package to provide NTLM client support.

http://www.phpclasses.org/sasl

-- 

Regards,
Manuel Lemos

JS Classes - Free ready to use OOP components written in JavaScript
http://www.jsclasses.org/

--- news://freenews.netfront.net/ - complaints: news@netfront.net ---
0
mlemos (662)
9/8/2010 4:58:46 AM
Reply: