Curl Command to download remote certificate


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Curl Command to download remote certificate
# 1  
Old 11-23-2011
Question Curl Command to download remote certificate

Hi,

I have Apache running with the certificates installed.

I need a "unix curl" command to download and display remote server certificate.

Kindly help.

Note: Apache has ""SSLVerifyClient require" set in its configuration.

Last edited by mohtashims; 11-23-2011 at 11:19 AM..
# 2  
Old 11-23-2011
Code:
echo "HEAD / HTTP/1.0\n Host: example.com:443\n\n EOT\n" | openssl s_client -prexit -connect example.com:443

this will return the SSL cert of the web server.
# 3  
Old 11-24-2011
MySQL

Quote:
Originally Posted by robsonde
Code:
echo "HEAD / HTTP/1.0\n Host: example.com:443\n\n EOT\n" | openssl s_client -prexit -connect example.com:443

this will return the SSL cert of the web server.
That works, however I was looking for the same with the CURL command.

Appreciate your help.
# 4  
Old 12-26-2011
Error

So, can anyone help me with a cURL command for downloading a website certificate.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Curl parallel download file list

Hello guys, first post sorry if I did some mess here =) Using Ubuntu 14.04lts 64bits server version. I have a list (url.list) with only URLs to download, one per line, that looks like this: http://domain.com/teste.php?a=2&b=3&name=1 http://domain.com/teste.php?a=2&b=3&name=2 ...... (6 Replies)
Discussion started by: tonispa
6 Replies

2. UNIX for Beginners Questions & Answers

Curl to download using Linux not working

Good Morning. I'm trying to download a file from a server. I was able to upload to the server successfully but when i download, i see the file name in my server but with some unknow data. The file name i'm trying to download is abcd.zip in binary mode. curl -1 -v --ftp-pasv -o abcd.zip -u... (4 Replies)
Discussion started by: Pavan Kumar19
4 Replies

3. Shell Programming and Scripting

Curl command to download multiple files with a file prefix

I am using the below curl command to download a single file from client server and it is working as expected curl --ftp-ssl -k -u ${USER}:${PASSWD} ftp://${HOST}:${PORT}/path/to/${FILE} --output ${DEST}/${FILE} let say the client has 3 files hellofile.101, hellofile.102, hellofile.103 and I... (3 Replies)
Discussion started by: r@v!7*7@
3 Replies

4. Shell Programming and Scripting

How to download file without curl and wget

Hi I need a Shell script that will download a zip file every second from a http server but i can't use neither curl nor wget. Can anyone will help me go about this task ??? Thanks!! (1 Reply)
Discussion started by: rubber08
1 Replies

5. UNIX for Advanced & Expert Users

Help with using curl to download files from https

Hi I'm trying to download an xml file from a https server using curl on a Linux machine with Ubuntu 10.4.2 I am able to connect to the remote server with my username and password but the output is only "Virtual user <username> logged in". I am expecting to download the xml file. My output... (4 Replies)
Discussion started by: henryN
4 Replies

6. Cybersecurity

openssl fails to download certificate

I tried openssl to download a remote cert on my181.svr.us.cyber.net Below are the 3 steps to generate self sign certificate. 1)To generate keys: /opt/boksm/lib/openssl genrsa -des3 -out server2.key 2048 -config /usr/sfw/lib/webmin/acl/openssl.cnf 2)To generate CSR ... (0 Replies)
Discussion started by: mohtashims
0 Replies

7. Shell Programming and Scripting

Download using curl and redirect question_please help

Basically I am needing to Download (using curl) in the background some data from(link here), with stderr redirected to /dev/null, to a file named taxcode I was doing this, curl & http:// name here/download/pls/Title_26.txt 2> /dev/null > taxcode but the results were not what I was after. ... (1 Reply)
Discussion started by: santod
1 Replies

8. Shell Programming and Scripting

curl certificate error

Hi, I am getting below error when I do ------------------------------- curl: (60) SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed More details here: cURL - Details on Server SSL Certificates... (5 Replies)
Discussion started by: Anjan1
5 Replies

9. UNIX for Advanced & Expert Users

Using SCP command in IBM AIX to download file from remote to local system

Hi, When i run the code in solaris unix machine, the file from remote server is getting downloaded. but when i use the same code in IBM AIX remote machine, it is not running. It is saying "Erro during scp transfer." Below is the code. Please give some resolution. SCPClient client = new... (1 Reply)
Discussion started by: gravi2020
1 Replies

10. UNIX for Dummies Questions & Answers

cURL Active FTP Download

Hello, I know this is probably a very silly question for most but how to do I force curl to do active FTP downloads? Thank you Dallas (2 Replies)
Discussion started by: Dallasbr
2 Replies
Login or Register to Ask a Question