Linux模拟HTTP请求:
[root@VM_0_2_centos nginx]# curl http://localhost?wd=wwl\&lover=xq
access.log:
127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
客户端请求地址:127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
客户端请求验证的用户名:这里没有,空
127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
本地时间:127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
完整的原始请求行:127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
服务端响应的状态码:127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
服务端返回给客户端字节大小:127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
告诉服务端我是从哪个页面链接过来的:127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
请求的具体客户端是什么(IE、Chrome、FireFox等):127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
客户端请求的真实IP,如果代理存在,即有值,否则没值:127.0.0.1 - - [10/Dec/2018:20:06:48 +0800] "GET /?wd=wwl&lover=xq HTTP/1.1" 200 635 "-" "curl/7.29.0" "-" "wwl"-"wd=wwl&lover=xq"-"-"-"-"-"localhost"-"Sat, 08 Dec 2018 04:13:40 GMT"
Nginx下一小节:Nginx 模块介绍