curl and wget

1. curl 

-s silent -v output -L 302 Tracking Details

-w custom output formats such as 

 -w %{http_code}   curl -o /dev/null -s -w "time_connect: %{time_connect}\ntime_starttransfer: %{time_starttransfer}\ntime_total: %{time_total}\n

-x agent

-I only output request header, -i include request content and header

-A custom user-agent

curl -A "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)"

-H custom header

The default request content output to the screen, -o output redirection, you can directly request https

json -d POST request data, such as

curl -H "Content-type:Application/json" -d '{"hostname": "CNC-WV-b-D40", "result": {"hostname": "hostname", "network": [{"DEVICE": "bond0", "IPADDR": "1.1.1.1"}, {"DEVICE": "bond1", "IPADDR": "10.11.100.32"}], "service_tag": "060580bD40"}}'  "url"

 

 

plus access https proxy mode --resolv blog.csdn.net:443:47.95.47.253

 

Guess you like

Origin www.cnblogs.com/brucewhite/p/11051643.html