JP4446330B2 - Communication device - Google Patents

Communication device Download PDF

Info

Publication number
JP4446330B2
JP4446330B2 JP2003075256A JP2003075256A JP4446330B2 JP 4446330 B2 JP4446330 B2 JP 4446330B2 JP 2003075256 A JP2003075256 A JP 2003075256A JP 2003075256 A JP2003075256 A JP 2003075256A JP 4446330 B2 JP4446330 B2 JP 4446330B2
Authority
JP
Japan
Prior art keywords
authentication
authentication method
communication
server
server device
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2003075256A
Other languages
Japanese (ja)
Other versions
JP2004287492A (en
Inventor
直樹 若杉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ricoh Co Ltd
Original Assignee
Ricoh Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to JP2003075256A priority Critical patent/JP4446330B2/en
Publication of JP2004287492A publication Critical patent/JP2004287492A/en
Application granted granted Critical
Publication of JP4446330B2 publication Critical patent/JP4446330B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Description

【0001】
【発明の属する技術分野】
この発明は、ネットワークを介して接続した外部装置と通信可能な情報処理装置,通信端末装置,出力装置などの通信装置に関し、特に外部装置に認証情報を送信して認証処理を要求する機能を持つ通信装置に関する。
【0002】
【従来の技術】
近年、インターネット上で提供されるサービスやアプリケーションの普及は目覚しく、様々な通信装置がネットワークを介して相互に接続され、盛んに通信を行なうようになっている。このような通信装置には、例えばパーソナルコンピュータ(PS),ワークステーション(WS)等の情報処理装置、携帯情報端末(PDA),携帯電話等の通信端末装置などがある。
また最近では、ファクシミリ装置(FAX)やスキャナ等の画像読取装置、プリンタ等の画像形成装置、家電製品、医療装置などに通信機能を設けてインターネットを介した通信を可能にした通信装置もある。これらの通信装置は、その殆どが標準化したTCP/IP(Transfer Control Protocol/Internet Protocol)を利用しており、機種の違いを超えて互いにネットワーク上で情報をやりとりできる。
【0003】
ところで、インターネットは不特定多数のユーザが利用するため、他人になりすまして情報の盗み見や改竄を行ういわゆる「なりすまし」による被害が発生する危険性が高い。
そのため、インターネットを利用した通信では、例えばユーザがクライアント装置を用いて外部装置と情報を送受信するときに、ユーザが本人であるかどうか識別して正当なアクセス権があるかどうかを検証するいわゆる「認証」を行ったり、情報の機密性を確保するために情報を暗号化して送受信したりしている。
【0004】
例えば特許文献1に見られるように、ユーザがセキュリティの確保されていない外部ネットワーク上の利用端末からゲートウェイを介して内部ネットワークにアクセスして、内部ネットワーク上のメールサーバに蓄積した機密性の高い電子メールを閲覧するときに、メールサーバがその電子メールを抽出して複製し、本文をユーザが予め入力した暗号化鍵を用いて暗号化した後に外部ネットワーク上に設けた中継サーバに転送する電子メール転送方法がある。
なお、この電子メール転送方法では、外部ネットワーク上でこの電子メールを閲覧するには中継サーバによって認証を受ける必要があり、さらに暗号化された電子メールを復号化する必要があるため、電子メールの機密性は高く保持される。
【0005】
なお、認証方式には、ユーザIDやパスワードなどの認証情報を暗号化して送受信する方式(本明細書では「暗号化認証方式」と云う)と、平文のまま送受信する方式(本明細書では「平文認証方式」と云う)とがある。
また、暗号方式には、暗号化と復号化に同じ鍵を用いる共通鍵暗号(秘密鍵暗号)と、対になった公開鍵と秘密鍵とを使用する公開鍵暗号(非対称暗号)とに大別される様々な方式があり(特許文献2参照)、各々暗号の強度や処理速度などが異なる。
例えば、共通鍵暗号には、DES(Data Encryption Standard:デス)、RC2(Ron's Code 2)、RC4などの暗号方式がある。
【0006】
一方、公開鍵暗号には、RSA(Rivest Shamir Adleman)、楕円曲線暗号、エルガマル暗号などの暗号方式がある。
さらに、情報の原文から固定長の疑似乱数を生成して通信経路の両端で比較することで通信途中での改竄の有無を検出する、MD5(Massage Digest 5)などのハッシュ関数も一般的に使用されている。
ユーザは、このような様々な認証方式および暗号方式の中から、クライアント装置および外部装置の暗号化処理能力や、通信する情報の機密性などに応じて適切なものを選択し、クライアント装置が格納している通信用プログラムなどを用いて設定すれば、自分の好みに応じた認証方式および暗号方式で安全に通信を行うことができる。
【0007】
【特許文献1】
特開平11−88410号公報
【特許文献2】
特開平11−122238号公報
【0008】
【発明が解決しようとする課題】
しかしながら、このときクライアント装置および外部装置が共にサポートしている認証方式および暗号方式以外のものをユーザが設定すると、クライアント装置と外部装置との間で正常な通信ができなくなってしまうという問題点があった。
例えば、インターネットのプロトコルの一種であるSMTP(Simple Mail Transfer Protocol)にユーザ認証機能を追加したSMTP−AUTH(Authentication)では、外部装置であるSMTPサーバがサポートしている認証方式の一覧からクライアント装置側が任意のものを選択し指定するが、このときクライアント装置がサポートしていない認証方式を指定してしまうとエラーになって通信できない。
【0009】
そのため、ユーザは、クライアント装置がサポートしている認証方式および暗号方式と、外部装置がサポートしている認証方式および暗号方式との両方を調査し、クライアント装置と外部装置とが共にサポートしているものを選択する必要がある。
しかし、ユーザの大半はインターネットのプロトコルにまで詳しいわけではないため、このような認証方式および暗号方式の調査や設定が過剰な負担になるという問題点があった。
【0010】
例えば、通信用プログラムである電子メールソフトには、接続するSMTPサーバに認証情報を送信するかどうかを設定する項目があるが、ユーザは、接続先のSMTPサーバがSMTP−AUTHに対応しているかどうかすら判らない場合が多い。
この場合、ユーザは、接続するSMTPサーバが認証に対応しているかどうか、また認証が必須かどうかを調査して、SMTPサーバに認証情報を送信するかどうかを設定する必要がある。さらに、認証情報を送信すると設定した場合はクライアント装置とSMTPサーバとが共にサポートしている暗号方式があるかどうかを調査する必要がある。
【0011】
この発明は上記の問題点に鑑みてなされたものであり、ネットワークを介して外部装置と通信可能な通信装置において、自機(クライアント装置)および外部装置が対応している認証方式を調査したり設定したりしなくても、外部装置に応じた適切な認証方式で認証を行うことができるようにすることを目的とする。
【0012】
【課題を解決するための手段】
この発明は、上記の目的を達成するため、ネットワークを介して接続する外部装置と通信する通信手段と、その外部装置に認証情報を送信して認証処理を要求する認証要求手段とを有する通信装置において、当該通信装置が対応している認証方式の情報を、暗号化認証方式と平文認証方式とに区分して記憶手段に記憶しており、上記外部装置が当該通信装置からの要求に応じて送信してくる、上記外部装置が対応している認証方式の情報を参照し、まず、上記記憶手段に記憶している暗号化認証方式と、上記外部装置が対応している認証方式とを順に比較し、一致するものがない場合に、上記記憶手段に記憶している平文認証方式と、上記外部装置が対応している認証方式とを順に比較し、これらの比較において最初に一致した認証方式を選択することによって、その外部装置と当該通信装置との双方が対応している認証方式のうち1つの認証方式を選択する認証方式選択手段を設け、上記認証要求手段が、認証方式選択手段が選択した認証方式に応じた認証情報を外部装置に送信し、その認証方式での認証処理を要求するようにしたものである。
なお、ネットワークを介して接続する外部装置をSMTPサーバまたはPOP3サーバまたはIMAP4サーバとしてもよい。
【0013】
また、これらの通信装置に、ネットワークを介して上記外部装置との間で画像情報を送受信する画像情報通信手段を設けるとよい。
さらに、上記認証方式選択手段が選択する認証方式の範囲を制限する指示を受け付ける選択指示受付手段を設けるとよい。なお、その選択指示受付手段は、受け付けた指示に従って、上記認証方式選択手段を、上記認証情報を暗号化して送信する暗号化認証方式の中から上記1つの認証方式を選択する第1のモード、上記認証情報を平文で送信する平文認証方式の中から上記1つの認証方式を選択する第2のモード、上記暗号化認証方式および上記平文認証方式の中から上記1つの認証方式を選択する第3のモードのいずれかに設定するものである。
【0014】
また、これらの通信装置に、認証要求手段の動作の有効/無効を設定する手段を設けるとよい。
さらに、認証要求手段が認証要求を行った場合、その認証要求に係る認証方式と、外部装置による認証結果とを記憶する記憶手段を設けるとよい。
【0015】
【発明の実施の形態】
以下、この発明の実施の形態を図面に基づいて説明する。
まず、この発明による通信装置が接続するネットワークの構成例について説明する。図2は、そのネットワークの構成を示す図である。この図2において、ワークステーション等の通信装置および外部装置と共に括弧書きで示したアドレスは、その装置と対応する電子メールアドレスである。この点については後述する。
【0016】
このネットワークは、それぞれLAN(ローカルエリアネットワーク)であるネットワーク1およびネットワーク2を、ルータ装置5または6を介してインターネット3に接続したものである。
そして、ネットワーク1には、この発明による通信装置であるワークステーション(WS)11およびスキャナ12が、サーバ装置13,WS14,FAX装置15など様々な種類の多くの外部装置と共に接続している。一方、ネットワーク2にも、サーバ装置23、WS21,24、FAX装置22など多くの外部装置が接続している。
これらの各通信装置および外部装置はそれぞれ通信機能を備えており、ネットワークを介した通信が可能である。
【0017】
なお、スキャナ12は画像読取手段を備えた画像読取装置であり、FAX装置15,22は画像形成手段を備えた画像形成装置である。
このスキャナ12およびFAX装置15,22はファクシミリ通信(FAX)機能も備えており、PSTN(Public Switched Telephone Networks:一般の加入電話回線網)またはISDN(Integrated Services Digital Network:デジタル通信網)などの公衆網4を介した通信も可能である。しかし、このFAX機能および公衆網4への接続は本発明に必須のものではない。
【0018】
なお、スキャナ12およびWS11については、その詳細を後述する。また、FAX装置15,22については、本発明に特有のものでも必須のものでもないため詳細な説明を省略する。
また、サーバ装置13はメールサーバであり、インターネット3に常時接続し、ネットワーク1に接続したクライアント装置(WS11、WS14、スキャナ12、FAX装置15)が行う電子メールの送受信を管理する。同様に、サーバ装置23はネットワーク2に接続したクライアント装置(WS21、WS24、FAX装置22)が行う電子メールの送受信を管理する。
【0019】
なお、メールサーバには、他のネットワークのクライアント装置に電子メールを送信するサーバ(SMTPサーバなど)と、自ネットワーク内のクライアント装置宛に送られてきた電子メールを保管して、ユーザからのダウンロード要求に対応するサーバ(POP3サーバやIMAP4サーバなど)とがあるが、サーバ装置13,23はこれらの両方の機能を備えているものとする。
【0020】
<第1の実施形態>
次に、この発明の通信装置の第1の実施形態である、図2に示したワークステーション11について詳細に説明する。
まず、図1の機能ブロック図に、このワークステーションの機能構成を示す。なお、この図においては、この発明に関連する部分の機能のみを示している。
このワークステーション(WS)11は、ハードウェアとしては、CPU,ROM,RAM,HDD(ハードディスクドライブ),通信インタフェース(I/F)等を備えたPC(パーソナルコンピュータ)等の公知のコンピュータを用いることができる。
【0021】
そして、CPUは、ROMやHDDに記憶している種々の制御プログラムを実行することにより、WS11全体を統括制御する制御部16として機能する。また、記憶部17の機能は、ROM,RAM,HDD等の記憶手段によって実現される。また通信I/F18は、ネットワークを介して接続するサーバ装置13等の外部装置と通信するための通信手段である。
また、この発明に係る機能として、制御部16は、認証方式選択部25と認証要求部26の機能を有する。
認証方式選択部25は、外部装置と通信を行う際にその外部装置に応じて認証方式を自動的に選択する認証方式選択手段として機能し、認証要求部26は、認証方式選択部25が選択した認証方式に応じた認証情報を外部装置に送信し、その認証方式での認証処理を要求する認証要求手段として機能する。
【0022】
以下、このようなWS11がサーバ装置13に対して通信を要求する場合の動作について、例を挙げて説明する。なお、以下の動作例において、WS11の記憶部17にはユーザが予め登録したユーザID(ユーザ名)およびパスワードと、サーバ装置のアドレス(図2に示した“msrv13.abc.co.jp”)とが格納されているものとする。
【0023】
≪第1の動作例:サーバ装置13がSMTPサーバとして機能する場合≫
まず、ワークステーション(WS)11のユーザが、SMTP(Simple Mail Transfer)サーバとして機能するサーバ装置13を介して、図2に示したネットワーク2に接続したワークステーション21のユーザに電子メールを送信する場合の動作について、図4〜図6に示す通信シーケンスを参照しながら、図3のフローチャートに沿って具体的に説明する。
なお、図4はサーバ装置が認証処理に対応している場合の通信シーケンスの一例を示す図であり、図5はサーバ装置が認証処理に対応していない場合の通信シーケンスの一例を示す図である。また、図6はサーバ装置がESMTPモードに対応していない場合の通信シーケンスの一例を示す図である。これらの通信シーケンスにおいて、実線の矢印はWS11からサーバ装置13へ送信するリクエストを示し、破線の矢印はサーバ装置13からWS11へ返信するレスポンスを示す。
【0024】
WS11のユーザがメールソフトウェアなどを用いてWS21のユーザ宛の電子メールを作成すると共に、メールヘッダのTO:フィールドにWS21のアドレス(図2に示した“msrv23.xyz.co.jp”)を電子メールの送信先として指定して送信を指示すると、WS11のCPUは図3のフローチャートに示す処理を開始する。
そして、まずステップS1でサーバ装置13とTCPポート25(この「25」はTCP/IP(Transmission Control Protocol/Internet Protocol)の規格であり、本明細書の符号ではない)で通信の接続を行う。この通信の接続は、図4〜図6に示すようにサーバ装置13に接続を要求するリクエストR1を送信することによって行う。なお、サーバ装置13は、接続要求を受け付けると接続応答を示すレスポンスR2を返す。
【0025】
ステップS1で通信が接続されると、次のステップS2でESMTP(SMTP service Extensions)モードへの移行をサーバ装置13に要求する。
このESMTPモードへの移行要求は、例えば図4〜図6のリクエストR3に示すように、サーバ装置13に対し、ESMTPモードへの移行を要求する「EHLO」コマンドと共にWS11のホスト名(この例では“ws11.abc.co.jp”)を送信することによって行う。
次のステップS3では、サーバ装置13がESMTPモードに対応しているか否か判断する。サーバ装置13は、ステップS2で送信した要求に対し、ESMTPモードに対応しているか否かによって異なる応答を返すので、受け取った応答を基にこの判断を行うことができる。
【0026】
なおこのときサーバ装置13は、ESMTPモードに対応している場合には、ESMTPモードへの移行処理を正常終了したことを示す応答と共に、クライアント装置が拡張機能で使用できるコマンドの一覧も返す。
例えば図4に示す例では、サーバ装置13はレスポンスR4として、ESMTPモードへの移行処理が正常終了したことを示すリプライコード250番の「250−Hello wsll.abc.co.jp」と共に、EXPN,SIZE,AUTH,HELPの4つのコマンドが使用できる旨の応答を返している。このうちAUTHが、使用する認証方式を指定するコマンドであり、ここでは「250−AUTH LOGIN CRAM−MD5」によって、「LOGIN」及び「CRAM−MD5」の方式が選択可能であることを示している。
【0027】
また、図5に示す例では、サーバ装置13はレスポンスR4′として、ESMTPモードへの移行処理が正常終了し、EXPN,SIZE,HELPの3つのコマンドが使用でき、AUTHコマンドは使用できない旨の応答を返している。図3の説明に戻ると、ステップS3の判断がYESであった場合、ステップS4に進んでサーバ装置13が認証処理に対応しているか否か判断する。この判断は、上記のレスポンスにおける、AUTHコマンドが使用できる旨の応答の有無によって判断することができる。そして、使用可能であれば認証処理に対応しており、そうでなければ対応していないと判断する。
【0028】
ステップS4でサーバ装置が認証処理に対応していると、ステップS5に進み、サーバ装置13が対応している認証方式の中に自機も対応しているものがあるか否か判断する。この判断は、上記のレスポンスにおける、「250−AUTH」の引数によって判断することができる。例えばレスポンスR4の場合には、サーバ装置13が「LOGIN」及び「CRAM−MD5」に対応していることが分かるので、自機がこれらに対応しているか否かをもとに判断すればよい。
ステップS5の判断がYESであればステップS6に進み、その認証方式を使用する認証方式として選択する。この時複数の候補があれば、その中から適当な1つを選択するが、この場合の選択基準については、例えば認証情報を暗号化して送信する方式を優先する、ユーザが定めた優先順位に従う、等が考えられる。
【0029】
そして、次のステップS7で、ステップS6で選択した認証方式による認証処理を、サーバ装置13に対して要求する。図4に示す例では、リクエストR5の「AUTH CRAM−MD5」がこの要求に相当し、CRAM−MD5(Challenge Response Authentication Mechanism−Message Digest 5)方式による認証処理を要求する旨の要求である。
次のステップS8では、ステップS7で要求した認証方式に応じた認証情報をサーバ装置13に送信する。この認証情報としては、パスワードや暗号化データ等が考えられるが、上記のCRAM−MD5方式においては、サーバ装置13から受信するチャレンジ文字列にパスワードを加えた文字列をハッシュ関数であるMD5で処理して求めたハッシュ値と、ユーザIDである。
【0030】
図4に示す例では、CRAM−MD5方式による認証処理を要求するリクエストR5を受信したサーバ装置13は、レスポンスR6として、認証処理を開始したことを示すリプライコード334番と共に適当なチャレンジ文字列を返すので、WS11は、このチャレンジ文字列に上記の処理を施して得たハッシュ値(暗号化文字列)とユーザIDとを、リクエストR7としてサーバ装置13に送信している。
サーバ装置13は、送信したチャレンジ文字列に受信したユーザIDと対応するパスワードを加えた文字列をMD5で処理してハッシュ値を求め、受信したハッシュ値と比較することにより、クライアント装置11が用いたパスワードが正しいものであるか否かを判断することができる。
【0031】
ステップS8の後は、ステップS9に進み、認証が成功であったか否か判断する。ステップS8で送信された認証情報を受信したサーバ装置13は、認証処理を行って応答としてその結果を返すので、認証成否の判断は、この応答の内容を参照して行うことができる。なお、所定期間内に応答がなかった場合には、認証失敗として取り扱うようにするとよい。
図4に示す例では、サーバ装置13はレスポンスR8において、認証成功を示すリプライコード「235 Ok」を返している。
【0032】
ステップS9で認証成功(認証OK)と判断すると、電子メールを送信してもよいものとしてステップS10に進み、通常の電子メール送信処理を行って処理を終了する。
なお、ステップS10の電子メール送信処理は、図4にリクエストR9として示すように、電子メールの送信元であるWS11のユーザのアドレス「Mail From:<ws11@abc.co.jp>」をサーバ装置13へ送信したり、電子メールの件名や本文や添付ファイルなどをサーバ装置13へ送信したりする処理である。これらの電子メール送信処理は本発明に特有のものではないため、詳細な説明は省略する。
【0033】
なお、ステップS9で認証失敗(認証NG)であった場合にはステップS11へ進み、エラー処理を行って終了する。この処理としては、例えばWS11のディスプレイに「認証が失敗しました」、「パスワードが違います」等のエラーメッセージを表示してエラーを通知することが考えられる。
また、図3のステップS4でサーバ装置13が認証処理に対応していなかった場合、およびステップS5で適当な認証方式がなかった場合は、認証処理を行うことができないので、認証処理を行わないものとしてそのままステップS10に進み、電子メール送信処理を行った後に処理を終了する。
【0034】
さらに、ステップS3でサーバ装置13がESMTPモードに対応していなかった場合も、認証処理を行うことができないので、認証処理を行わないものとしてステップS12に進み、サーバ装置13にSMTPモードへの移行を要求する。
サーバ装置13は、ESMTPモードに対応していなかった場合には、図6に示すように、WS11からのESMTPモードへの移行を要求するリクエストR3に対して、レスポンスR10のようなエラー応答を返す。
このような場合には、図示は省略したが、サーバ装置13に「HELO」コマンドを送り、SMTPモードへの移行をSMTPサーバに要求するのである。
【0035】
次のステップS13では、サーバ装置13がSMTPモードに対応しているか否か判断する。サーバ装置13は、ステップS12で送信した要求に対し、SMTPモードに対応しているか否かによって異なる応答を返すので、受け取った応答を基にこの判断を行うことができる。
サーバ装置13がSMTPモードに対応している場合はステップS10に進み、通常の電子メール送信処理を行って処理を終了する。一方、サーバ装置13がSMTPモードに対応していない場合にはステップS14へ進み、エラー処理を行って処理を終了する。この処理としては、例えばWS11のディスプレイに「接続したサーバは電子メールの送信に対応していません」等のエラーメッセージを表示してエラーを通知することが考えられる。
【0036】
なお、図示は省略するが、ステップS7でSMTPサーバに認証処理を要求したときにSMTPサーバからエラー応答が返った場合は、ステップS8およびステップS9の処理を行わないでステップS10に進み、通常の電子メール送信処理を行って処理を終了するとよい。
または、上記の場合に、他にも選択可能な認証方式がある場合は、その認証方式を選択して再度サーバ装置13に指定するようにしてもよい。
【0037】
以上の処理において、ステップS5,S6においてはWS11のCPUが認証方式選択手段として機能し、ステップS7,S8においては同じCPUが認証要求手段として機能する。
そして、以上のような処理を行うことにより、WS11およびサーバ装置13の双方が対応している認証方式を自動的に選択して、その認証方式による認証処理を行うことができるので、予めユーザがこれらの情報を調査したり設定したりしなくても、サーバ装置に応じた適切な認証方式で認証を行うことができる。
【0038】
≪第2の動作例:サーバ装置13がPOP3サーバとして機能する場合≫
次に、WS11のユーザが、POP3(Post Office Protocol version 3)サーバとして機能するサーバ装置13を介して電子メールを受信(ダウンロード)する場合の動作について、図8,9に示す通信シーケンスを参照しながら、図7のフローチャートに沿って具体的に説明する。
図8はサーバ装置が暗号化認証方式による認証処理(以下、単に「暗号化認証処理」と云う)に対応している場合の通信シーケンスの一例を示す図であり、図9はサーバ装置が暗号化認証処理に対応していない場合の通信シーケンスの一例を示す図である。これらの通信シーケンスにおいて、実線の矢印はWS11からサーバ装置13へ送信するリクエストを示し、破線の矢印はサーバ装置13からWS11へ返信するレスポンスを示す。
【0039】
WS11のCPUは、定期的にまたはユーザの指示があったときに、図7のフローチャートに示す処理を行ってサーバ装置13のメールボックスにそのユーザ宛に着信した電子メールが格納されているかどうかを調査する。
この処理を開始すると、まずステップS21でサーバ装置13とTCPポート110(この「110」はTCP/IPの規格であり、本明細書の符号ではない)で通信の接続を行う。この通信の接続は、図8,9に示すようにサーバ装置13に接続を要求するリクエストR11を送信することによって行う。なお、サーバ装置13は接続要求を受け付けると応答を返すが、その応答内容はサーバ装置13が暗号化認証処理に対応している場合と対応していない場合とでは異なる。
【0040】
例えば図8に示す例では、サーバ装置13はレスポンスR12として、接続応答を示すリプライコード「+OK」と共にチャレンジ文字列を返している。このチャレンジ文字列は、チャレンジアンドレスポンス方式で暗号化認証処理を行うときに使用するOTP(ワンタイムパスワード)である。
一方、図9に示す例では、サーバ装置13は暗号化認証処理に対応していないので、レスポンスR12′として、接続応答を示すリプライコード「+OK」のみを返している。
しかし、WS11は、ステップS21で通信が接続されると、サーバ装置13が暗号化認証処理に対応しているか否かに係らず、次のステップS22で自機が対応している暗号化認証方式の中から所定のものを選択する。
【0041】
そして、次のステップS23で、ステップS22で選択した暗号化認証方式による認証処理をサーバ装置13に対して要求し、続くステップS24で、その暗号化認証方式に応じた認証情報をサーバ装置13に送信する。
なお、このステップS23とステップS24は同時に行ってもよい。例えば図8,9に示す例では、リクエストR13として、チャレンジアンドレスポンス方式での認証処理を要求するコマンド「APOP」と共に、認証情報であるユーザIDおよび暗号化文字列をサーバ装置13に送信している。この暗号化文字列は、第1の動作例における暗号化文字列と同様に、チャレンジ文字列にパスワードを加えた文字列を暗号化処理して求めたものである。
【0042】
このとき、サーバ装置13は、要求された暗号化認証処理に対応している場合は認証処理を行い、応答として認証結果をWS11に返す。一方、要求された暗号化認証処理に対応していない場合は認証処理を行わないで、エラー応答をWS11に返す。
例えば図8に示す例では、サーバ装置13は、送信したチャレンジ文字列に受信したユーザIDと対応するパスワードを加えた文字列を暗号化処理して、リクエストR13で受信したものと比較し、それらが一致したときに認証が成功したと判断する。そして、レスポンスR14として認証成功を示す応答「+OK」を返す。また、図9に示す例では、サーバ装置13はレスポンスR16として認証失敗を示す応答「−ERR」を返す。
【0043】
図7の説明に戻ると、ステップS24でサーバ装置13に送信した認証情報に対し、次のステップS25で認証が成功であったか否かを判断する。この認証成否の判断は、サーバ装置13から受け取った上記応答の認証結果を参照して行うことができる。なお、所定期間内に応答がなかったときは、認証失敗として取り扱うようにするとよい。
ステップS25で認証成功(認証OK)と判断すると、通信が許可されたものとしてステップS26に進み、通常の電子メール受信処理を行って処理を終了する。なお、ステップS26の電子メール受信処理は、図8,図9のリクエストR15に示すように、サーバ装置13にコマンド「STAT」を送信して、サーバ装置13のメールボックスなどに格納されたWS11のユーザ宛の電子メールの数とサイズを調査したり、その電子メールを受信したりする処理である。これらの電子メール受信処理は本発明に特有のものではないため、詳細な説明は省略する。
【0044】
一方、ステップS25で認証失敗(認証NG)と判断した場合はステップS27へ進み、サーバ装置13に平文認証方式での認証処理(以下、単に「平文認証処理」と云う)を要求し、認証情報を送信する。例えば図9に示す例では、リクエストR17としてユーザIDを指定するコマンド「USER」と共にユーザIDを送信し、それに対するレスポンスR18でサーバ装置13からユーザIDを認識したことを示す応答「+OK」を受け取ると、次にリクエストR19として平文認証方式で認証情報を送信するコマンド「PASS」と共にパスワードを送信する。
このとき、サーバ装置13は、リクエストR17で受信したユーザIDに対応するパスワードとリクエストR19で受信したパスワードとを比較し、それらが一致した場合に認証成功と判断する。そして、レスポンスR20として認証成功を示す応答「+OK」を返す。なお、一致しない場合には認証失敗と判断して、認証失敗を示す応答「−ERR」を返す。
【0045】
そして、次のステップS28では、平文認証処理が成功であったか否かを判断する。この認証成否の判断は、サーバ装置13から受け取った上記応答の認証結果を参照して行うことができる。なお、所定期間内に応答がなかったときは、認証失敗として取り扱うようにするとよい。
ステップS28で認証成功(認証OK)と判断すると、通信が許可されたものとして前述のステップS26へ進み、電子メール受信処理を行って処理を終了する。
一方、ステップS28で認証失敗(認証NG)と判断した場合はステップS29へ進み、エラー処理を行って終了する。この処理としては、例えばWS11のディスプレイに「認証が失敗しました」、「パスワードが違います」等のエラーメッセージを表示してエラーを通知することが考えられる。
【0046】
以上の処理において、ステップS22,S27においてはWS11のCPUが認証方式選択手段として機能し、ステップS23,S24,S27においては同じCPUが認証要求手段として機能する。
なお、前述した第1の動作例では、サーバ装置13が対応している認証方式の中からWS11にも対応しているものを自動的に選択し、その認証方式による認証処理を行ったが、この第2の動作例では、サーバ装置13が暗号化認証処理に対応しているか否かに係らず、暗号化認証方式での認証処理を試みるようにしている。しかし、サーバ装置13の暗号化認証方式への対応の有無を、この認証処理の応答によって判断し、暗号化認証方式に対応していない場合は、自動的に平文認証方式による認証処理を行うようにしている。
【0047】
従って、第1の動作例と同様、予めユーザが認証方式を調査したり設定したりしなくても、サーバ装置に応じた適切な認証方式で認証を行うことができる。
なお、WS11が対応している暗号化認証方式が複数ある場合は、ステップS25で認証失敗(認証NG)を判断したときに、ステップS27に進む代りにステップS22に戻って別の暗号化認証方式を選択し、再度ステップS23からステップS25までの処理を行うようにしてもよい。
このようにして、ステップS25で認証成功(認証OK)を判断するまで、WS11が対応している全ての暗号化認証方式での認証処理を試みるようにすると、暗号化認証処理を行う確率が高くなるため、通信の安全性が向上する。
【0048】
または、ステップS21で送信した接続要求に対して、サーバ装置13は前述したように暗号化認証処理に対応している場合と対応していない場合とで異なる応答を返すので、受け取ったその応答を基にして暗号化認証処理を行うかどうかを判断する処理を、ステップS21とステップS22の間で行うようにしてもよい。例えば、図8および図9に示した通信シーケンスの場合には、レスポンスR12における「+OK」の後の<>で囲まれたチャレンジ文字列の有無によって判断することができる。なお、この処理で暗号化認証処理を行うと判断した場合はステップS22に進み、平文認証処理を行うと判断した場合はステップS27に進むとよい。
さらに、POP3サーバとして機能するサーバ装置13が前述したAUTHコマンドが使用できる場合には、第1の動作例と同様にして認証を行い、電子メールの受信処理を行うこともできる。
【0049】
≪第3の動作例:サーバ装置13がIMAP4サーバとして機能する場合≫
次に、WS11のユーザが、IMAP4(Internet Mail Access Protocol version 4)サーバとして機能するサーバ装置13を介して電子メールを受信する場合の動作について、図11,12に示す通信シーケンスを参照しながら、図10のフローチャートに沿って具体的に説明する。
図11はサーバ装置が暗号化認証処理に対応している場合の通信シーケンスの一例を示す図であり、図12はサーバ装置が暗号化認証処理に対応していない場合の通信シーケンスの一例を示す図である。これらの通信シーケンスにおいて、実線の矢印および破線の矢印は、前述した通信シーケンスの場合と同様であり、それぞれリクエストおよびレスポンスを示す。
【0050】
また、図11および図12の通信シーケンスでは、各々のリクエストおよびレスポンスの先頭に「タグ」,「*」,「+」のいずれかが付けられている。これらはいずれもIMAP4のフォーマットで定められたタグであり、リクエストとレスポンスとの関係を明示するためのものである。なお、タグは本発明の特徴に係るものではないので、個々の詳細な説明は省略する。
さて、WS11は、第2の動作例と同様、定期的にまたはユーザの指示があったときに、図10のフローチャートに示す電子メールの受信処理を開始する。
そして、まずステップS31でサーバ装置13にTCPポート143(この「143」はTCP/IPの規格であり、本明細書の符号ではない)で通信の接続を行う。この通信の接続は、図11,図12に示すようにサーバ装置13に接続を要求するリクエストR21を送信することによって行う。なお、サーバ装置13は、接続要求を受け付けると接続応答を示すレスポンスR22を返す。
【0051】
ステップS31で通信が接続されると、次のステップS32でサーバ装置13の機能一覧の送信を要求する。この要求は、例えば図11,図12のリクエストR23に示すように、サーバ装置13に対し、使用可能な拡張コマンドや対応している認証方式の一覧送信を命令するコマンド「CAPABILITY」を送信することによって行う。
【0052】
このとき、サーバ装置13はこの要求に対する応答として、機能の一覧と、送信処理が正常終了(表示OK)したことを示すコマンド「Ok」とをWS11に返信する。例えば図11に示す例では、レスポンスR24として「imap4 auth=CRAM−MD5」と「Ok」を返している。このうち「imap4auth=」はサーバ装置13が暗号化認証方式での認証処理(暗号化認証処理)に対応している旨を示すコマンドであり、引数には対応している暗号化認証処理の一覧を表示している。つまり、ここでは「CRAM−MD5」に対応していることを示している。
なお、この送信処理が異常終了(表示NG)した場合は、図示しないが、サーバ装置13は応答としてコマンド「Bad」のみを返信する。
また、サーバ装置13に何ら拡張機能がない場合は、図12に示すレスポンスR24′のように応答として「Ok」のみを返信する。この場合、サーバ装置13が対応している暗号化認証処理がないことを示している。
【0053】
図10の説明に戻ると、次のステップS33では、サーバ装置13からの応答を正常に受信できたか否かを判断する。このステップS33の判断がNOであった場合にはステップS44へ進み、エラー処理を行って終了する。この処理としては、例えばWS11のディスプレイにエラーメッセージを表示してエラーを通知することが考えられる。
一方、ステップS33の判断がYESであった場合には、次のステップS34に進み、サーバ装置13が暗号化認証処理に対応しているか否か判断する。この判断は、上記のレスポンスにおける、暗号化認証処理に対応している旨を示す応答の有無によって行うことができる。
【0054】
ステップS34でサーバ装置13が暗号化認証処理に対応していると判断した場合はステップS35に進み、サーバ装置13が対応している暗号化認証方式の中に自機も対応しているものがあるか否か判断する。この判断は、上記のレスポンスにおける、「imap4 auth=」の引数によって判断することができる。例えばレスポンスR24の場合には、サーバ装置13が「CRAM−MD5」に対応していることが分かるので、自機がこれに対応しているか否かをもとに判断すればよい。
【0055】
ステップS35の判断がYESであればステップS36に進み、サーバ装置13と自機の双方が対応している認証方式を、使用する暗号化認証方式として選択する。この時複数の候補があれば、その中から適当な1つを選択する。この場合の選択基準としては、例えばユーザの定めた優先順位に従うなどが考えられる。そして、次のステップS37で、ステップS36で選択した認証方式による暗号化認証処理を、サーバ装置13に対して要求する。図11に示す例では、「AUTENTICATE CRAM−MD5」がこの要求に相当し、CRAM−MD5方式による認証処理を要求する旨の要求である。
【0056】
次のステップS38では、ステップS37で要求した認証方式に応じた認証情報をサーバ装置13に送信する。例えば図11に示す例では、CRAM−MD5方式による認証処理を要求するリクエストR25を受信したサーバ装置13が、レスポンスR26としてチャレンジ文字列を返すので、WS11は、そのチャレンジ文字列を用いて、第1の動作例の場合と同様にして求めた暗号化文字列を認証情報としてリクエストR27としてサーバ装置13に送信する。このときサーバ装置13は、受け取った暗号化文字列から、第1の動作例の場合と同様にしてクライアント装置11が用いたパスワードが正しいものであるか否かを判断する。
【0057】
ステップS38の後は、ステップS39に進み、暗号化認証処理が成功(認証OK)であったか否かを判断する。ステップS38で送信された認証情報を受信したサーバ装置13は、暗号化認証処理を行って応答としてその結果を返すので、暗号化認証成否の判断は、この応答内容を参照して行うことができる。なお、所定期間内に応答がなかった場合には、暗号化認証失敗として取り扱うようにするとよい。図11に示す例では、サーバ装置13はレスポンスR28において、認証成功を示すリプライコード「Ok」を返している。
ステップS39で認証成功(認証OK)と判断するとステップS40に進み、図7に示したステップS26と同様の通常の電子メール受信処理を行って処理を終了する。
【0058】
一方、ステップS34でサーバ装置13が暗号化認証処理に対応していないと判断した場合や、ステップS35でサーバ装置13が対応する暗号化認証方式の中に自機も対応しているものがないと判断した場合にはステップS41へ進み、平文認証方式での認証処理をサーバ装置13に要求する。例えば図12に示す例では、リクエストR29でログインを要求するコマンド「LOGIN」の引数にユーザIDとパスワードを平文のままサーバ装置13に送信することにより、平文認証方式での認証処理をサーバ装置13に要求している。このときサーバ装置13は、リクエストR29で受け取ったユーザIDとパスワードから、第1の動作例の場合と同様にしてクライアント装置11が用いたパスワードが正しいものであるか否かを判断することができる。図12に示す例では、サーバ装置13はレスポンスR30において、認証成功を示すリプライコード「Ok」を返している。
【0059】
そして、ステップS41の後はステップS42に進み、平文認証処理が成功であったか否か判断する。ステップS41で送信された認証情報を受信したサーバ装置13は、平文認証処理を行って応答としてその結果を返すので、その内容を参照して認証成否の判断をすることができる。なお、所定期間内に応答がなかった場合には、認証失敗として取り扱うようにするとよい。
ステップS42で認証成功(認証OK)と判断するとステップS40に進み、通常の電子メール送信処理を行って処理を終了する。
一方、ステップS42で認証失敗(認証NG)であった場合にはステップS43へ進み、第1の動作例の場合と同様にしてエラー処理を行って終了する。
【0060】
ステップS39で認証失敗(認証NG)であった場合も、ステップS41に進んで上記と同様の処理を行う。
以上の処理において、ステップS35,S36,S41においてはWS11のCPUが認証方式選択手段として機能し、ステップS37,S38,S41においては同じCPUが認証要求手段として機能する。
【0061】
そして、以上のような処理を行うことにより、WS11およびサーバ装置13の双方が対応している暗号化認証方式を自動的に選択して、その暗号化認証方式による認証処理を行うことができるので、予めユーザがこれらの情報を調査したり設定したりしなくても、サーバ装置に応じた適切な認証方式で認証を行うことができる。また、WS11およびサーバ装置13の双方が対応している暗号化認証方式がない場合は自動的に平文認証方式で認証を行うので、これらの装置の対応する暗号化認証方式の違いによって電子メールが受信できなくなることが無い。
【0062】
<第2の実施形態>
次に、この発明の通信装置の第2の実施形態である、図2に示したスキャナ12について詳細に説明する。このスキャナ12は、ネットワークを介して外部装置との間で画像情報を送受信する画像情報通信手段を備えた通信装置である。
まず、図13の機能ブロック図に、このスキャナの機能構成を示す。なお、この図においては、この発明に関連する部分の機能のみを示している。また、図13において図1と同様な部分には同一符号を付してその説明を省略する。
このスキャナ12は、一般的なスキャナの機能部であるスキャナ部31,プロッタ部32,操作部33,表示部34,時計回路部35の他に、CPU,ROM,RAM,HDD,通信インタフェース(I/F)等も備え、さらに一般的なFAX機能部であるFAX部20も備える。これらは全て公知のハードウェアを用いて構成することができる。
【0063】
そして、CPUは、ROMやHDDに記憶している種々の制御プログラムを実行することにより、スキャナ12全体を統括制御する制御部16′として機能する。また、記憶部17′の機能は、ROM,RAM,HDD等の記憶手段によって実現される。
制御部16′は、前述した認証方式選択部25および認証要求部26の機能の他にも、符号化/復号化部27および画像情報通信部28の機能を有する。
符号化/復号化部27は、データ圧縮等の符号化を行ったり、逆に符号化された画像データを復号化して元の状態に戻したりする。また、画像情報通信部28は通信I/F18を制御し、ネットワークを介してサーバ装置13との間で画像情報(画像データ)を送受信して、画像情報通信手段の機能を果たす。
【0064】
記憶部17′は、OS等の基本ソフトウェアを格納するシステムメモリ36と、設定値などの変数を一時的に格納するパラメータメモリ37と、画像データを格納する画像蓄積部38との機能を有する。
また、スキャナ部31は、シート上の画像を読み取ってデジタルの画像データに変換するユニットである。
プロッタ部32は、画像データに基づいてシート上に画像を形成するユニットである。また、操作部33は、ユーザが動作設定を行ったり電子メールなどを作成したりするためのものである。
表示部34は、スキャナ12の設定状態、動作状況、画像データ、ヘルプ情報などを表示するためのものである。時計回路部35は時計機能を有し、時間を計測する。
【0065】
一方、FAX部20は、G3FAXモデム40および網制御部39を有し、一般的なFAX通信の機能を有する。
このFAX部20をスキャナ12に設けた場合、ネットワーク1を介して受信した画像データをプロッタ部32で印刷することなく、そのままFAX送信することができる。しかし、FAX機能は本発明に必須のものではないので、FAX部20は設けなくてもよい。
また、プロッタ部32,表示部34,時計回路部35も設けなくてもよい。
以下、このスキャナ12がサーバ装置13に対して通信を要求する場合の動作について、例を挙げて説明する。なお、以下の動作例において、スキャナ12の記憶部17′にはユーザが予め登録したユーザIDおよびパスワードと、サーバ装置のアドレス(図2に示した“msrv13.abc.co.jp”)とが格納されているものとする。
【0066】
スキャナ12がSMTPサーバとして機能するサーバ装置13を介して、図2に示したネットワーク2に接続したワークステーション21のユーザに画像データを添付した電子メールを送信する場合、ユーザは、まず記憶部17′の画像蓄積部38から送りたい画像データを選択するか、または送りたい画像が形成されたシートをスキャナ部31にセットして操作部33を操作し、シート上の画像を画像データに変換する。
そして、メールソフトウェアなどを用いてWS21のユーザ宛の電子メールを作成すると共に、メールヘッダのTOフィールドにWS21のアドレス(図2に示した“msrv23.xyz.co.jp”)を電子メールの送信先として指定し、さらに上記選択した画像データまたは変換した画像データを添付して送信を指示する。すると、スキャナ12のCPUは、第1の実施形態で説明したWS11の場合と同様に、図3のフローチャートに示したステップS1〜S14と同様な処理を行って電子メールを送信する。
【0067】
一方、スキャナ12がPOP3サーバとして機能するサーバ装置13のメールボックスから画像データが添付された電子メールを受信する場合も、スキャナ12のCPUは、WS11の場合と同様に、図7のフローチャートに示したステップS21〜S29と同じ処理を行う。
また、スキャナ12がIMAP4サーバとして機能するサーバ装置13のメールボックスから画像データが添付された電子メールを受信する場合には、同様に図10のフローチャートに示したステップS31〜S44と同じ処理を行う。
なお、これらの処理におけるスキャナ12とサーバ装置13との通信シーケンス例は、それぞれ図4〜図6、図8、図9、図11、図12に示した通信シーケンスの「WS11」を「スキャナ12」に代えたものとなる。
【0068】
従って、第2の実施形態においても第1の実施形態と同様に、スキャナ12(通信装置)およびサーバ装置13(外部装置)の双方が対応している認証方式を自動的に選択して、その認証方式による認証処理を行うことができるので、予めユーザがこれらの情報を調査したり設定したりしなくても、サーバ装置に応じた適切な認証方式で認証を行うことができる。
なお、第2の実施形態では通信装置がスキャナである場合について説明したがそれに限るものではなく、ネットワークに接続して通信可能な他の通信装置(例えばFAX装置やネットワークプリンタ等)であってもよい。
【0069】
<第3の実施形態>
続いて、この発明の通信装置の第3の実施形態について説明する。この実施形態もスキャナであり、第2の実施形態のスキャナにおいて、認証方式を自動的に選択する場合の選択範囲を、認証情報を暗号化して送信する暗号化認証方式および/または認証情報を平文で送信する平文認証方式に制限する指示を受け付けるようにしたものである。その他の点は第2の実施形態のスキャナと同様であるので、説明を省略する。
【0070】
このスキャナにおいて、認証情報の選択範囲の設定指示は、所定のアプリケーションプログラムなどを用いて予め受け付けておくことができ、この処理においてスキャナ12のCPUが選択指示受付手段として機能する。
そして、その受け付けた指示に従い、同CPUが認証方式選択手段として機能する場合の選択方式を、暗号化認証方式の中から外部装置に応じたものを自動的に選択する第1のモード、平文認証方式の中から外部装置に応じたものを自動的に選択する第2のモード、暗号化認証方式および平文認証方式の中から外部装置に応じたものを自動的に選択する第3のモードのいずれかに設定するようにしている。
以下、このスキャナの動作例について説明する。
【0071】
≪第4の動作例:サーバ装置13がSMTPサーバとして機能する場合≫
図14は、このスキャナがSMTPサーバとして機能するサーバ装置と認証を行って電子メールを送信する場合の処理を示すフローチャートである。なお、図14において、図3と同様な部分には同一符号を付してその説明を省略する。
スキャナ12のユーザが画像データを添付した電子メールの送信を指示すると、スキャナ12のCPUは図14のフローチャートに示す処理を開始する。そして、ステップS1〜S3では、図3に示したステップS1〜S3と同様の処理を行い、サーバ装置13をESMTPモードに移行させることを試みる。また、ステップS3でサーバ装置13がESMTPモードに対応していない場合はステップS12へ進み、ステップS12〜S14では、図3に示したステップS12〜S14と同様の処理を行い、サーバ装置13をSMTPモードに移行させることを試みる。
【0072】
一方、ステップS3でサーバ装置がESMTPモードに対応している場合はステップS4に進み、図3に示したステップS4と同様、サーバ装置13が認証処理に対応しているかどうか判断する。
ステップS4で対応していない場合は、そのままステップS56へ進み、図3に示したステップS10と同じ通常の電子メール送信処理を行って処理を終了する。この場合、認証は行わない。
ステップS4で対応している場合は、ステップS50に進み、認証方式の選択方式の設定が、第3のモード(暗号化認証方式と平文認証方式の両方から特に制限なく自由に選択するモード)になっているか否かを判断する。
【0073】
ステップS50の判断がYESの場合にはステップS51へ進み、図3に示したステップS5の場合と同様に、サーバ装置13が対応している暗号化認証方式の中に自機も対応しているものがあるか否か判断する。
さらに、ステップS51の判断がYESの場合にはステップS52へ進み、サーバ装置13とスキャナ12の双方が共に対応している暗号化認証方式の中から適当なものを選択する。次のステップS53では、ステップS52で選択した認証方式での認証処理をサーバ装置13に要求し、続くステップS54では、ステップS52で選択した暗号化認証方式に応じた認証情報をサーバ装置13に送信する。なお、これらの詳細な説明は第1の動作例のステップS6〜S9と同様であるので、ここでは省略する。
【0074】
そして、次のステップS55では認証成功(認証OK)か否かを判断する。ステップS55で認証OKと判断した場合はステップS56に進み、通常の電子メール送信処理を行って処理を終了する。また、ステップS55で認証NGと判断した場合はステップS57に進み、図3のステップS11の場合と同様なエラー処理を行って終了する。
ところで、ステップS51で適当な暗号化認証方式がなかった場合はステップS58に進む。ステップS58では、サーバ装置13と自機(スキャナ12)の双方が対応している平文認証方式があるかどうか判断する。この判断は、対象が暗号化認証方式か平文認証方式かの差はあるが、概ね図3に示したステップS5の場合と同様にして行うことができる。
【0075】
ステップS58の判断がNOの場合は、双方が対応している認証方式がないことになるので、そのままステップS56に進み、認証処理を行うことなく通常の電子メール送信処理を行って終了する。一方、ステップS58の判断がYESの場合はステップS59へ進み、サーバ装置13とスキャナ12の双方が共に対応している平文認証方式の中で適当なものを選択する。そして、次のステップS60では、ステップS59で選択した平文認証方式での認証処理をサーバ装置13に要求し、続くステップS61ではその平文認証方式に応じた認証情報をサーバ装置に送信する。
ステップS61の後はステップS55に進み、以下、ステップS55〜S57で前述した処理と同様の処理を行う。
【0076】
また、ステップS50で設定が第3のモードでない場合は、ステップS62に進む。ステップS62では、選択方式の設定が第1のモード(暗号化認証方式の中から選択するモード)であるか否かを判断する。
そして、第1のモードである場合はステップS63へ進み、ステップS51の場合と同様に、サーバ装置13が対応している暗号化認証方式の中に自機も対応しているものがあるかどうか判断する。
ステップS63の判断がYESである場合はステップS52へ進み、以下、ステップS51の判断がYESであった場合と同様に、暗号化認証方式を選択し、その方式で認証処理を行って、成功した場合に電子メールを送信して終了する。
【0077】
さらに、ステップS62で第1のモードでない場合、つまり選択方式の設定が第2のモード(平文認証方式の中から選択するモード)である場合はステップS64へ進み、ステップS58の場合と同様に、サーバ装置13とスキャナ12の双方が共に対応している平文認証方式があるかどうか判断する。
ステップS64の判断がYESである場合はステップS59へ進み、以下、ステップS58の判断がYESであった場合と同様に、平文認証方式を選択し、その方式で認証処理を行って、成功した場合に電子メールを送信して終了する。
一方、ステップS64の判断がNOである場合はそのままステップS56へ進み、通常の電子メール送信処理を行って処理を終了する。
【0078】
なお、図14のフローチャートでは、ステップS4でサーバ装置13が認証処理に対応していない場合、ステップS58,S63,S64でそれぞれ適当な認証方式がなかった場合に、認証処理を行うことなくステップS56へ進んで通常の電子メール送信処理を行うようにしている。
このようにした場合、サーバ装置13とスキャナ12との認証方式の違いにより電子メールの送信がエラーになってしまう確率を低くすることができる。
【0079】
≪第5の動作例:サーバ装置13がPOP3サーバとして機能する場合≫
図15は、この第3の実施形態のスキャナが、POP3サーバとして機能するサーバ装置と認証を行って電子メールを受信する場合の処理を示すフローチャートである。なお、図15において、図7と同様な部分には同一の符号を付してその説明を省略する。
スキャナ12のCPUは、定期的にまたはスキャナ12のユーザが電子メールの受信を指示したときに図15のフローチャートに示した処理を開始する。そして、ステップS21では、図7に示したステップS21の場合と同様な通信の接続処理を行う。
【0080】
次のステップS70では、認証方式の選択方式の設定が第3のモードになっているか否かを判断する。
ステップS70で設定が第3のモードの場合は、ステップS71〜S73へ進み、図7に示したステップS22〜S24の場合と同様に、暗号化認証方式を選択し、その方式での認証処理をサーバ装置13に要求し、認証情報を送信する。そして、次のステップS74では、認証成功(認証OK)か否かを判断する。ステップS74で認証OKの場合は、ステップS75に進み、図7に示したステップS25の場合と同様に通常の電子メール受信処理を行って終了する。
ステップS74で認証NGの場合は、ステップS76〜S78に進み、平文認証方式を選択し、図7のステップS27の場合と同様に、その方式での認証処理をサーバ装置13に要求し、認証情報を送信する。
【0081】
そして、次のステップS79で認証成功(認証OK)か否かを判断する。ステップS79で認証OKの場合は、ステップS75へ進んで通常の電子メール受信処理を行って終了し、認証NGの場合は、ステップS80へ進んで図3のステップS11の場合と同様にエラー処理を行って終了する。
一方、ステップS70で設定が第3のモードでない場合は、ステップS81に進み、設定が第1のモードであるか否かを判断する。
ステップS81の判断がNOの場合、つまり設定が第2のモードの場合はステップS76に進み、以下、ステップS74の判断がNOである場合と同様の処理を行う。
【0082】
ステップS81の判断がYESの場合は、ステップS82〜S84へ進み、ステップS71〜S73と同様な処理を行う。そして、次のステップS85で認証OKか否かを判断し、その判断がYESの場合はステップS75の処理を行って終了する。また、ステップS85の判断がNOの場合は、ステップS86に進み、ステップS80の場合と同様なエラー処理を行って終了する。
以上、POP3サーバとして機能するサーバ装置から電子メールを受信する場合について説明したが、そのサーバ装置13の拡張機能としてAUTHコマンドが使用できる場合は、第4の動作例と同様にして認証を行い、電子メールを受信することもできる。
【0083】
≪第6の動作例:サーバ装置13がIMAP4サーバとして機能する場合≫
図16は、この第3の実施形態のスキャナが、IMAP4サーバとして機能するサーバ装置と認証を行って電子メールを受信する場合の処理を示すフローチャートである。なお、図16において、図10と同様な部分には同一符号を付してその説明を省略する。
スキャナ12のCPUは、定期的にまたはスキャナ12のユーザが電子メールの受信を指示したときに図16のフローチャートに示した処理を開始する。そして、ステップS31では、図10に示したステップS31と同様の通信の接続処理を行う。
【0084】
そして次のステップS90では、認証方式の選択方式の設定が第2のモードになっているか否かを判断する。
ステップS90で設定が第2のモードの場合は、ステップS91〜S93へ進み、平文認証方式を選択し、図10に示したステップS41の場合と同様に、その方式での認証処理をサーバ装置13に要求して認証情報を送信する。
そして、次のステップS94では認証成功(認証OK)か否かを判断し、YESの場合はステップS95に進んで前述と同様の通常の電子メール受信処理を行って終了し、NOの場合はステップS111に進んでエラー処理を行って終了する。
【0085】
一方、ステップS90で設定が第2のモードではない場合は、ステップS96へ進み、図10に示したステップS32の場合と同様にサーバ装置13に機能一覧の送信を要求する。そして、次のステップS97では機能一覧を正常に受信したか否かを判断し、その判断がNOの場合は、ステップS111のエラー処理を行って終了する。
ステップS97の判断がYESの場合は、ステップS98へ進み、設定が第3のモードであるか否かを判断する。
【0086】
ステップS98で第3のモードである場合は、ステップS99〜S104に進み、それぞれ図10に示したステップS34〜S39の場合と同様に暗号化認証方式を選択し、その方式での認証処理をサーバ装置13に要求して認証情報を送信する。なお、ステップS99,S100,S104のいずれかの処理でNOと判断した場合は、ステップS91へ進み、以下、ステップS90の判断がYESである場合と同様の処理を行う。また、ステップS104の判断がYESである場合は、ステップS95の通常の電子メール受信処理を行って処理を終了する。すなわち、第3のモードの場合には、暗号化認証方式と平文認証方式の双方の中から、自機とサーバ装置とが共に対応している方式を選択し、認証を要求する。
【0087】
一方、ステップS97で設定が第3のモードでない場合、つまり設定が第1のモードである場合はステップS105に進む。以下、ステップS105〜S110では、前述した第3のモードの場合のステップS99〜S104と概ね同様の処理を行う。なお、第1のモードでは暗号化認証方式のみから選択するため、この中に適当な方式がなく、ステップS105,S106,S110のいずれかの処理でNOと判断した場合は、ステップS111に進み、エラー処理を行って終了する点が前述した第3のモードの場合と異なる。
【0088】
以上、通信装置が自動的に選択する認証方式の範囲を、暗号化認証方式および/または平文認証方式に制限する指示を受け付けるようにし、認証方式を選択する場合の選択方式を、暗号化認証方式に制限する第1のモードか、平文認証方式に制限する第2のモードか、特に制限しないで暗号化認証方式および平文認証方式の両方から自由に選択できる第3のモードかのいずれかに設定できるようにしているため、ユーザが特に暗号化認証方式での認証または平文認証方式での認証を望む場合に、通信装置およびその通信装置と通信する外部装置に適した認証方式の中から、ユーザの要望に沿った認証方式を自動的に選択することができる。さらに、認証でエラーが発生した場合には、ユーザは明示的に結果を知ることができ、対処しやすくなる。
【0089】
また、通信装置と外部装置との双方が対応している暗号化認証方式があることが予め判っている場合に第1のモードに設定したり、そのような暗号化認証方式がないことが予め判っている場合に第2のモードに設定したりすれば、CPUが無駄な処理を行わないので、CPUの負担を低減でき、処理速度を早くすることができる。
【0090】
<第1〜第3の実施形態の変形例>
続いて、上述した各実施形態の変形例について説明する。
この変形例は、認証要求動作の有効/無効を所定のアプリケーションプログラムなどを用いて予め設定しておくことができるようにしたものである。
以下、変形例を上述した第4の動作例に適用した処理について説明する。
図17に、この処理のフローを示す。なお、図17において、図3あるいは図14と同じ部分には同一符号を付してその説明を省略する。
スキャナ12のユーザが電子メールの送信を指示すると、スキャナ12のCPUは図17のフローチャートに示す処理を開始する。そして、ステップS1では、図14に示したステップS1と同様の処理を行う。
【0091】
次のステップS120では、CPUの認証要求手段としての動作、すなわち認証要求動作が有効に設定されているか否かを判断する。
ステップS120の判断がNOの場合、つまり認証要求を行わない設定になっている場合はステップS12へ進み、以下のステップS12〜S14では、図3および図14に示したステップS12〜S14と同様の処理を行う。すなわち、SMTPモードへの移行をサーバ装置13に要求し、サーバ装置13がSMTPモードに対応しているかどうかを判断する。そして、対応している場合は通常の電子メール送信処理を行って終了し、対応していない場合はエラー処理を行って終了する。
【0092】
ステップS120の判断がYESの場合はステップS2に進み、以下のステップS2〜S4では、図14に示したステップS2〜S4と概ね同様の処理を行う。なお、ステップS3,S4の処理でNOと判断した場合、図14のフローチャートでは認証要求動作の有効/無効の設定を行わなかったため、それぞれステップS12,S56に進んだ。しかし、この図17のフローチャートでは、ステップS120で認証要求動作の設定が有効であるにもかかわらず、ステップS3,S4の処理でNOと判断した場合は認証を行うことができないので、ステップS57へ進み、エラー処理を行って終了するようにしている。
【0093】
ステップS4の判断でYESの場合はステップS50に進み、以下、ステップS50〜S64では、それぞれ図14に示したステップS50〜S64と概ね同様な処理を行う。なお、ステップS58,S63,S64のいずれかの処理でNOと判断した場合、図14に示したフローチャートでは認証を行わないままステップS56に進み、それぞれ通常の電子メール送信処理を行うようにしていた。しかし、この図17のフローチャートでは、ステップS120で認証要求動作の設定が有効であるにもかかわらず、ステップS58,S63,S64の処理でNOと判断した場合は認証を行うことができないので、それぞれステップS57に進み、エラー処理を行って終了するようにしている。
【0094】
このような処理を行うことにより、認証要求をするか否かを予め設定できるので、予め通信装置または外部装置が認証処理に対応していないとわかっている場合に無効に設定することにより、CPUが無駄な処理を行わず、CPUの負担が低減し、処理速度が速くなる。
また、認証要求動作の有効/無効を設定することで、ユーザは、好みに応じて認証を行うか否かを選択することができる。さらに、認証でエラーが発生した場合には、ユーザは明示的に結果を知ることができ、対処がしやすくなる。
【0095】
ところで、ここでは、ステップS120で無効の場合にステップS12に進み、SMTPモードへの移行を要求するようにしているが、それに限るものではない。例えば、ステップS2,S3と同様にしてESMTPモードへの移行をサーバ装置13に要求し、サーバ装置13がESMTPモードに対応しているか否か判断するようにしてもよい。そして、サーバ装置13が対応していない場合はエラー処理を行って処理を終了し、サーバ装置13が対応している場合はステップS56の通常の電子メール送信処理を行って処理を終了するとよい。
【0096】
また、この変形例は、もちろん他の実施形態や動作例にも適用することができる。例えば、第5の動作例に適用する場合には、図15に示したフローチャートのステップS21の後でステップS120の判断を行い、その判断がYESの場合にステップS70に進み、NOの場合にステップS75に進むようにすればよい。
また、第6の動作に適用する場合には、図16に示したフローチャートのステップS31の後でステップS120の判断を行い、その判断がYESの場合にステップS90に進み、NOの場合にステップS95に進むようにすればよい。
【0097】
次に、上述した各動作例の処理において、選択可能な認証方式が複数ある場合に、その複数の認証方式の中から適当なものを選択する選択基準について説明する。
この選択基準としては、図18に示すような優先順位テーブルを用いることができる。そして、選択の条件に合う認証方式が複数ある場合に、この認証方式の優先順位テーブルの中で優先順位が高いものを優先的に選択するのである。
なお、この優先順位テーブルは、暗号化認証方式を選択の優先順位に従って並べた暗号化認証方式優先順位テーブルと、平文認証方式を選択の優先順位に従って並べた平文認証方式優先順位テーブルとからなり、これらの各優先順位をアプリケーションソフトウェアなどを用いて予め任意に設定し、通信装置の記憶部などに格納しておくことができる。
【0098】
そして、この優先順位テーブルには、通信装置が対応している認証方式のみを記載するものとする。この処理においてCPUは、同CPUが認証方式選択手段として機能する場合の認証方式の選択の優先順位を設定する手段として機能する。
このような優先順位テーブルを用いる場合、例えば図3に示したステップS6では、サーバ装置13が対応している認証方式と優先順位テーブルに含まれる認証方式とを優先順位の高い方から順番に比較し、最初に一致したものを選択するとよい。このとき、先に暗号化認証方式優先順位テーブルと比較し、一致するものがない場合に平文認証方式優先順位テーブルと比較するようにすれば、暗号化認証を行う確率が高くなるので、通信の安全性がより向上する。
【0099】
図18に示す優先順位テーブルを用いる場合には、まずサーバ装置13が対応している認証方式と、暗号化認証方式優先順位テーブルにおける優先順位1位のCRAM−MD5,2位のKERBEROS_V4とを比較し、次に平文認証方式優先順位テーブルにおける1位のLOGIN,2位のPLAINとを比較することになる。
なお、LOGINおよびPLAINは、電子メールに添付される画像などのアプリケーションデータ(バイナリデータ)を文字列(テキストデータ)にエンコードするBASE64を行うが、認証情報は平文のまま送受信するため、本明細書では平文認証方式と位置付ける。
【0100】
また、図7に示したステップS22では、暗号化認証方式優先順位テーブルの中で優先順位が最高位の方式を選択するとよい。さらに、ステップS25で認証NGの場合は、ステップS22に戻って優先順位が次位の方式を選択し、再び認証要求するようにするとよい。このようにして、ステップS25で認証OKになるまで自機が対応する暗号化認証方式の全てについて優先順位の順番で選択するようにすれば、暗号化認証を行う確率が高くなるので、通信の安全性がより向上する。
さらに、ステップS27でも同様にして、平文認証方式優先順位テーブルの中で優先順位が最高位の方式を選択するとよい。この場合も、対象が暗号化認証方式か平文認証方式かの違いがあるが、上記ステップS22の場合と概ね同様にして、ステップS28で認証OKになるまで平文認証方式優先順位テーブルの優先順位が高い方から次々に選択して認証要求するとよい。
【0101】
また、図14,図17のフローチャートに示す処理の場合には、ステップS51でサーバ装置13が対応している認証方式と暗号化認証方式優先順位テーブルに含まれる認証方式とを優先順位の高い方から順番に比較し、一致する方式をステップS52で選択するとよい。このとき一致する方式がなければ、ステップS58でサーバ装置13が対応している認証方式と平文認証方式優先順位テーブルに含まれる認証方式とを同様にして比較し、一致するものをステップS59で選択するとよい。
さらに、ステップS63の処理を行う場合には暗号化認証方式優先順位テーブルを用いて、ステップS64の処理を行う場合には平文認証方式優先順位テーブルを用いて、上記の場合と同様に比較して一致するものを選択するとよい。
【0102】
以上のような処理を行うことにより、ユーザが指示した優先順位で認証処理を選択し、これを実行することができる。なお、優先順位テーブルは、暗号化認証方式優先順位テーブルと平文認証方式優先順位テーブルとを区別せずに順位を付すようにしてもよい。
【0103】
なお、上述した各実施形態において、認証要求に係る認証方式,外部装置による認証結果,エラー情報などをログ領域に一時格納しておき、ユーザが後程シートに印刷などして確認できるようにしてもよい。あるいは、外部装置のログ領域に一時格納しておき、ユーザが後程その外部装置と通信を行って確認できるようにしてもよい。このようにすれば、ユーザが認証結果を知り、装置の動作状況を把握することができる。
【0104】
また、ここでは通信装置がWSやスキャナである場合について説明したが、それに限るものではないのは勿論である。この発明は、通信機能を備えてネットワークに接続可能な通信装置であればどのようなものにも適用できる。例えば、パーソナルコンピュータ等の情報処理装置,携帯電話やPHS等の通信端末装置,プリンタ等の出力装置などの通信装置に本発明を適用することができる。
また、通信装置が通信を行う外部装置も、上述したSTMPサーバ,POP3サーバ,IMAP4サーバとして機能するサーバ装置に限るものではない。例えば、これらのメールサーバと略同じプロトコルで動作する他のメールサーバとして機能するサーバ装置であってもよい。あるいは、ウェブサーバなど、メールサーバ以外のサーバとして機能するサーバ装置であってもよい。さらに、例えば大型コンピュータなど、サーバ装置以外の電子装置であってもよい。
【0105】
さらに、本明細書では、暗号化認証方式としてCRAM−MD5,KERBEROS_V4、平文認証方式としてLOGIN,PLAINをそれぞれ例示したが、本発明に対応している認証方式はこれらに限るものではないのは勿論であり、他の暗号化認証方式および平文認証方式であってもよい。
また、本明細書では、通信装置が認証方式を自動的に選択する場合について説明したがそれに限るものではなく、通信の認証以外の部分(例えば電子メールの本文など)を暗号する暗号化方式についても、同様にして自動的に選択することができる。
【0106】
また、上述したこの発明の通信装置と、その通信相手となる外部装置、例えばサーバ装置とによって通信システムを構成すれば、ユーザが通信装置と外部装置とが対応している暗号方式および認証方式を調査したり設定したりしなくても、適切な暗号方式および認証方式を自動的に選択して認証処理を行うことができるので、ユーザの作業負担が低い、便利な通信システムを実現することができる。
【0107】
【発明の効果】
以上説明してきたように、この発明による通信装置によれば、外部装置と自機が対応している認証方式に応じて適切な認証方式を自動的に選択でき、その認証方式で外部装置に認証処理を要求するので、ユーザが通信装置と外部装置がサポートしている認証方式および暗号方式を調査し、選択して設定する必要が無く、ユーザの負担を軽減することができる。
【図面の簡単な説明】
【図1】この発明による通信装置の第1の実施形態であるWSの機能を示す機能ブロック図である。
【図2】この発明による通信装置が接続するネットワークの構成例を示す図である。
【図3】図1に示したWSがSMTPサーバとして機能するサーバ装置を介して電子メールを送信する場合の処理を示すフローチャートである。
【図4】図3に示す処理において、サーバ装置が認証処理に対応している場合のWSとサーバ装置との間の通信シーケンスの例を示す図である。
【図5】同じく、サーバ装置が認証方式に対応していない場合の例を示す図である。
【図6】同じく、サーバ装置がESMTPモードに対応していない場合の例を示す図である。
【図7】図1に示したWSがPOP3サーバとして機能するサーバ装置を介して電子メールを受信する場合の処理を示すフローチャートである。
【図8】図7に示す処理において、サーバ装置が暗号化認証方式に対応している場合のWSとサーバ装置との間の通信シーケンスの例を示す図である。
【図9】同じく、サーバ装置が暗号化認証方式に対応していない場合の例を示す図である。
【図10】図1に示したWSがIMAP4サーバとして機能するサーバ装置を介して電子メールを受信する場合の処理を示すフローチャートである。
【図11】図10に示す処理において、サーバ装置が暗号化認証方式に対応している場合のWSとサーバ装置との間の通信シーケンスの例を示す図である。
【図12】同じく、サーバ装置が暗号化認証方式に対応していない場合の例を示す図である。
【図13】この発明による通信装置の第2の実施形態であるスキャナの機能を示す機能ブロック図である。
【図14】この発明の第3の実施形態の通信装置が、SMTPサーバとして機能するサーバ装置を介して電子メールを送信する場合の処理を示すフローチャートである。
【図15】同じく、POP3サーバとして機能するサーバ装置を介して電子メールを受信する場合の処理を示すフローチャートである。
【図16】同じく、IMAP4サーバとして機能するサーバ装置を介して電子メールを受信する場合の処理を示すフローチャートである。
【図17】図14に示した処理に変形例を適用した場合の処理を示すフローチャートである。
【図18】認証方式の優先順位テーブルの例を示す図である。
【符号の説明】
1,2:ネットワーク 3:インターネット
4:公衆網 5,6:ルータ装置
11,14,21,24:ワークステーション(WS)
12:スキャナ 13,23:サーバ装置
15,22:FAX装置 16,16′:制御部
17,17′:記憶部
18:通信インタフェース(I/F)
20:FAX部 25:認証方式選択部
26:認証要求部 27:符号化/複合化部
28:画像情報通信部
31:スキャナ部 32:プロッタ部
33:操作部 34:表示部
35:時計回路部 36:システムメモリ
37:パラメータメモリ 38:画像蓄積部
39:網制御部 40:G3FAXモデム
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a communication device such as an information processing device, a communication terminal device, and an output device that can communicate with an external device connected via a network, and particularly has a function of requesting authentication processing by transmitting authentication information to the external device. The present invention relates to a communication device.
[0002]
[Prior art]
In recent years, services and applications provided on the Internet have been widely spread, and various communication devices are connected to each other via a network and actively communicate with each other. Examples of such communication devices include information processing devices such as personal computers (PS) and workstations (WS), and communication terminal devices such as personal digital assistants (PDAs) and mobile phones.
Recently, there is also a communication apparatus that enables communication via the Internet by providing a communication function in an image reading apparatus such as a facsimile machine (FAX) or a scanner, an image forming apparatus such as a printer, a home appliance, or a medical apparatus. Most of these communication apparatuses use standardized TCP / IP (Transfer Control Protocol / Internet Protocol), and can exchange information on the network with each other across different models.
[0003]
By the way, since the Internet is used by an unspecified number of users, there is a high risk of damage caused by so-called “spoofing” in which information is spoofed or falsified by impersonating another person.
Therefore, in communication using the Internet, for example, when a user transmits / receives information to / from an external device using a client device, the user is identified to identify whether or not he / she is an authorized person and has a valid access right. Authentication is performed, and information is encrypted and transmitted / received to ensure the confidentiality of the information.
[0004]
For example, as can be seen in Patent Document 1, highly confidential electronic data stored in a mail server on an internal network when a user accesses the internal network via a gateway from a user terminal on the external network where security is not secured. E-mail that the mail server extracts and duplicates the e-mail when browsing the e-mail, encrypts the body text using the encryption key entered in advance by the user, and then forwards it to the relay server provided on the external network There is a transfer method.
In addition, in this e-mail transfer method, in order to view this e-mail on an external network, it is necessary to be authenticated by a relay server, and it is necessary to decrypt the encrypted e-mail. Confidentiality is kept high.
[0005]
The authentication method includes a method for transmitting and receiving authentication information such as a user ID and a password (referred to as “encrypted authentication method” in this specification) and a method for transmitting and receiving plaintext (in this specification, “ Called plaintext authentication method).
Also, the encryption method is largely divided into a common key encryption (secret key encryption) that uses the same key for encryption and decryption, and a public key encryption (asymmetric encryption) that uses a paired public key and secret key. There are various methods (see Patent Document 2), and the encryption strength and processing speed are different.
For example, common key encryption includes encryption methods such as DES (Data Encryption Standard: Death), RC2 (Ron's Code 2), and RC4.
[0006]
On the other hand, public key cryptography includes cryptographic schemes such as RSA (Rivest Shamir Adleman), elliptic curve cryptography, and El Gamal cryptography.
In addition, hash functions such as MD5 (Massage Digest 5), which detects the presence or absence of tampering during communication by generating a fixed-length pseudo-random number from the original text of the information and comparing it at both ends of the communication path, are also commonly used. Has been.
The user selects an appropriate authentication method and encryption method according to the encryption processing capability of the client device and the external device and the confidentiality of the information to be communicated, and the client device stores it. If it is set using a communication program or the like, it is possible to communicate safely with an authentication method and an encryption method according to one's preference.
[0007]
[Patent Document 1]
JP 11-88410 A
[Patent Document 2]
Japanese Patent Laid-Open No. 11-122238
[0008]
[Problems to be solved by the invention]
However, if the user sets a method other than the authentication method and encryption method supported by both the client device and the external device at this time, there is a problem that normal communication cannot be performed between the client device and the external device. there were.
For example, in SMTP-AUTH (Authentication) in which a user authentication function is added to SMTP (Simple Mail Transfer Protocol), which is a kind of Internet protocol, the client device side can select from a list of authentication methods supported by an SMTP server as an external device. An arbitrary one is selected and specified. At this time, if an authentication method that is not supported by the client device is specified, an error occurs and communication cannot be performed.
[0009]
Therefore, the user investigates both the authentication method and encryption method supported by the client device and the authentication method and encryption method supported by the external device, and both the client device and the external device support it. You need to choose one.
However, since most users are not familiar with the Internet protocol, there is a problem that the investigation and setting of such an authentication method and encryption method become an excessive burden.
[0010]
For example, e-mail software, which is a communication program, has an item for setting whether or not authentication information is transmitted to the SMTP server to be connected. However, the user determines whether the connection destination SMTP server supports SMTP-AUTH. In many cases, I don't even know.
In this case, the user needs to check whether or not the SMTP server to be connected supports authentication, and whether or not authentication is required, and set whether to send authentication information to the SMTP server. Furthermore, when it is set to transmit authentication information, it is necessary to investigate whether there is an encryption method supported by both the client device and the SMTP server.
[0011]
The present invention has been made in view of the above problems, and in a communication device capable of communicating with an external device via a network, an authentication method supported by the own device (client device) and the external device is investigated. It is an object of the present invention to perform authentication by an appropriate authentication method according to an external device without setting.
[0012]
[Means for Solving the Problems]
In order to achieve the above object, the present invention includes a communication unit that communicates with an external device connected via a network, and an authentication request unit that transmits authentication information to the external device and requests authentication processing. In the authentication method supported by the communication device. The storage means is divided into the encryption authentication method and the plaintext authentication method. Refer to the authentication method information that the external device supports, which is stored and transmitted in response to a request from the communication device, First, the encryption authentication method stored in the storage unit and the authentication method supported by the external device are sequentially compared, and if there is no match, the plaintext authentication stored in the storage unit By comparing the method and the authentication method supported by the external device in order, and selecting the first matching authentication method in these comparisons, An authentication method selection means for selecting one of the authentication methods supported by both the external device and the communication device is provided, and the authentication request means responds to the authentication method selected by the authentication method selection means. Authentication information is transmitted to an external device, and an authentication process using the authentication method is requested.
An external device connected via a network may be an SMTP server, a POP3 server, or an IMAP4 server.
[0013]
These communication devices may be provided with image information communication means for transmitting / receiving image information to / from the external device via a network.
Furthermore, the authentication method selected by the authentication method selection means Limit range It is preferable to provide selection instruction receiving means for receiving an instruction. In addition, the selection instruction receiving unit is configured to change the authentication method selection unit according to the received instruction. Send the above authentication information encrypted From among encryption authentication methods The above one authentication method The first mode to select, Send the authentication information in clear text From plaintext authentication methods The above one authentication method From the second mode to select, the encryption authentication method and the plaintext authentication method The above one authentication method One of the third modes to be selected is set.
[0014]
Further, these communication devices may be provided with means for setting the validity / invalidity of the operation of the authentication requesting means.
further, When the authentication request means makes an authentication request, it is preferable to provide a storage means for storing an authentication method related to the authentication request and an authentication result by the external device.
[0015]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
First, a configuration example of a network to which a communication apparatus according to the present invention is connected will be described. FIG. 2 is a diagram showing the configuration of the network. In FIG. 2, the address shown in parentheses together with a communication device such as a workstation and an external device is an e-mail address corresponding to that device. This point will be described later.
[0016]
This network is obtained by connecting a network 1 and a network 2, each of which is a LAN (local area network), to the Internet 3 via a router device 5 or 6.
A workstation (WS) 11 and a scanner 12 which are communication devices according to the present invention are connected to the network 1 together with various types of external devices such as a server device 13, a WS 14, and a FAX device 15. On the other hand, many external devices such as the server device 23, WS 21, 24, and FAX device 22 are also connected to the network 2.
Each of these communication devices and external devices has a communication function and can communicate via a network.
[0017]
The scanner 12 is an image reading apparatus provided with an image reading means, and the FAX apparatuses 15 and 22 are image forming apparatuses provided with an image forming means.
The scanner 12 and the FAX apparatuses 15 and 22 also have a facsimile communication (FAX) function, and are public such as PSTN (Public Switched Telephone Networks) or ISDN (Integrated Services Digital Network). Communication via the network 4 is also possible. However, this FAX function and connection to the public network 4 are not essential to the present invention.
[0018]
The details of the scanner 12 and the WS 11 will be described later. Further, since the FAX apparatuses 15 and 22 are neither unique nor essential to the present invention, detailed description thereof will be omitted.
The server device 13 is a mail server, and is connected to the Internet 3 at all times, and manages transmission / reception of e-mails performed by client devices (WS11, WS14, scanner 12, FAX device 15) connected to the network 1. Similarly, the server device 23 manages transmission / reception of e-mails performed by client devices (WS21, WS24, FAX device 22) connected to the network 2.
[0019]
The mail server stores a server (such as an SMTP server) that sends an e-mail to a client device in another network, and an e-mail sent to the client device in its own network, and is downloaded from the user. Although there are servers (POP3 server, IMAP4 server, etc.) corresponding to the request, the server apparatuses 13 and 23 are assumed to have both of these functions.
[0020]
<First Embodiment>
Next, the workstation 11 shown in FIG. 2, which is the first embodiment of the communication apparatus of the present invention, will be described in detail.
First, the functional block diagram of FIG. 1 shows the functional configuration of this workstation. In this figure, only the functions of the parts related to the present invention are shown.
The workstation (WS) 11 uses, as hardware, a known computer such as a PC (personal computer) equipped with a CPU, ROM, RAM, HDD (hard disk drive), communication interface (I / F), and the like. Can do.
[0021]
The CPU functions as the control unit 16 that performs overall control of the entire WS 11 by executing various control programs stored in the ROM and HDD. The function of the storage unit 17 is realized by a storage unit such as a ROM, RAM, or HDD. The communication I / F 18 is a communication unit for communicating with an external device such as the server device 13 connected via a network.
As functions according to the present invention, the control unit 16 has functions of an authentication method selection unit 25 and an authentication request unit 26.
The authentication method selection unit 25 functions as an authentication method selection unit that automatically selects an authentication method according to the external device when communicating with the external device, and the authentication request selection unit 26 is selected by the authentication method selection unit 25 It functions as an authentication request means for transmitting authentication information corresponding to the authentication method to the external device and requesting an authentication process in the authentication method.
[0022]
Hereinafter, an operation when the WS 11 requests communication with the server device 13 will be described with an example. In the following operation example, the user ID (user name) and password registered in advance by the user in the storage unit 17 of the WS 11 and the address of the server device (“msrv13.abc.co.jp” shown in FIG. 2) And are stored.
[0023]
<< First Operation Example: When Server Device 13 Functions as an SMTP Server >>
First, the user of the workstation (WS) 11 transmits an e-mail to the user of the workstation 21 connected to the network 2 shown in FIG. 2 via the server device 13 functioning as an SMTP (Simple Mail Transfer) server. The operation in this case will be specifically described along the flowchart of FIG. 3 with reference to the communication sequences shown in FIGS.
FIG. 4 is a diagram illustrating an example of a communication sequence when the server device is compatible with authentication processing, and FIG. 5 is a diagram illustrating an example of a communication sequence when the server device is not compatible with authentication processing. is there. FIG. 6 is a diagram illustrating an example of a communication sequence when the server apparatus does not support the ESMTP mode. In these communication sequences, a solid line arrow indicates a request transmitted from the WS 11 to the server apparatus 13, and a broken line arrow indicates a response returned from the server apparatus 13 to the WS 11.
[0024]
The user of WS11 creates an e-mail addressed to the user of WS21 using e-mail software or the like, and electronically inputs the address of WS21 ("msrv23.xyz.co.jp" shown in FIG. 2) in the TO: field of the mail header. When designated as a mail transmission destination and instructed to be transmitted, the CPU of the WS 11 starts the processing shown in the flowchart of FIG.
First, in step S1, the server apparatus 13 is connected to the TCP port 25 (this “25” is a standard of TCP / IP (Transmission Control Protocol / Internet Protocol), not the code of this specification). This communication connection is performed by transmitting a request R1 for requesting connection to the server device 13 as shown in FIGS. In addition, the server apparatus 13 will return response R2 which shows a connection response, if a connection request is received.
[0025]
When communication is connected in step S1, the server apparatus 13 is requested to shift to the ESMTP (SMTP service Extensions) mode in the next step S2.
For example, as shown in request R3 in FIGS. 4 to 6, the request to shift to the ESMTP mode is sent to the server apparatus 13 together with the “EHLO” command for requesting the shift to the ESMTP mode, and the host name of the WS 11 (in this example, This is done by sending "ws11.abc.co.jp").
In the next step S3, it is determined whether or not the server device 13 is compatible with the ESMTP mode. The server device 13 returns a different response to the request transmitted in step S2 depending on whether or not the request corresponds to the ESMTP mode, so this determination can be made based on the received response.
[0026]
At this time, if the server apparatus 13 is compatible with the ESMTP mode, the server apparatus 13 also returns a list of commands that the client apparatus can use with the extended function, together with a response indicating that the process of shifting to the ESMTP mode has been completed normally.
For example, in the example shown in FIG. 4, the server apparatus 13 uses EXPN, as a response R4, together with “250-Hello wsll.abc.co.jp” with a reply code number 250 indicating that the transition process to the ESMTP mode has been normally completed. A response indicating that the four commands SIZE, AUTH, and HELP can be used is returned. Of these, AUTH is a command for designating an authentication method to be used. Here, “250-AUTH LOGIN CRAM-MD5” indicates that the methods of “LOGIN” and “CRAM-MD5” can be selected. .
[0027]
Further, in the example shown in FIG. 5, the server device 13 responds that the process of shifting to the ESMTP mode is normally completed and that three commands of EXPN, SIZE, and HELP can be used, and that the AUTH command cannot be used as a response R4 ′. Is returned. Returning to the description of FIG. 3, if the determination in step S <b> 3 is YES, the process proceeds to step S <b> 4 to determine whether or not the server device 13 supports authentication processing. This determination can be made based on the presence or absence of a response indicating that the AUTH command can be used in the above response. If it can be used, the authentication process is supported, and if not, it is determined that the authentication process is not supported.
[0028]
If the server apparatus supports the authentication process in step S4, the process proceeds to step S5, and it is determined whether or not the authentication method supported by the server apparatus 13 is compatible with the own apparatus. This determination can be made based on the argument “250-AUTH” in the above response. For example, in the case of the response R4, since it can be seen that the server device 13 supports “LOGIN” and “CRAM-MD5”, it may be determined based on whether or not the own device supports these. .
If the determination in step S5 is YES, the process proceeds to step S6 and is selected as an authentication method that uses the authentication method. At this time, if there are a plurality of candidates, an appropriate one is selected from the candidates. In this case, for example, the selection criteria according to the priority order determined by the user, which prioritizes the method of encrypting and transmitting the authentication information, is selected. , Etc. are conceivable.
[0029]
Then, in the next step S7, the server apparatus 13 is requested to perform authentication processing by the authentication method selected in step S6. In the example illustrated in FIG. 4, “AUTH CRAM-MD5” of the request R5 corresponds to this request, and is a request for requesting an authentication process using the CRAM-MD5 (Challenge Response Authentication Mechanism-Message Digest 5) method.
In the next step S8, authentication information corresponding to the authentication method requested in step S7 is transmitted to the server device 13. As this authentication information, a password, encrypted data, and the like can be considered. In the CRAM-MD5 system, a character string obtained by adding a password to a challenge character string received from the server device 13 is processed by MD5 that is a hash function. The hash value obtained in this way and the user ID.
[0030]
In the example shown in FIG. 4, the server device 13 that has received the request R5 requesting authentication processing according to the CRAM-MD5 method, as a response R6, sends an appropriate challenge character string together with the reply code 334 indicating that the authentication processing has started. Therefore, the WS 11 transmits the hash value (encrypted character string) obtained by performing the above processing to the challenge character string and the user ID to the server device 13 as the request R7.
The server device 13 uses the MD5 to process the character string obtained by adding the password corresponding to the received user ID to the transmitted challenge character string to obtain a hash value, and compares it with the received hash value. It is possible to determine whether or not the password is correct.
[0031]
After step S8, the process proceeds to step S9, where it is determined whether the authentication is successful. The server device 13 that has received the authentication information transmitted in step S8 performs an authentication process and returns the result as a response. Therefore, the success or failure of the authentication can be determined with reference to the content of this response. If there is no response within a predetermined period, it may be handled as an authentication failure.
In the example illustrated in FIG. 4, the server apparatus 13 returns a reply code “235 Ok” indicating successful authentication in the response R8.
[0032]
If it is determined in step S9 that the authentication is successful (authentication OK), it is determined that the e-mail may be transmitted, the process proceeds to step S10, a normal e-mail transmission process is performed, and the process ends.
Note that the e-mail transmission process in step S10 includes the address “Mail From: <ws11@abc.co.jp>” of the user of the WS 11 that is the e-mail transmission source as shown in FIG. 13 is a process of transmitting to the server device 13 the subject name, body text, attached file, and the like of the e-mail. Since these e-mail transmission processes are not specific to the present invention, a detailed description thereof will be omitted.
[0033]
If it is determined in step S9 that the authentication has failed (authentication NG), the process proceeds to step S11 where error processing is performed and the process ends. As this process, for example, an error message such as “authentication failed” or “password is incorrect” may be displayed on the display of the WS 11 to notify the error.
Further, if the server device 13 does not support the authentication process in step S4 of FIG. 3 and if there is no appropriate authentication method in step S5, the authentication process cannot be performed, so the authentication process is not performed. As it is, the process proceeds to step S10 as it is, and after the e-mail transmission process is performed, the process is terminated.
[0034]
Further, even if the server device 13 does not support the ESMTP mode in step S3, the authentication process cannot be performed. Therefore, the process proceeds to step S12 assuming that the authentication process is not performed, and the server device 13 shifts to the SMTP mode. Request.
If the server device 13 does not support the ESMTP mode, as shown in FIG. 6, the server device 13 returns an error response such as a response R10 to the request R3 requesting the transition from the WS 11 to the ESMTP mode. .
In such a case, although not shown, a “HELO” command is sent to the server apparatus 13 to request the SMTP server to shift to the SMTP mode.
[0035]
In the next step S13, it is determined whether or not the server device 13 is compatible with the SMTP mode. The server device 13 returns a different response to the request transmitted in step S12 depending on whether or not it is compatible with the SMTP mode, so this determination can be made based on the received response.
If the server device 13 is compatible with the SMTP mode, the process proceeds to step S10, a normal e-mail transmission process is performed, and the process ends. On the other hand, if the server device 13 does not support the SMTP mode, the process proceeds to step S14, an error process is performed, and the process is terminated. As this process, for example, it is conceivable to display an error message such as “The connected server does not support transmission of e-mail” on the display of the WS 11 to notify the error.
[0036]
Although illustration is omitted, if an error response is returned from the SMTP server when the authentication process is requested from the SMTP server in step S7, the process proceeds to step S10 without performing the processes in steps S8 and S9. It is advisable to end the process by performing an e-mail transmission process.
Alternatively, in the above case, if there is another authentication method that can be selected, the authentication method may be selected and designated to the server device 13 again.
[0037]
In the above processing, the CPU of WS11 functions as an authentication method selection unit in steps S5 and S6, and the same CPU functions as an authentication request unit in steps S7 and S8.
Then, by performing the processing as described above, it is possible to automatically select an authentication method supported by both the WS 11 and the server device 13 and perform authentication processing by the authentication method. Even without examining or setting these pieces of information, authentication can be performed by an appropriate authentication method according to the server device.
[0038]
<< Second Operation Example: When Server Device 13 Functions as a POP3 Server >>
Next, the operation when the user of WS 11 receives (downloads) an e-mail via the server device 13 functioning as a POP3 (Post Office Protocol version 3) server will be described with reference to the communication sequences shown in FIGS. However, it demonstrates concretely along the flowchart of FIG.
FIG. 8 is a diagram showing an example of a communication sequence in the case where the server apparatus supports authentication processing by the encryption authentication method (hereinafter simply referred to as “encrypted authentication processing”), and FIG. It is a figure which shows an example of a communication sequence in case it does not respond | correspond to the authentication authentication process. In these communication sequences, a solid line arrow indicates a request transmitted from the WS 11 to the server apparatus 13, and a broken line arrow indicates a response returned from the server apparatus 13 to the WS 11.
[0039]
The CPU of the WS 11 performs processing shown in the flowchart of FIG. 7 periodically or when a user gives an instruction, and checks whether or not an incoming e-mail addressed to the user is stored in the mailbox of the server device 13. investigate.
When this process is started, first, in step S21, communication connection is performed with the server device 13 and the TCP port 110 (this "110" is a standard of TCP / IP, not a symbol in the present specification). This communication connection is performed by transmitting a request R11 for requesting connection to the server device 13 as shown in FIGS. The server device 13 returns a response when accepting the connection request, but the content of the response differs depending on whether the server device 13 supports encryption authentication processing or not.
[0040]
For example, in the example shown in FIG. 8, the server apparatus 13 returns a challenge character string as a response R12 together with a reply code “+ OK” indicating a connection response. This challenge character string is an OTP (one-time password) used when performing encryption authentication processing by the challenge and response method.
On the other hand, in the example shown in FIG. 9, since the server device 13 does not support the encryption authentication process, only the reply code “+ OK” indicating the connection response is returned as the response R12 ′.
However, when the communication is connected in step S21, the WS 11 does not depend on whether or not the server device 13 supports the encryption authentication process, and the encryption authentication method supported by itself in the next step S22. A predetermined one is selected from the list.
[0041]
Then, in the next step S23, the server apparatus 13 is requested to perform authentication processing by the encryption authentication method selected in step S22, and in step S24, authentication information corresponding to the encryption authentication method is sent to the server apparatus 13. Send.
Note that step S23 and step S24 may be performed simultaneously. For example, in the example shown in FIGS. 8 and 9, as a request R13, a user ID and an encrypted character string as authentication information are transmitted to the server device 13 together with a command “APOP” requesting authentication processing in a challenge and response system. Yes. Similar to the encrypted character string in the first operation example, this encrypted character string is obtained by encrypting a character string obtained by adding a password to the challenge character string.
[0042]
At this time, the server device 13 performs an authentication process if the requested encryption authentication process is supported, and returns an authentication result to the WS 11 as a response. On the other hand, if the requested encryption authentication process is not supported, the authentication process is not performed and an error response is returned to the WS 11.
For example, in the example illustrated in FIG. 8, the server device 13 encrypts a character string obtained by adding a password corresponding to the received user ID to the transmitted challenge character string, and compares the encrypted character string with that received in the request R13. If the two match, it is determined that the authentication is successful. Then, a response “+ OK” indicating successful authentication is returned as a response R14. In the example illustrated in FIG. 9, the server device 13 returns a response “−ERR” indicating an authentication failure as the response R <b> 16.
[0043]
Returning to the description of FIG. 7, it is determined whether or not the authentication information transmitted to the server device 13 in step S24 has been successfully authenticated in the next step S25. This authentication success / failure determination can be made with reference to the authentication result of the response received from the server device 13. In addition, when there is no response within a predetermined period, it may be handled as an authentication failure.
If it is determined in step S25 that the authentication is successful (authentication OK), it is determined that communication is permitted, the process proceeds to step S26, a normal e-mail reception process is performed, and the process ends. The e-mail receiving process in step S26 transmits the command “STAT” to the server device 13 as shown in the request R15 in FIGS. 8 and 9, and the WS 11 stored in the mail box of the server device 13 or the like. This is a process of checking the number and size of e-mail addressed to the user and receiving the e-mail. Since these e-mail receiving processes are not unique to the present invention, detailed description thereof is omitted.
[0044]
On the other hand, if it is determined in step S25 that the authentication has failed (authentication NG), the process proceeds to step S27, where the server apparatus 13 is requested to perform authentication processing using the plaintext authentication method (hereinafter simply referred to as “plaintext authentication processing”). Send. For example, in the example shown in FIG. 9, a user ID is transmitted as a request R17 together with a command “USER” for specifying a user ID, and a response “+ OK” indicating that the user ID is recognized from the server device 13 is received in response R18. Then, as a request R19, a password is transmitted together with a command “PASS” for transmitting authentication information by a plain text authentication method.
At this time, the server device 13 compares the password corresponding to the user ID received in the request R17 with the password received in the request R19, and determines that the authentication is successful if they match. Then, a response “+ OK” indicating successful authentication is returned as a response R20. If they do not match, it is determined that the authentication has failed, and a response “-ERR” indicating the authentication failure is returned.
[0045]
In the next step S28, it is determined whether or not the plaintext authentication process has been successful. This authentication success / failure determination can be made with reference to the authentication result of the response received from the server device 13. In addition, when there is no response within a predetermined period, it may be handled as an authentication failure.
If it is determined in step S28 that the authentication is successful (authentication OK), it is determined that the communication is permitted, the process proceeds to step S26 described above, an e-mail reception process is performed, and the process ends.
On the other hand, if it is determined in step S28 that the authentication has failed (authentication NG), the process proceeds to step S29, where error processing is performed and the process ends. As this process, for example, an error message such as “authentication failed” or “password is incorrect” may be displayed on the display of the WS 11 to notify the error.
[0046]
In the above processing, the CPU of WS11 functions as an authentication method selection unit in steps S22 and S27, and the same CPU functions as an authentication request unit in steps S23, S24, and S27.
In the first operation example described above, the authentication method corresponding to the WS 11 is automatically selected from the authentication methods supported by the server device 13 and the authentication process using the authentication method is performed. In the second operation example, the authentication process using the encryption authentication method is attempted regardless of whether or not the server device 13 supports the encryption authentication process. However, whether or not the server apparatus 13 is compatible with the encrypted authentication method is determined based on the response of the authentication process. If the server device 13 does not support the encrypted authentication method, the authentication process using the plaintext authentication method is automatically performed. I have to.
[0047]
Therefore, similarly to the first operation example, even if the user does not investigate or set the authentication method in advance, authentication can be performed with an appropriate authentication method according to the server device.
When there are a plurality of encryption authentication methods supported by WS11, when an authentication failure (authentication NG) is determined in step S25, instead of proceeding to step S27, the process returns to step S22 and another encryption authentication method. May be selected and the processing from step S23 to step S25 may be performed again.
In this way, if the authentication process is attempted in all encryption authentication methods supported by WS11 until the authentication success (authentication OK) is determined in step S25, the probability of performing the encryption authentication process is high. Therefore, the safety of communication is improved.
[0048]
Alternatively, in response to the connection request transmitted in step S21, the server device 13 returns different responses depending on whether the encryption authentication processing is supported or not, as described above. The process for determining whether to perform the encryption authentication process based on the process may be performed between step S21 and step S22. For example, in the case of the communication sequences shown in FIGS. 8 and 9, the determination can be made based on the presence or absence of a challenge character string enclosed in <> after “+ OK” in the response R12. If it is determined that the encryption authentication process is performed in this process, the process proceeds to step S22. If it is determined that the plain text authentication process is performed, the process proceeds to step S27.
Further, when the AUTH command described above can be used by the server device 13 functioning as the POP3 server, authentication can be performed in the same manner as in the first operation example, and an e-mail receiving process can be performed.
[0049]
<< Third Operation Example: When Server Device 13 Functions as an IMAP4 Server >>
Next, with reference to the communication sequence shown in FIGS. 11 and 12, the operation when the user of the WS 11 receives an e-mail via the server device 13 functioning as an IMAP4 (Internet Mail Access Protocol version 4) server. A specific description will be given along the flowchart of FIG.
FIG. 11 is a diagram illustrating an example of a communication sequence when the server device supports encryption authentication processing, and FIG. 12 illustrates an example of a communication sequence when the server device does not support encryption authentication processing. FIG. In these communication sequences, solid-line arrows and broken-line arrows are the same as those in the communication sequence described above, and indicate requests and responses, respectively.
[0050]
In the communication sequences of FIGS. 11 and 12, any one of “tag”, “*”, and “+” is added to the head of each request and response. These are all tags defined in the IMAP4 format, and are intended to clarify the relationship between requests and responses. In addition, since a tag does not concern on the characteristic of this invention, each detailed description is abbreviate | omitted.
As in the second operation example, the WS 11 starts e-mail reception processing shown in the flowchart of FIG. 10 periodically or when a user gives an instruction.
First, in step S31, communication is connected to the server apparatus 13 using the TCP port 143 (this “143” is a TCP / IP standard, not a symbol in the present specification). This communication connection is performed by transmitting a request R21 for requesting connection to the server device 13 as shown in FIGS. In addition, the server apparatus 13 will return response R22 which shows a connection response, if a connection request is received.
[0051]
When communication is connected in step S31, a request for transmission of a function list of the server device 13 is requested in next step S32. For this request, for example, as shown in a request R23 in FIGS. 11 and 12, a command “CAPABILITY” instructing the server device 13 to transmit a list of usable extended commands and corresponding authentication methods is transmitted. Do by.
[0052]
At this time, as a response to this request, the server device 13 returns a list of functions and a command “Ok” indicating that the transmission process has ended normally (display OK) to the WS 11. For example, in the example shown in FIG. 11, “map4 auth = CRAM-MD5” and “Ok” are returned as the response R24. Among these, “map4auth =” is a command indicating that the server apparatus 13 supports authentication processing (encryption authentication processing) in the encryption authentication method, and the argument lists the corresponding encryption authentication processing. Is displayed. That is, here, it corresponds to “CRAM-MD5”.
If the transmission process is abnormally terminated (display NG), the server device 13 returns only the command “Bad” as a response, although not shown.
If the server device 13 has no extended function, only “Ok” is returned as a response, as in a response R24 ′ shown in FIG. In this case, it is indicated that there is no encryption authentication process supported by the server device 13.
[0053]
Returning to the description of FIG. 10, in the next step S33, it is determined whether or not the response from the server device 13 has been normally received. If the determination in step S33 is no, the process proceeds to step S44, where error processing is performed and the process ends. As this process, for example, an error message may be displayed on the display of the WS 11 to notify the error.
On the other hand, if the determination in step S33 is YES, the process proceeds to the next step S34 to determine whether or not the server device 13 is compatible with the encryption authentication process. This determination can be made based on the presence / absence of a response indicating that the response corresponds to the encryption authentication process.
[0054]
If it is determined in step S34 that the server apparatus 13 is compatible with the encryption authentication process, the process proceeds to step S35, and the server apparatus 13 is compatible with the encryption authentication method supported by the server apparatus 13. Judge whether there is. This determination can be made based on the argument “map4 auth =” in the response. For example, in the case of the response R24, it can be seen that the server device 13 is compatible with “CRAM-MD5”, and therefore, it may be determined based on whether or not the own device supports this.
[0055]
If the determination in step S35 is YES, the process proceeds to step S36, and an authentication method that is compatible with both the server device 13 and the own device is selected as the encryption authentication method to be used. If there are a plurality of candidates at this time, an appropriate one is selected from them. As a selection criterion in this case, for example, a priority order determined by the user can be considered. In the next step S37, the server device 13 is requested to perform an encryption authentication process using the authentication method selected in step S36. In the example shown in FIG. 11, “AUTHENTICATE CRAM-MD5” corresponds to this request, and is a request for requesting authentication processing by the CRAM-MD5 method.
[0056]
In the next step S38, authentication information corresponding to the authentication method requested in step S37 is transmitted to the server device 13. For example, in the example shown in FIG. 11, the server device 13 that has received the request R25 requesting the authentication processing by the CRAM-MD5 method returns a challenge character string as the response R26, and the WS 11 uses the challenge character string to The encrypted character string obtained in the same manner as in the operation example 1 is transmitted as the request R27 to the server device 13 as authentication information. At this time, the server device 13 determines whether or not the password used by the client device 11 is correct from the received encrypted character string in the same manner as in the first operation example.
[0057]
After step S38, the process proceeds to step S39, and it is determined whether or not the encryption authentication process is successful (authentication OK). The server device 13 that has received the authentication information transmitted in step S38 performs the encryption authentication process and returns the result as a response. Therefore, the determination of the success or failure of the encryption authentication can be made with reference to the response content. . If there is no response within a predetermined period, it may be handled as encryption authentication failure. In the example illustrated in FIG. 11, the server apparatus 13 returns a reply code “Ok” indicating successful authentication in the response R28.
If it is determined in step S39 that the authentication is successful (authentication OK), the process proceeds to step S40, and a normal e-mail reception process similar to that in step S26 shown in FIG.
[0058]
On the other hand, if it is determined in step S34 that the server device 13 does not support the encryption authentication process, or there is no encryption authentication method that the server device 13 supports in step S35. If YES, the process proceeds to step S41, and the server device 13 is requested to perform authentication processing using the plaintext authentication method. For example, in the example shown in FIG. 12, the user ID and password are transmitted in plain text to the server device 13 as arguments of the command “LOGIN” for requesting login in the request R29, thereby performing authentication processing in the plain text authentication method. To request. At this time, the server device 13 can determine whether the password used by the client device 11 is correct from the user ID and password received in the request R29, as in the case of the first operation example. . In the example shown in FIG. 12, the server apparatus 13 returns a reply code “Ok” indicating successful authentication in the response R30.
[0059]
And after step S41, it progresses to step S42 and it is judged whether the plaintext authentication process was successful. The server device 13 that has received the authentication information transmitted in step S41 performs a plaintext authentication process and returns the result as a response. Therefore, it is possible to determine the success or failure of the authentication with reference to the contents. If there is no response within a predetermined period, it may be handled as an authentication failure.
If it is determined in step S42 that the authentication is successful (authentication OK), the process proceeds to step S40, a normal e-mail transmission process is performed, and the process ends.
On the other hand, if the authentication has failed (authentication NG) in step S42, the process proceeds to step S43, and error processing is performed in the same manner as in the first operation example, and the process ends.
[0060]
Even in the case of authentication failure (authentication NG) in step S39, the process proceeds to step S41 and the same processing as described above is performed.
In the above processing, the CPU of WS11 functions as an authentication method selection unit in steps S35, S36, and S41, and the same CPU functions as an authentication request unit in steps S37, S38, and S41.
[0061]
By performing the processing as described above, it is possible to automatically select an encryption authentication method supported by both the WS 11 and the server device 13 and perform authentication processing by the encryption authentication method. Even if the user does not investigate or set the information in advance, the authentication can be performed by an appropriate authentication method according to the server device. In addition, when there is no encryption authentication method supported by both the WS 11 and the server device 13, authentication is automatically performed using the plain text authentication method. There is no loss of reception.
[0062]
<Second Embodiment>
Next, the scanner 12 shown in FIG. 2, which is a second embodiment of the communication apparatus of the present invention, will be described in detail. The scanner 12 is a communication device provided with image information communication means for transmitting / receiving image information to / from an external device via a network.
First, the functional configuration of this scanner is shown in the functional block diagram of FIG. In this figure, only the functions of the parts related to the present invention are shown. In FIG. 13, the same parts as those in FIG.
The scanner 12 includes a scanner unit 31, a plotter unit 32, an operation unit 33, a display unit 34, and a clock circuit unit 35, which are functional units of a general scanner, as well as a CPU, ROM, RAM, HDD, communication interface (I). / F) and the like, and a FAX unit 20 which is a general FAX function unit. All of these can be configured using known hardware.
[0063]
The CPU functions as a control unit 16 ′ that controls the entire scanner 12 by executing various control programs stored in the ROM and HDD. The function of the storage unit 17 ′ is realized by a storage unit such as a ROM, a RAM, and an HDD.
The control unit 16 ′ has functions of an encoding / decoding unit 27 and an image information communication unit 28 in addition to the functions of the authentication method selection unit 25 and the authentication request unit 26 described above.
The encoding / decoding unit 27 performs encoding such as data compression or conversely decodes the encoded image data and restores the original state. Further, the image information communication unit 28 controls the communication I / F 18 and transmits / receives image information (image data) to / from the server device 13 via the network, thereby fulfilling a function of an image information communication unit.
[0064]
The storage unit 17 ′ has functions of a system memory 36 that stores basic software such as an OS, a parameter memory 37 that temporarily stores variables such as setting values, and an image storage unit 38 that stores image data.
The scanner unit 31 is a unit that reads an image on a sheet and converts it into digital image data.
The plotter unit 32 is a unit that forms an image on a sheet based on image data. The operation unit 33 is used by the user to set operation or create an e-mail or the like.
The display unit 34 is for displaying the setting state, operation status, image data, help information, and the like of the scanner 12. The clock circuit unit 35 has a clock function and measures time.
[0065]
On the other hand, the FAX unit 20 includes a G3 FAX modem 40 and a network control unit 39, and has a general FAX communication function.
When the FAX unit 20 is provided in the scanner 12, the image data received via the network 1 can be faxed as it is without being printed by the plotter unit 32. However, since the FAX function is not essential for the present invention, the FAX unit 20 may not be provided.
Further, the plotter unit 32, the display unit 34, and the clock circuit unit 35 may not be provided.
Hereinafter, the operation when the scanner 12 requests the server device 13 to communicate will be described with an example. In the following operation example, the user ID and password registered in advance by the user and the address of the server device (“msrv13.abc.co.jp” shown in FIG. 2) are stored in the storage unit 17 ′ of the scanner 12. Assume that it is stored.
[0066]
When the scanner 12 transmits an e-mail attached with image data to the user of the workstation 21 connected to the network 2 shown in FIG. 2 via the server device 13 functioning as an SMTP server, the user first stores the storage unit 17. The image data to be sent is selected from the image storage unit 38, or the sheet on which the image to be sent is formed is set in the scanner unit 31 and the operation unit 33 is operated to convert the image on the sheet into image data. .
Then, an e-mail addressed to the user of WS 21 is created using e-mail software and the e-mail is sent with the address of WS 21 (“msrv23.xyz.co.jp” shown in FIG. 2) in the TO field of the mail header. The destination is designated, and the selected image data or the converted image data is attached and transmission is instructed. Then, the CPU of the scanner 12 performs the same processing as steps S1 to S14 shown in the flowchart of FIG. 3 and transmits an e-mail as in the case of the WS 11 described in the first embodiment.
[0067]
On the other hand, when the scanner 12 receives an e-mail attached with image data from the mailbox of the server device 13 functioning as the POP3 server, the CPU of the scanner 12 is shown in the flowchart of FIG. The same processing as steps S21 to S29 is performed.
When the scanner 12 receives an e-mail attached with image data from the mailbox of the server device 13 functioning as an IMAP4 server, the same processing as steps S31 to S44 shown in the flowchart of FIG. 10 is performed. .
Note that examples of communication sequences between the scanner 12 and the server device 13 in these processes are “WS11” in the communication sequences shown in FIGS. 4 to 6, 8, 9, 11, and 12, respectively. Is replaced with "."
[0068]
Therefore, also in the second embodiment, as in the first embodiment, an authentication method that is compatible with both the scanner 12 (communication device) and the server device 13 (external device) is automatically selected, and Since the authentication process by the authentication method can be performed, it is possible to perform the authentication by an appropriate authentication method according to the server device even if the user does not investigate or set the information in advance.
In the second embodiment, the case where the communication device is a scanner has been described. However, the present invention is not limited to this. The communication device may be another communication device (for example, a FAX device or a network printer) that can communicate with the network. Good.
[0069]
<Third Embodiment>
Next, a third embodiment of the communication apparatus according to the present invention will be described. This embodiment is also a scanner. In the scanner of the second embodiment, the selection range when the authentication method is automatically selected is the encryption authentication method in which the authentication information is encrypted and / or the authentication information is transmitted in plain text. An instruction to restrict to the plaintext authentication method transmitted by the is received. Since other points are the same as those of the scanner of the second embodiment, description thereof is omitted.
[0070]
In this scanner, an instruction for setting a selection range of authentication information can be received in advance using a predetermined application program or the like. In this process, the CPU of the scanner 12 functions as a selection instruction receiving unit.
Then, in accordance with the received instruction, the first mode for automatically selecting the selection method when the CPU functions as the authentication method selection unit according to the external device from the encryption authentication method, plaintext authentication Any one of the second mode for automatically selecting the method according to the external device from among the methods, and the third mode for automatically selecting the method according to the external device from among the encryption authentication method and the plaintext authentication method I try to set it up.
Hereinafter, an operation example of this scanner will be described.
[0071]
<< Fourth Operation Example: When Server Device 13 Functions as an SMTP Server >>
FIG. 14 is a flowchart showing processing when the scanner authenticates with a server device functioning as an SMTP server and transmits an e-mail. In FIG. 14, the same parts as those in FIG.
When the user of the scanner 12 instructs transmission of an e-mail attached with image data, the CPU of the scanner 12 starts the process shown in the flowchart of FIG. In steps S1 to S3, processing similar to that in steps S1 to S3 shown in FIG. 3 is performed to attempt to shift the server device 13 to the ESMTP mode. If the server apparatus 13 does not support the ESMTP mode in step S3, the process proceeds to step S12. In steps S12 to S14, processing similar to that in steps S12 to S14 shown in FIG. Attempt to enter mode.
[0072]
On the other hand, if the server apparatus is compatible with the ESMTP mode in step S3, the process proceeds to step S4, and it is determined whether the server apparatus 13 is compatible with the authentication process as in step S4 shown in FIG.
If it is not supported in step S4, the process proceeds to step S56 as it is, and the same normal e-mail transmission process as in step S10 shown in FIG. 3 is performed and the process is terminated. In this case, authentication is not performed.
If it is determined in step S4, the process proceeds to step S50, and the setting of the authentication method selection method is changed to the third mode (a mode that can be freely selected from both the encryption authentication method and the plaintext authentication method without limitation). Judge whether or not.
[0073]
If the determination in step S50 is YES, the process proceeds to step S51, and as in the case of step S5 shown in FIG. 3, the own apparatus also supports the encryption authentication method supported by the server device 13. Determine if there is something.
Further, if the determination in step S51 is YES, the process proceeds to step S52, and an appropriate one is selected from encryption authentication methods that both the server apparatus 13 and the scanner 12 support. In the next step S53, the server apparatus 13 is requested to perform authentication processing using the authentication method selected in step S52, and in the subsequent step S54, authentication information corresponding to the encrypted authentication method selected in step S52 is transmitted to the server apparatus 13. To do. Since these detailed descriptions are the same as steps S6 to S9 in the first operation example, they are omitted here.
[0074]
In the next step S55, it is determined whether or not the authentication is successful (authentication OK). If it is determined in step S55 that the authentication is OK, the process proceeds to step S56, a normal e-mail transmission process is performed, and the process ends. If it is determined in step S55 that the authentication is NG, the process proceeds to step S57, and error processing similar to that in step S11 in FIG.
By the way, if there is no appropriate encryption authentication method in step S51, the process proceeds to step S58. In step S58, it is determined whether there is a plaintext authentication method that is compatible with both the server device 13 and the own device (scanner 12). This determination can be made in substantially the same manner as in step S5 shown in FIG. 3, although there is a difference between whether the target is an encryption authentication method or a plaintext authentication method.
[0075]
If the determination in step S58 is NO, there is no authentication method that is compatible with both, so the process proceeds directly to step S56, where the normal e-mail transmission process is performed without performing the authentication process, and the process ends. On the other hand, if the determination in step S58 is YES, the process proceeds to step S59, and an appropriate one is selected from the plaintext authentication methods that both the server device 13 and the scanner 12 support. In the next step S60, the server device 13 is requested to perform authentication processing using the plaintext authentication method selected in step S59, and in step S61, authentication information corresponding to the plaintext authentication method is transmitted to the server device.
After step S61, the process proceeds to step S55, and processing similar to that described above in steps S55 to S57 is performed.
[0076]
If the setting is not the third mode in step S50, the process proceeds to step S62. In step S62, it is determined whether or not the setting of the selection method is the first mode (a mode selected from the encryption authentication method).
If it is in the first mode, the process proceeds to step S63, and as in the case of step S51, whether or not there is an encryption authentication method supported by the server device 13 that is also supported by the own device. to decide.
If the determination in step S63 is YES, the process proceeds to step S52. Subsequently, as in the case where the determination in step S51 is YES, the encryption authentication method is selected, and the authentication process is performed using that method. If so, send an email and exit.
[0077]
Furthermore, if it is not the first mode in step S62, that is, if the setting of the selection method is the second mode (a mode for selecting from the plaintext authentication method), the process proceeds to step S64, and as in step S58, It is determined whether there is a plain text authentication method that both the server device 13 and the scanner 12 support.
If the determination in step S64 is YES, the process proceeds to step S59. Thereafter, in the same manner as in the case where the determination in step S58 is YES, a plaintext authentication method is selected and authentication processing is performed using that method. Send an email to and exit.
On the other hand, if the determination in step S64 is no, the process proceeds directly to step S56, where a normal e-mail transmission process is performed, and the process ends.
[0078]
In the flowchart of FIG. 14, if the server apparatus 13 does not support authentication processing in step S4, and if there is no appropriate authentication method in steps S58, S63, and S64, step S56 is performed without performing authentication processing. The normal e-mail transmission process is performed in advance.
In such a case, it is possible to reduce the probability that the transmission of the electronic mail becomes an error due to the difference in the authentication method between the server device 13 and the scanner 12.
[0079]
<< Fifth Operation Example: When Server Device 13 Functions as a POP3 Server >>
FIG. 15 is a flowchart showing processing when the scanner according to the third embodiment authenticates with a server device functioning as a POP3 server and receives an e-mail. In FIG. 15, the same parts as those in FIG.
The CPU of the scanner 12 starts the processing shown in the flowchart of FIG. 15 periodically or when the user of the scanner 12 instructs to receive an e-mail. In step S21, communication connection processing similar to that in step S21 shown in FIG. 7 is performed.
[0080]
In the next step S70, it is determined whether or not the setting of the authentication method selection method is the third mode.
When the setting is the third mode in step S70, the process proceeds to steps S71 to S73, and in the same way as in steps S22 to S24 shown in FIG. The server apparatus 13 is requested and authentication information is transmitted. In the next step S74, it is determined whether or not the authentication is successful (authentication OK). If the authentication is OK in step S74, the process proceeds to step S75, and a normal e-mail reception process is performed in the same manner as in step S25 shown in FIG.
In the case of authentication NG in step S74, the process proceeds to steps S76 to S78, a plaintext authentication method is selected, and authentication processing in that method is requested to the server device 13 as in the case of step S27 in FIG. Send.
[0081]
Then, in the next step S79, it is determined whether or not the authentication is successful (authentication OK). If the authentication is OK in step S79, the process proceeds to step S75 to perform normal e-mail reception processing and ends. If the authentication is NG, the process proceeds to step S80 and error processing is performed as in step S11 of FIG. Go and finish.
On the other hand, if the setting is not the third mode in step S70, the process proceeds to step S81 to determine whether or not the setting is the first mode.
If the determination in step S81 is NO, that is, if the setting is in the second mode, the process proceeds to step S76. Thereafter, the same processing as in the case where the determination in step S74 is NO is performed.
[0082]
If the determination in step S81 is yes, the process proceeds to steps S82 to S84, and the same processing as in steps S71 to S73 is performed. In the next step S85, it is determined whether or not the authentication is OK. If the determination is YES, the process of step S75 is performed and the process ends. If the determination in step S85 is no, the process proceeds to step S86, and error processing similar to that in step S80 is performed and the process ends.
As described above, the case where the electronic mail is received from the server apparatus functioning as the POP3 server has been described. However, when the AUTH command can be used as the extended function of the server apparatus 13, authentication is performed in the same manner as in the fourth operation example. You can also receive emails.
[0083]
<< Sixth Operation Example: When Server Device 13 Functions as an IMAP4 Server >>
FIG. 16 is a flowchart showing processing when the scanner according to the third embodiment authenticates with a server device functioning as an IMAP4 server and receives an e-mail. In FIG. 16, the same parts as those in FIG.
The CPU of the scanner 12 starts the processing shown in the flowchart of FIG. 16 periodically or when the user of the scanner 12 instructs to receive an e-mail. In step S31, communication connection processing similar to that in step S31 shown in FIG. 10 is performed.
[0084]
In the next step S90, it is determined whether or not the setting of the authentication method selection method is the second mode.
If the setting is the second mode in step S90, the process proceeds to steps S91 to S93, the plaintext authentication method is selected, and the authentication process in that method is performed in the same manner as in step S41 shown in FIG. Request and send authentication information.
Then, in the next step S94, it is determined whether or not the authentication is successful (authentication OK). If YES, the process proceeds to step S95, and the same normal e-mail reception process as described above is performed and terminated. In S111, error processing is performed and the process ends.
[0085]
On the other hand, if the setting is not the second mode in step S90, the process proceeds to step S96, and the server device 13 is requested to transmit the function list in the same manner as in step S32 shown in FIG. Then, in the next step S97, it is determined whether or not the function list has been normally received. If the determination is NO, the error processing of step S111 is performed and the process ends.
If the determination in step S97 is yes, the process proceeds to step S98 to determine whether the setting is in the third mode.
[0086]
If the mode is the third mode in step S98, the process proceeds to steps S99 to S104, and the encryption authentication method is selected in the same manner as in steps S34 to S39 shown in FIG. Request the device 13 to send authentication information. If NO is determined in any of steps S99, S100, and S104, the process proceeds to step S91, and thereafter, the same processing as that in the case where the determination in step S90 is YES is performed. If the determination in step S104 is yes, the normal e-mail reception process in step S95 is performed and the process is terminated. That is, in the case of the third mode, a method corresponding to both the own device and the server device is selected from both the encryption authentication method and the plaintext authentication method, and authentication is requested.
[0087]
On the other hand, if the setting is not the third mode in step S97, that is, if the setting is the first mode, the process proceeds to step S105. Thereafter, in steps S105 to S110, processing similar to that in steps S99 to S104 in the third mode described above is performed. In the first mode, since only the encryption authentication method is selected, there is no appropriate method, and if NO is determined in any of steps S105, S106, and S110, the process proceeds to step S111. It differs from the case of the third mode described above in that error processing is terminated.
[0088]
As described above, an instruction to restrict the range of the authentication method automatically selected by the communication device to the encryption authentication method and / or the plaintext authentication method is accepted, and the selection method when selecting the authentication method is the encryption authentication method. Set to either the first mode that restricts to the first mode, the second mode that restricts to the plaintext authentication method, or the third mode that can be freely selected from both the encryption authentication method and the plaintext authentication method without any particular limitation. Therefore, when the user desires authentication using the encryption authentication method or authentication using the plaintext authentication method, the user can select one of the authentication methods suitable for the communication device and the external device communicating with the communication device. It is possible to automatically select an authentication method according to the user's request. Furthermore, when an error occurs in authentication, the user can explicitly know the result and can easily deal with it.
[0089]
In addition, when it is known in advance that there is an encryption authentication method supported by both the communication device and the external device, it is set in advance that the first mode is set or there is no such encryption authentication method. If the second mode is set when it is known, the CPU does not perform useless processing, so the burden on the CPU can be reduced and the processing speed can be increased.
[0090]
<Modification of the first to third embodiments>
Next, modified examples of the above-described embodiments will be described.
In this modification, the validity / invalidity of the authentication request operation can be set in advance using a predetermined application program or the like.
Hereinafter, processing applied to the above-described fourth operation example will be described.
FIG. 17 shows the flow of this processing. In FIG. 17, the same parts as those in FIG. 3 or FIG.
When the user of the scanner 12 instructs to send an e-mail, the CPU of the scanner 12 starts the process shown in the flowchart of FIG. In step S1, processing similar to that in step S1 shown in FIG. 14 is performed.
[0091]
In the next step S120, it is determined whether or not the operation of the CPU as an authentication request means, that is, the authentication request operation is set to be valid.
If the determination in step S120 is NO, that is, if the authentication request is not set, the process proceeds to step S12, and the following steps S12 to S14 are the same as steps S12 to S14 shown in FIGS. Process. That is, the server apparatus 13 is requested to shift to the SMTP mode, and it is determined whether or not the server apparatus 13 supports the SMTP mode. If it is compatible, a normal e-mail transmission process is performed and the process ends. If not, an error process is performed and the process ends.
[0092]
If the determination in step S120 is yes, the process proceeds to step S2. In the following steps S2 to S4, processing substantially similar to steps S2 to S4 shown in FIG. 14 is performed. If NO is determined in the processes of steps S3 and S4, the authentication request operation is not set to be valid / invalid in the flowchart of FIG. 14, and thus the process proceeds to steps S12 and S56, respectively. However, in the flowchart of FIG. 17, even if the setting of the authentication request operation is valid in step S120, if NO is determined in the processes in steps S3 and S4, the authentication cannot be performed, so the process proceeds to step S57. Proceed with error handling and exit.
[0093]
If the determination in step S4 is YES, the process proceeds to step S50. Thereafter, in steps S50 to S64, processing similar to that in steps S50 to S64 shown in FIG. 14 is performed. If it is determined NO in any one of steps S58, S63, and S64, the process proceeds to step S56 without performing authentication in the flowchart shown in FIG. 14, and each performs normal e-mail transmission processing. . However, in the flowchart of FIG. 17, even if the setting of the authentication request operation is valid in step S120, if it is determined NO in the processes of steps S58, S63, and S64, authentication cannot be performed. In step S57, error processing is performed and the process ends.
[0094]
By performing such processing, it is possible to set in advance whether or not an authentication request is to be made. Therefore, if it is known in advance that the communication device or the external device does not support authentication processing, the CPU can be set invalid by setting it to invalid. However, unnecessary processing is not performed, the burden on the CPU is reduced, and the processing speed is increased.
Also, by setting the validity / invalidity of the authentication request operation, the user can select whether or not to perform authentication according to preference. Furthermore, when an error occurs in authentication, the user can explicitly know the result and can easily deal with it.
[0095]
By the way, here, if invalid in step S120, the process proceeds to step S12 to request the transition to the SMTP mode. However, the present invention is not limited to this. For example, as in steps S2 and S3, the server apparatus 13 may be requested to shift to the ESMTP mode, and it may be determined whether or not the server apparatus 13 supports the ESMTP mode. If the server device 13 is not compatible, error processing is performed and the processing is terminated. If the server device 13 is compatible, normal email transmission processing in step S56 is performed and the processing is terminated.
[0096]
In addition, this modification can be applied to other embodiments and operation examples. For example, when applied to the fifth operation example, the determination in step S120 is performed after step S21 in the flowchart shown in FIG. 15, and if the determination is YES, the process proceeds to step S70, and if the determination is NO, the process proceeds to step S70. The process may proceed to S75.
Further, when applied to the sixth operation, the determination of step S120 is performed after step S31 of the flowchart shown in FIG. 16, and the process proceeds to step S90 if the determination is YES, and step S95 if the determination is NO. Just go to.
[0097]
Next, when there are a plurality of selectable authentication methods in the processing of each operation example described above, a selection criterion for selecting an appropriate one from the plurality of authentication methods will be described.
As this selection criterion, a priority table as shown in FIG. 18 can be used. When there are a plurality of authentication methods that meet the selection conditions, the authentication method having a higher priority is selected preferentially in the priority table of the authentication methods.
The priority table is composed of an encryption authentication method priority table in which encryption authentication methods are arranged in accordance with the priority of selection, and a plaintext authentication method priority table in which plaintext authentication methods are arranged in accordance with the priority of selection. Each of these priorities can be arbitrarily set in advance using application software or the like and stored in a storage unit or the like of the communication device.
[0098]
In this priority table, only authentication methods supported by the communication device are described. In this process, the CPU functions as a means for setting the priority of authentication method selection when the CPU functions as an authentication method selection means.
When such a priority table is used, for example, in step S6 shown in FIG. 3, the authentication methods supported by the server device 13 and the authentication methods included in the priority table are compared in order from the highest priority. And select the first match. At this time, if the comparison is made with the encryption authentication method priority table first and if there is no match, the comparison with the plaintext authentication method priority table will increase the probability of performing the encryption authentication. Safety is further improved.
[0099]
FIG. When the priority order table shown in FIG. 2 is used, first, the authentication method supported by the server device 13 is compared with the CRAM-MD5 with the first priority in the encrypted authentication method priority order table and the KERBEROS_V4 with the second priority. Next, the first LOGIN and the second PLAIN in the plaintext authentication method priority table are compared.
LOGIN and PLAIN perform BASE64 which encodes application data (binary data) such as an image attached to an e-mail into a character string (text data). However, authentication information is transmitted and received in plain text. Then, it is positioned as plain text authentication.
[0100]
Also, in step S22 shown in FIG. 7, the method with the highest priority may be selected from the encryption authentication method priority order table. Further, in the case of authentication NG in step S25, it is preferable to return to step S22, select the method with the next highest priority, and request authentication again. In this way, if all the encryption authentication methods supported by the own device are selected in order of priority until the authentication is OK in step S25, the probability of performing the encryption authentication increases. Safety is further improved.
Further, in the same manner in step S27, the method with the highest priority may be selected from the plaintext authentication method priority table. In this case as well, there is a difference between the encryption authentication method and the plaintext authentication method, but the priority of the plaintext authentication method priority table is the same as in step S22 until the authentication is OK in step S28. It is recommended to request authentication from the highest one.
[0101]
In the case of the processing shown in the flowcharts of FIGS. 14 and 17, the authentication method supported by the server device 13 in step S51 and the authentication method included in the encrypted authentication method priority order table have the higher priority. Are compared in order, and a matching method may be selected in step S52. If there is no matching method at this time, the authentication method supported by the server device 13 in step S58 is compared with the authentication methods included in the plaintext authentication method priority table in the same manner, and the matching method is selected in step S59. Good.
Further, when performing the process of step S63, the encrypted authentication method priority order table is used, and when performing the process of step S64, the plaintext authentication method priority order table is used. Select a match.
[0102]
By performing the processing as described above, authentication processing can be selected and executed in the priority order designated by the user. Note that the priority table may be given a rank without distinguishing between the encryption authentication method priority table and the plaintext authentication method priority table.
[0103]
In each of the above-described embodiments, an authentication method related to an authentication request, an authentication result by an external device, error information, and the like are temporarily stored in a log area so that the user can check by printing on a sheet later. Good. Alternatively, the information may be temporarily stored in the log area of the external device so that the user can confirm by communicating with the external device later. In this way, the user can know the authentication result and grasp the operation status of the apparatus.
[0104]
Although the case where the communication device is a WS or a scanner has been described here, the present invention is not limited to this. The present invention can be applied to any communication device that has a communication function and can be connected to a network. For example, the present invention can be applied to an information processing device such as a personal computer, a communication terminal device such as a mobile phone or PHS, and a communication device such as an output device such as a printer.
Further, the external device with which the communication device communicates is not limited to the server device that functions as the above-described STMP server, POP3 server, or IMAP4 server. For example, it may be a server device that functions as another mail server that operates with substantially the same protocol as these mail servers. Or the server apparatus which functions as servers other than a mail server, such as a web server, may be sufficient. Furthermore, an electronic device other than the server device such as a large computer may be used.
[0105]
Furthermore, in this specification, CRAM-MD5 and KERBEROS_V4 are exemplified as encryption authentication methods, and LOGIN and PLAIN are exemplified as plaintext authentication methods. However, the authentication methods corresponding to the present invention are not limited to these. Other encryption authentication methods and plaintext authentication methods may be used.
In this specification, the case where the communication apparatus automatically selects the authentication method has been described. However, the present invention is not limited to this, and an encryption method for encrypting a part other than communication authentication (for example, the body of an e-mail). Can be automatically selected in the same manner.
[0106]
In addition, if a communication system is configured by the communication device of the present invention described above and an external device that is a communication partner, for example, a server device, an encryption method and an authentication method that the user corresponds to the communication device and the external device can be used. Since it is possible to automatically select an appropriate encryption method and authentication method without performing investigation or setting, it is possible to realize a convenient communication system with low user workload. it can.
[0107]
【The invention's effect】
As described above, according to the communication device of the present invention, it is possible to automatically select an appropriate authentication method according to the authentication method supported by the external device and the own device, and authenticate to the external device using the authentication method. Since the process is requested, it is not necessary for the user to investigate, select and set the authentication method and the encryption method supported by the communication device and the external device, and the burden on the user can be reduced.
[Brief description of the drawings]
FIG. 1 is a functional block diagram showing functions of a WS which is a first embodiment of a communication apparatus according to the present invention.
FIG. 2 is a diagram showing a configuration example of a network to which a communication apparatus according to the present invention is connected.
FIG. 3 is a flowchart showing processing when the WS shown in FIG. 1 transmits an e-mail via a server device functioning as an SMTP server.
4 is a diagram illustrating an example of a communication sequence between a WS and a server device when the server device supports authentication processing in the processing illustrated in FIG.
FIG. 5 is a diagram similarly showing an example when the server device does not support the authentication method.
FIG. 6 is a diagram similarly showing an example when the server device does not support the ESMTP mode.
FIG. 7 is a flowchart showing processing when the WS shown in FIG. 1 receives an e-mail via a server device functioning as a POP3 server.
8 is a diagram showing an example of a communication sequence between the WS and the server device when the server device is compatible with the encryption authentication method in the process shown in FIG.
FIG. 9 is a diagram similarly showing an example when the server apparatus does not support the encryption authentication method.
FIG. 10 is a flowchart showing processing when the WS shown in FIG. 1 receives an e-mail via a server device functioning as an IMAP4 server.
11 is a diagram showing an example of a communication sequence between the WS and the server device when the server device is compatible with the encryption authentication method in the process shown in FIG.
FIG. 12 is a diagram similarly showing an example when the server apparatus does not support the encryption authentication method.
FIG. 13 is a functional block diagram showing functions of a scanner which is a second embodiment of a communication apparatus according to the present invention.
FIG. 14 is a flowchart showing processing when the communication device according to the third embodiment of the present invention transmits an electronic mail via a server device functioning as an SMTP server.
FIG. 15 is a flowchart showing processing when an e-mail is received via a server device functioning as a POP3 server.
FIG. 16 is a flowchart showing processing when an e-mail is received via a server device functioning as an IMAP4 server.
FIG. 17 is a flowchart showing processing when a modification is applied to the processing shown in FIG. 14;
FIG. 18 is a diagram illustrating an example of a priority table for authentication methods;
[Explanation of symbols]
1, 2: Network 3: Internet
4: Public network 5, 6: Router device
11, 14, 21, 24: Workstation (WS)
12: Scanner 13, 23: Server device
15, 22: FAX machine 16, 16 ': Control unit
17, 17 ': Storage unit
18: Communication interface (I / F)
20: FAX section 25: Authentication method selection section
26: Authentication request unit 27: Encoding / decoding unit
28: Image information communication unit
31: Scanner unit 32: Plotter unit
33: Operation unit 34: Display unit
35: Clock circuit part 36: System memory
37: Parameter memory 38: Image storage unit
39: Network control unit 40: G3 FAX modem

Claims (8)

ネットワークを介して接続する外部装置と通信する通信手段と、該外部装置に認証情報を送信して認証処理を要求する認証要求手段とを有する通信装置であって、
当該通信装置が対応している認証方式の情報を、暗号化認証方式と平文認証方式とに区分して記憶手段に記憶しており、
前記外部装置が当該通信装置からの要求に応じて送信してくる、前記外部装置が対応している認証方式の情報を参照し、まず、前記記憶手段に記憶している暗号化認証方式と、前記外部装置が対応している認証方式とを順に比較し、一致するものがない場合に、前記記憶手段に記憶している平文認証方式と、前記外部装置が対応している認証方式とを順に比較し、これらの比較において最初に一致した認証方式を選択することによって、該外部装置と当該通信装置との双方が対応している認証方式のうち1つの認証方式を選択する認証方式選択手段を備え、
前記認証要求手段は、前記認証方式選択手段が選択した認証方式に応じた認証情報を前記外部装置に送信し、該認証方式での認証処理を要求する手段であることを特徴とする通信装置。
A communication device having communication means for communicating with an external device connected via a network, and authentication request means for transmitting authentication information to the external device and requesting authentication processing,
Information on the authentication method supported by the communication device is stored in the storage means, divided into an encrypted authentication method and a plaintext authentication method ,
The external device refers to information on an authentication method supported by the external device, which is transmitted in response to a request from the communication device, and first, an encryption authentication method stored in the storage unit, The authentication methods supported by the external device are compared in order, and if there is no match, the plaintext authentication method stored in the storage unit and the authentication method supported by the external device are sequentially processed. An authentication method selection means for selecting one authentication method from among the authentication methods supported by both the external device and the communication device by selecting an authentication method that matches first in these comparisons. Prepared,
The communication apparatus, wherein the authentication request means is means for transmitting authentication information corresponding to the authentication method selected by the authentication method selection means to the external device and requesting authentication processing in the authentication method.
前記外部装置がSMTPサーバであることを特徴とする請求項1に記載の通信装置。  The communication apparatus according to claim 1, wherein the external apparatus is an SMTP server. 前記外部装置がPOP3サーバであることを特徴とする請求項1に記載の通信装置。  The communication apparatus according to claim 1, wherein the external apparatus is a POP3 server. 前記外部装置がIMAP4サーバであることを特徴とする請求項1に記載の通信装置。  The communication apparatus according to claim 1, wherein the external apparatus is an IMAP4 server. 請求項1乃至4のいずれか一項に記載の通信装置において、
前記ネットワークを介して前記外部装置との間で画像情報を送受信する画像情報通信手段を備えることを特徴とする通信装置。
The communication device according to any one of claims 1 to 4,
A communication apparatus comprising image information communication means for transmitting and receiving image information to and from the external apparatus via the network.
請求項1乃至5のいずれか一項に記載の通信装置において、
前記認証方式選択手段が選択する認証方式の範囲を制限する指示を受け付ける選択指示受付手段を設け、
該選択指示受付手段は、該選択指示受付手段が受け付けた指示に従って、前記認証方式選択手段を、前記認証情報を暗号化して送信する暗号化認証方式の中から前記1つの認証方式を選択する第1のモード、前記認証情報を平文で送信する平文認証方式の中から前記1つの認証方式を選択する第2のモード、前記暗号化認証方式および前記平文認証方式の中から前記1つの認証方式を選択する第3のモードのいずれかに設定することを特徴とする通信装置。
The communication device according to any one of claims 1 to 5,
A selection instruction receiving means for receiving an instruction to limit the range of authentication methods selected by the authentication method selecting means;
The selection instruction receiving unit selects the one authentication method from among the encrypted authentication methods in which the authentication method selection unit encrypts and transmits the authentication information in accordance with the instruction received by the selection instruction receiving unit. A first mode, a second mode in which the one authentication method is selected from plaintext authentication methods in which the authentication information is transmitted in plaintext, the one authentication method from among the encryption authentication method and the plaintext authentication method. A communication apparatus that is set to one of the third modes to be selected.
請求項1乃至6のいずれか一項に記載の通信装置において、
前記認証要求手段の動作の有効/無効を設定する手段を設けたことを特徴とする通信装置。
The communication device according to any one of claims 1 to 6,
A communication apparatus comprising means for setting validity / invalidity of the operation of the authentication request means.
請求項1乃至のいずれか一項に記載の通信装置において、
前記認証要求手段が認証要求を行った場合、その認証要求に係る認証方式と、前記外部装置による認証結果とを記憶する記憶手段を設けたことを特徴とする通信装置。
The communication device according to any one of claims 1 to 7 ,
A communication device, comprising: a storage unit that stores an authentication method related to an authentication request and an authentication result of the external device when the authentication request unit makes an authentication request.
JP2003075256A 2003-03-19 2003-03-19 Communication device Expired - Fee Related JP4446330B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003075256A JP4446330B2 (en) 2003-03-19 2003-03-19 Communication device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003075256A JP4446330B2 (en) 2003-03-19 2003-03-19 Communication device

Publications (2)

Publication Number Publication Date
JP2004287492A JP2004287492A (en) 2004-10-14
JP4446330B2 true JP4446330B2 (en) 2010-04-07

Family

ID=33290614

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003075256A Expired - Fee Related JP4446330B2 (en) 2003-03-19 2003-03-19 Communication device

Country Status (1)

Country Link
JP (1) JP4446330B2 (en)

Families Citing this family (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7549048B2 (en) * 2004-03-19 2009-06-16 Microsoft Corporation Efficient and secure authentication of computing systems
KR101346734B1 (en) * 2006-05-12 2014-01-03 삼성전자주식회사 Multi certificate revocation list support method and apparatus for digital rights management
JP4245016B2 (en) 2006-08-18 2009-03-25 ブラザー工業株式会社 E-mail communication apparatus and computer program
JP4946429B2 (en) * 2006-12-27 2012-06-06 ブラザー工業株式会社 Information processing apparatus and information processing program
JP5103087B2 (en) * 2007-08-01 2012-12-19 シャープ株式会社 COMMUNICATION DEVICE, PROGRAM, AND RECORDING MEDIUM
JP2009064065A (en) * 2007-09-04 2009-03-26 Nec Corp Command execution device, command execution control method and program
JP5011208B2 (en) * 2008-05-21 2012-08-29 ソフトバンクモバイル株式会社 Mail processing system and communication terminal device
JP5011210B2 (en) * 2008-05-21 2012-08-29 ソフトバンクモバイル株式会社 Communications system
JP5011209B2 (en) * 2008-05-21 2012-08-29 ソフトバンクモバイル株式会社 Mail processing system and communication terminal device
JP2010092111A (en) * 2008-10-03 2010-04-22 Kawamura Electric Inc E-mail transmission terminal, e-mail authentication method setting method, and e-mail authentication method setting program
JP5517676B2 (en) * 2010-02-25 2014-06-11 三菱電機株式会社 Authentication apparatus, authentication method, and program
CN107070843A (en) * 2011-04-28 2017-08-18 交互数字专利控股公司 A kind of user equipment and method in a user device
US11991165B2 (en) 2018-04-06 2024-05-21 Nec Corporation Authentication method for next generation systems

Also Published As

Publication number Publication date
JP2004287492A (en) 2004-10-14

Similar Documents

Publication Publication Date Title
JP4446330B2 (en) Communication device
US8726009B1 (en) Secure messaging using a trusted third party
US8184312B2 (en) Image processing system with excellent operability
US8176329B2 (en) Scanned image disclosure apparatus, method and storage medium; electronic mail transmission apparatus, method and storage medium; and internet facsimile transmission apparatus
US7986784B2 (en) Image processing apparatus
US9516013B2 (en) Communication apparatus, method of controlling the same and storage medium for transmitting image file to a network address
JP2010278776A (en) Communications apparatus
JP2009060384A (en) System and device for image communication
JP2006222476A (en) E-mail terminal device
JP3640872B2 (en) Communication control device and communication control method
JP2007082208A (en) System, method, and program for safely transmitting electronic document between domains in terms of security
JP4367546B2 (en) Mail relay device
US6498837B1 (en) Method and apparatus capable of performing information providing operation with information security measures
JP6679867B2 (en) Communication system, communication device, and computer program
JP5120405B2 (en) E-mail communication apparatus and computer program
JP2007060467A (en) Internet facsimile relay device, program, method, and facsimile receiver
JP2008099058A (en) Network system
JP2008134985A (en) Network system
JP6686350B2 (en) Computer program and relay device
US8179544B2 (en) Image processing system, image processor and image processing program
JP4739248B2 (en) Transmitting apparatus, receiving apparatus, control method for transmitting apparatus, and control method for receiving apparatus
JP2005094414A (en) Network terminal device
JP5071261B2 (en) Image file transmission system and image file transmission method
JP4824044B2 (en) User terminal device
JP2004213534A (en) Network communication device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050707

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20081028

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20081104

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20081226

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090507

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090702

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20100112

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20100113

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20100113

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130129

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140129

Year of fee payment: 4

LAPS Cancellation because of no payment of annual fees