Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to establish SSL connection upon wget on Ubuntu 14.04 LTS

I tried to download an image through wget but I got an error: Unable to establish SSL connection.

wget https://www.website.com/image.jpg --2015-02-26 01:30:17--  https://www.website.com/image.jpg Resolving www.website.com (www.website.com)... xx.xxx.xx.xx Connecting to www.website.com (www.website.com)|xx.xxx.xx.xx|:443... connected. Unable to establish SSL connection. 

My test case:

  1. Using Ubuntu 12.04.4 LTS (GNU/Linux 3.8.0-44-generic x86_64), GNU Wget 1.13.4 built on linux-gnu, I was able to download the image using the code above. No error.
  2. Using Ubuntu 14.04 LTS (GNU/Linux 3.13.0-24-generic x86_64), GNU Wget 1.15 built on linux-gnu, I was not able to download the image using the code above.

Another variable is that the www.website.com uses TLS 1.0. I don't have an idea how this affects wget. But if I wget an image from TLS 1.2 websites I don't get any ssl connection errors from both test cases.

Is Ubuntu 14.04 or wget 1.15 not compatible with TLS 1.0 websites? Do I need to install/download any library/software to enable this connection?

like image 398
xanderlopez Avatar asked Feb 27 '15 03:02

xanderlopez


1 Answers

you must be using old version of wget i had same issue. i was using wget 1.12.so to solve this issue there are 2 way: Update wget or use curl

curl -LO 'https://example.com/filename.tar.gz' 
like image 192
ParasPatel Avatar answered Oct 03 '22 19:10

ParasPatel