Я правильно установил flutter SDK, но теперь flutter doctor не работает.

$ set | grep SSL
SSL_CA_CERT_FILE=/Users/agoyal3/certs/ca.pem
SSL_CA_CERT_PATH=/Users/agoyal3/certs
SSL_CERT_FILE=/Users/agoyal3/certs/server-crt.pem
SSL_KEY_FILE=/Users/agoyal3/certs/server-key.pem

$ pwd
/Users/agoyal3/temp/flutter/bin

$ ./flutter doctor
Downloading Dart SDK from Flutter engine ead227f118077d1f2b57842a32abaf105b573b8a...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: https://curl.haxx.se/docs/sslcerts.html

curl performs SSL certificate verification by default, using a "bundle"
 of Certificate Authority (CA) public keys (CA certs). If the default
 bundle file isn't adequate, you can specify an alternate file
 using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
 the bundle, the certificate verification probably failed due to a
 problem with the certificate (it might be expired, or the name might
 not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
 the -k (or --insecure) option.
0
AG1 1 Мар 2018 в 06:49

1 ответ

Лучший ответ

Возможно, в вашей системе отсутствуют действующие сертификаты SSL.

Попробуйте сделать:

  1. Загрузите последние сертификаты здесь

  2. Затем установите это как SSL_CA_CERT_PATH и файл как SSL_CA_CERT_FILE

Надеюсь, это поможет!

1
Hemanth Raj 1 Мар 2018 в 09:55