2016年10月26日 星期三

Error: server certificate verification failed.


My newly installed ARM64 Ubuntu complaint about certificate verification fail, on apt-get update, wget,..., e.g.

Err https://private-ppa.launchpad.net trusty/main arm64 Packages
  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
WFetched 3853 kB in 21s (180 kB/s)
: Failed to fetch https://private-ppa.launchpad.net/yarmouth-team/15.11/ubuntu/dists/trusty/main/binary-arm64/Packages  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
There are lots of info there that I think is useful:
/etc/ssl/certs/
/etc/ssl/certs/ca-certificates.crt

echo -n | openssl s_client -showcerts -connect private-ppa.launchpad.net:443 2>/dev/null  | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p'

curl-config --ca
sudo update-ca-certificates
But what really fix the issue is the time. Yes, I know certificates has valid started date and expiration date, but I just didn't check it!!!
root@ubuntu:~/prj/opencord# date
Thu Jan  1 16:53:04 PST 1970
server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none - Stack Overflow
http://stackoverflow.com/questions/21181231/server-certificate-verification-failed-cafile-etc-ssl-certs-ca-certificates-c

How to install certificates for command line - Ask Ubuntu
http://askubuntu.com/questions/645818/how-to-install-certificates-for-command-line

沒有留言: