sto testando l'accesso SSL a un server nodo locale con la chiave, ca, cert in opzioni (auto-firmato w OpenSSL)SSL errore di certificato
var server_options = {
key: fs.readFileSync('/etc/ssl/self-signed/server.key'),
ca: fs.readFileSync('/etc/ssl/self-signed/server.csr'),
cert: fs.readFileSync('/etc/ssl/self-signed/server.crt')
};
cercando di accedervi:
curl -v --user 1234567890:abcdefghijklmnopqrstuvwxyz --data "grant_type=password&username=yves&password=123456789" https://macMini.local:8000/oauth/token
utilizzando ricciolo ottengo il seguente errore:
curl: (60) SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
ho scaricato il certificato CA da http://curl.haxx.se/ca/cacert.pem e aggiungerli al mio curl-c a-fascio-new.crt di file, come suggerito in alcuni commenti su arricciare ... ma c'è modo
ecco il registro
- About to connect() to macMini.local port 8000 (#0)
- Trying 192.168.1.14...
- connected
- Connected to macMini.local (192.168.1.14) port 8000 (#0)
- SSLv3, TLS handshake, Client hello (1):
- SSLv3, TLS handshake, Server hello (2):
- SSLv3, TLS handshake, CERT (11):
- SSLv3, TLS alert, Server hello (2):
- SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
- Closing connection #0 curl: (60) SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed More details here: http://curl.haxx.se/docs/sslcerts.html
so di poter bypassare il controllo Curl CA, utilizzando:
curl -k -v --user 1234567890:abcdefghijklmnopqrstuvwxyz --data "grant_type=password&username=yves&password=123456789" https://macMini.local:8000/oauth/token
nel qual caso è in esecuzione bene, posso vedere:
SSL certificate verify result: self signed certificate (18), continuing anyway.
ma mi piacerebbe sapere se c'è un modo t o risolvere questo problema ...
grazie, ho appena avuto qualche difficoltà a trovare dove cacert.pem si trovava su OSX (10.8) vedi sopra .... – erwin