Como depurar curl? gnutls_handshake failed - pacote TLS inesperado (OpenSSL)

1

Como posso depurar ainda mais o erro de curl quando o Apache error.log não está mostrando nenhum?

(35) gnutls_handshake() failed: An unexpected TLS packet was received.

curl -v https://example.com
* Rebuilt URL to: https://example.com/
*   Trying 127.0.0.1...
* Connected to example.com(127.0.0.1) port 443 (#0)
* found 151 certificates in /etc/ssl/certs/ca-certificates.crt
* found 612 certificates in /etc/ssl/certs
* ALPN, offering http/1.1
* gnutls_handshake() failed: An unexpected TLS packet was received.
* Closing connection 0

Ubuntu 16.04, apache2 trabalhando com SSL.

ATUALIZAÇÃO:

echo | openssl s_client -connect example.com:443

CONNECTED(00000003)
139626124003072:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:252:
---
no peer certificate available
---
No client certificate CA names sent
---
SSL handshake has read 5 bytes and written 176 bytes
Verification: OK
---
New, (NONE), Cipher is (NONE)
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
SSL-Session:
    Protocol  : TLSv1.2
    Cipher    : 0000
    Session-ID:
    Session-ID-ctx:
    Master-Key:
    PSK identity: None
    PSK identity hint: None
    SRP username: None
    Start Time: 1531383152
    Timeout   : 7200 (sec)
    Verify return code: 0 (ok)
    Extended master secret: no
---

UPDATE2 - RESOLVIDO

Tinha uma linha em branco no meu arquivo de corrente e o RootCA não estava instalado corretamente no servidor em que eu executava o comando openssl.

    
por Markus 11.07.2018 / 17:54

1 resposta

2

Eu tinha uma linha em branco no meu arquivo de corrente e o RootCA não estava instalado corretamente no servidor do qual eu executei o comando openssl. Uma vez fixo, enrole bem.

    
por 12.07.2018 / 17:44