curl:发起http(s)请求,查看http(s)通信过程

作者: 李佶澳   转载保留:原文地址   更新时间:2018/08/10 13:46:58

说明

curl是一个特别方便的用于http(s)客户端。

查看完整过程

 curl -v http://www.baidu.com
 curl -v http://www.baidu.com
* Rebuilt URL to: http://www.baidu.com/
*   Trying 103.235.46.39...
* TCP_NODELAY set
* Connected to www.baidu.com (103.235.46.39) port 80 (#0)
> GET / HTTP/1.1
> Host: www.baidu.com
> User-Agent: curl/7.54.0
> Accept: */*
>
< HTTP/1.1 200 OK
< Server: bfe/1.0.8.18
...

https

curl -k --cacert $ca_file  --key $key_file --cert $cert_file https://XXXX

参考

  1. curl详细用法

本文原创首发于网站:www.lijiaocn.com

QQ交流群

区块链实践互助QQ群:576555864

Kubernetes实践互助QQ群:947371129

Prometheus实践互助QQ群:952461804

Kong/Envoy实践互助QQ群:952503851

Ansible实践互助QQ群:955105412

Copyright @2011-2019 All rights reserved. 转载请添加原文连接,合作请加微信lijiaocn或者发送邮件: [email protected],备注网站合作 友情链接: lijiaocn github.com