Lucas Charbonnier
Lucas Charbonnier

Reputation: 461

curl error 35 : failed to receive handshake, SSL/TLS connection failed

When I try to execute this curl command :

curl -v --key some_key_file.key --cert certificate_file.pem --show-error --header "Content-Type: application/json;charset=UTF-8" https://some-api/service

I get the following error : curl: (35) schannel: failed to receive handshake, SSL/TLS connection failed

And the full execution log :

enter image description here

I have searched this error online and haven't found anyone explaining what it really meant.

Upvotes: 7

Views: 53633

Answers (3)

Lucas Charbonnier
Lucas Charbonnier

Reputation: 461

The problem was with my curl version which for some reason didn't accept the arguments --cert and --key.

To solve the problem, I installed a completely new curl version and ran it from the installation folder and it worked.

Upvotes: 2

Miguel Godoy
Miguel Godoy

Reputation: 9

This error happens when you are behind a 7 layer firewall (i.e Palo Alto) that Allow SSL connections only via application, so you have to configure 2 rules in such solution.

  1. Allow 443 or whatever port with higher priority
  2. Allow Application SSL with lower priority

Upvotes: 1

Kazi Moslem Hoque
Kazi Moslem Hoque

Reputation: 21

Run the command from the path where you have curl package. if you place in c:\curl goto this path and run the curl command it will work.

Upvotes: 2

Related Questions