smtp、pop3についてのコマンドレスポンスについて
SMTPでのメールの送り方について
$ telnet localhost 25 <---入力 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. 220 vmvine32.mie-chukyo-u.ac.jp ESMTP Postfix HELO localhost 250 vmvine32.mie-chukyo-u.ac.jp MAIL FROM: <okada@localhost> <---入力 250 Ok RCPT TO: <okada@localhost> <---入力 250 Ok DATA <---入力 354 End data with <CR><LF>.<CR><LF> From: <okada@localhost> <---入力 To: <okada@localhost> <---入力 Subject: TEST1 <---入力 <---入力 TEST MSG. <---入力 . <---入力 250 Ok: queued as 6767B5BCC2 QUIT <---入力 221 Bye Connection closed by foreign host.
pop3でのメールの受信について
$ telnet localhost 110 <---入力 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. +OK Qpopper (version 4.0.9) at vmvine32.mie-chukyo-u.ac.jp starting. <14168.1160013216@vmvine32.mie-chukyo-u.ac.jp> USER okada <---入力 +OK Password required for okada. PASS ****** <---入力 +OK okada has 1 visible message (0 hidden) in 509 octets. LIST <---入力 +OK 1 visible messages (509 octets) 1 509 . RETR 1 <---入力 +OK 509 octets Return-Path: <okada@vmvine32.mie-chukyo-u.ac.jp> X-Original-To: okada Delivered-To: okada@vmvine32.mie-chukyo-u.ac.jp Received: by vmvine32.mie-chukyo-u.ac.jp (Postfix, from userid 500) id 34A685BCC2; Thu, 5 Oct 2006 10:46:45 +0900 (JST) To: okada@vmvine32.mie-chukyo-u.ac.jp Subject: TEST2 Message-Id: <20061005014645.34A685BCC2@vmvine32.mie-chukyo-u.ac.jp> Date: Thu, 5 Oct 2006 10:46:45 +0900 (JST) From: okada@vmvine32.mie-chukyo-u.ac.jp (Okada) X-UIDL: Cc5!!DhV"!fUI"!5>*"! TEST MSG2. . QUIT <---入力 +OK Pop server at vmvine32.mie-chukyo-u.ac.jp signing off. Connection closed by foreign host.
メッセージの削除(認証後)
LIST <---入力 +OK 2 visible messages (1029 octets) 1 521 2 508 (略) DELE 1 <---入力(削除) +OK Message 1 has been deleted. LIST <---入力 +OK 1 visible messages (508 octets) 2 508
$ telnet localhost 110 <---入力 Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. +OK Qpopper (version 4.0.9) at vmvine32.mie-chukyo-u.ac.jp starting. <14230.1160013800@vmvine32.mie-chukyo-u.ac.jp> <---(チャレンジワード) APOP okada 1c576f**************30639dace3af <---入力(MD5ハッシュ値) +OK okada has 1 visible message (0 hidden) in 520 octets. LIST <---入力 +OK 1 visible messages (520 octets) 1 520 . QUIT <---入力 +OK Pop server at vmvine32.mie-chukyo-u.ac.jp signing off. Connection closed by foreign host.
APOPでのMD5のハッシュ値を作成するにはチャレンジワードとパスワードを連続文字列として作成する。
上記の場合はパスワードが*****の場合は
$ echo -n '<14230.1160013800@vmvine32.mie-chukyo-u.ac.jp>*****' | md5sum
1c576f**************30639dace3af -