Linux – Curl NSS error -12190 – Error in TLS handshake

certificatecurllinuxopensshssl

I am getting below error while trying to download a package from a URL through putty:

Proxy replied OK to CONNECT request

Initializing NSS with certpath: sql:/etc/pki/nssdb

CAfile: /etc/pki/tls/certs/ca-bundle.crt

CApath: none

NSS error -12190

Error in TLS handshake, trying SSLv3…

GET /NagiosEnterprises/nrpe/releases/download/nrpe-3.1.1/nrpe-3.1.1.tar.gz HTTP/1.1

User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.13.1.0 zlib/1.2.3 libidn/1.18 libssh2/1.2.2

Host: github.com

Accept: /

But for some url it works perfectly as below:

Proxy replied OK to CONNECT request

Initializing NSS with certpath: sql:/etc/pki/nssdb

CAfile: /etc/pki/tls/certs/ca-bundle.crt

CApath: none

SSL connection using TLS_DHE_RSA_WITH_AES_256_CBC_SHA

Server certificate:

subject: CN=*.mariadb.org,OU=Domain Control Validated

start date: Oct 15 19:34:00 2017 GMT

expire date: Oct 18 20:07:53 2018 GMT

common name: *.mariadb.org

  issuer: CN=Go Daddy Secure Certificate Authority - G2,OU=http://certs.godaddy.com/repository/,O="GoDaddy.com, Inc.",L=Scottsdale,ST=Arizona,C=US

GET /f/mariadb-10.1.31/source/mariadb-10.1.31.tar.gz HTTP/1.1

User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.13.1.0 zlib/1.2.3 libidn/1.18 libssh2/1.2.2

Host: downloads.mariadb.org

Accept: /

Could someone help me to fix this.

Best Answer

I had this error with curl -v.

I solved it by changing tls version:

curl --tlsv1.2 https://(...)

hth

Related Question