Next: About this document ...
Up: 課題1
Previous: 課題1
telnetコマンドを使って任意のWWWサーバにアクセスし、任意のURLのページデータ(htmlソースプログラム)を画面に表示せよ。(報告書にはそのURLとページデータの先頭の20行程度を添付せよ)
telnetは任意に指定したホスト先に接続してログインすることができるコマンドである。
以下に、渦中のlivedoorのトップページのHTMLソースを、telnetをポート80で接続し、結果を示す。
・実行結果
[j04021@pw021 ~]% telnet livedoor.com 80
Trying 203.131.197.197...
Connected to livedoor.com.
Escape character is '^]'.
GET /index.html HTTP/1.0
HTTP/1.1 200 OK
Date: Fri, 27 Jan 2006 07:16:17 GMT
Server: Apache/1.3.33 (Unix) mod_perl/1.29
Set-Cookie: ad=[B@1997cf9; Domain=.livedoor.com; Expires=Sat, 27-Jan-2007 07:16:18 GMT; Path=/
Pragma: no-cache
Cache-Control: private
Vary: User-Agent
Content-Type: text/html; charset=euc-jp
X-Cache: MISS from www.livedoor.com
Connection: close
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=euc-jp">
<title>livedoor</title>
<meta name="description" content="ライブドアが運営するポータルサイト。ブログ、検索、ニュース、メール、地図、ウィキなどを提供。">
<meta name="Keywords" content="ライブドア,ブログ,blog,検索,サーチ,ニュース,メール,地図,ウィキ,wiki,ソーシャルネットワーク,辞書,ファイナンス,ショッピング,コンピュータ,">
~~~ 中略 ~~~~~~~~~~
</body>
</html>
Connection closed by foreign host.
[j04021@pw021 ~]%
fumiya nakamura
2006-01-27