这就是我试过的
telnet www.google.com 80
Get HTTP/1.1 Host:www.google.com
这是我收到的回复
HTTP/1.0 400 Bad Request
Content-Type: text/html; charset=UTF-8
Content-Length: 925
Date: Sat, 24 Nov 2012 19:37:42 GMT
Server: GFE/2.0
如何使这项工作?我尝试使用telnet访问www.google.com
答案 0 :(得分:9)
$ telnet www.google.com 80
Trying 173.194.38.82...
Connected to www.google.com.
Escape character is '^]'.
GET / HTTP/1.1
HTTP/1.1 302 Found
Location: http://www.google.co.jp/
Cache-Control: private
Content-Type: text/html; charset=UTF-8
[.... skipped ....]
答案 1 :(得分:3)