卷曲:为什么我得到空洞的回应?

时间:2016-07-19 13:45:28

标签: ssl curl

我使用谷歌开发者工具并将答案复制为卷曲请求

enter image description here

当我在我的linux服务器上运行卷曲时,我得到来自服务器的空回复

curl 'https://web-ast.dsi.cnrs.fr/l3c/owa/personnel.liste?nom=&prenom=&code_labo=&p_dep=52&sec=&bap=&emptype=&nat_pers=&typ_pers=&organisme=&delegation=&ville=&p_i=0&p_nb_res=0' \
-H 'Accept-Encoding: gzip, deflate, sdch, br' -H 'Accept-Language: fr-FR,fr;q=0.8,en-US;q=0.6,en;q=0.4,es;q=0.2,pl;q=0.2' \
-H 'Upgrade-Insecure-Requests: 1' -H 'User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36' \
-H 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8' \
-H 'Cache-Control: max-age=0' -H 'Connection: keep-alive' \
--compressed

curl: (52) Empty reply from server

详细输出:

* Hostname was NOT found in DNS cache
*   Trying 193.52.36.99...
* Connected to web-ast.dsi.cnrs.fr (193.52.36.99) port 443 (#0)
* successfully set certificate verify locations:
*   CAfile: none
  CApath: /etc/ssl/certs
* SSLv3, TLS handshake, Client hello (1):
* SSLv3, TLS handshake, Server hello (2):
* SSLv3, TLS handshake, CERT (11):
* SSLv3, TLS handshake, Server finished (14):
* SSLv3, TLS handshake, Client key exchange (16):
* SSLv3, TLS change cipher, Client hello (1):
* SSLv3, TLS handshake, Finished (20):
* SSLv3, TLS change cipher, Client hello (1):
* SSLv3, TLS handshake, Finished (20):
* SSL connection using AES256-SHA
* Server certificate:
*    subject: OU=Domain Control Validated; CN=web-ast.dsi.cnrs.fr
*    start date: 2013-10-21 00:00:00 GMT
*    expire date: 2016-10-20 23:59:59 GMT
*    subjectAltName: web-ast.dsi.cnrs.fr matched
*    issuer: C=NL; O=TERENA; CN=TERENA SSL CA
*    SSL certificate verify ok.
> GET /l3c/owa/personnel.liste?nom=&prenom=&code_labo=&p_dep=52&sec=&bap=&emptype=&nat_pers=&typ_pers=&organisme=&delegation=&ville=&p_i=0&p_nb_res=0 HTTP/1.1
> Host: web-ast.dsi.cnrs.fr
> Accept-Encoding: gzip, deflate, sdch, br
> Accept-Language: fr-FR,fr;q=0.8,en-US;q=0.6,en;q=0.4,es;q=0.2,pl;q=0.2
> Upgrade-Insecure-Requests: 1
> User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36
> Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
> Cache-Control: max-age=0
> Connection: keep-alive
> 
* SSLv3, TLS alert, Client hello (1):
* Empty reply from server
* Connection #0 to host web-ast.dsi.cnrs.fr left intact
curl: (52) Empty reply from server

知道为什么吗?

1 个答案:

答案 0 :(得分:0)

  

-k,--insecure(SSL)此选项明确允许curl执行“不安全”的SSL连接和传输。通过使用默认安装的CA证书捆绑包,尝试使所有SSL连接安全。这使得所有被认为是“不安全”的连接都会失败,除非使用-k,-insecure。

试试这个兄弟。