gpt4 book ai didi

ssl - curl:为什么我得到空响应?

转载 作者:太空宇宙 更新时间:2023-11-03 14:46:36 25 4
gpt4 key购买 nike

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

enter image description here

当我在我的 Linux 服务器上运行 curl 时,我得到了来自服务器的空回复

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

知道为什么吗?

最佳答案

-k, --insecure (SSL) This option explicitly allows curl to perform "insecure" SSL connections and transfers. All SSL connections are attempted to be made secure by using the CA certificate bundle installed by default. This makes all connections considered "insecure" fail unless -k, --insecure is used.

兄弟,试试这个。

关于ssl - curl:为什么我得到空响应?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38460424/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com