JP2007043382A - Frame processor - Google Patents
Frame processor Download PDFInfo
- Publication number
- JP2007043382A JP2007043382A JP2005224136A JP2005224136A JP2007043382A JP 2007043382 A JP2007043382 A JP 2007043382A JP 2005224136 A JP2005224136 A JP 2005224136A JP 2005224136 A JP2005224136 A JP 2005224136A JP 2007043382 A JP2007043382 A JP 2007043382A
- Authority
- JP
- Japan
- Prior art keywords
- message
- frame
- information
- received
- comparison
- 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.)
- Withdrawn
Links
Images
Landscapes
- Communication Control (AREA)
Abstract
Description
本発明は、ネットワークインタフェースを通じてイーサネット(登録商標)などのフレームを送受信処理する装置において、フレームを識別して、受信フレームの廃棄、通過、またはフレーム送出等の制御を行うフレーム処理装置に関する。 The present invention relates to a frame processing apparatus that performs frame transmission / reception processing such as Ethernet (registered trademark) through a network interface and performs control such as discarding, passing, or sending out a received frame by identifying the frame.
ネット家電の普及に伴い、UPnPに代表される、ユーザの手間を削減しつつ接続性を確保する制御プロトコルの実装が必須となってきているが、実装に際しては下記のような課題が想定される。
・ユーザの手間を減らす分、機器間でやり取りされるメッセージが増大する。
・トラヒック制御等の余計な機能の実装はコスト上制限されるため、制御フレームがバースト的に出力される。
・コスト面の制約から、ネット家電では高性能なプロセッサが使用できないため、このようなトラヒックの処理負荷が負担となる。
With the spread of Internet home appliances, it has become essential to implement a control protocol, such as UPnP, that secures connectivity while reducing user effort. However, the following issues are expected for implementation. .
-The amount of messages exchanged between devices increases by reducing the user's effort.
-Implementation of extra functions such as traffic control is limited in cost, so control frames are output in bursts.
-Due to cost constraints, high-performance processors cannot be used in internet home appliances, so this traffic processing load becomes a burden.
従来の技術としては、MACとIP層の間に簡易TCP/UDP処理を設けることでフレームの廃棄を行い、プロセッサの処理負荷を低減させるものがあった(例えば、特許文献1参照)。この従来技術では、MACとIP層の間に簡易TCP/UDP処理を設けることにより下記の処理を行う。まず、TCPの場合は簡易TCP/UDP処理が現在通信を行っているTCPポート番号と、次に受信すべきシーケンス番号、次に自ホストが送るべきシーケンス番号、相手に送出したが確認ACKが来ていないシーケンス番号とを入手する。そして、次に受信すべきシーケンス番号より小さい番号であれば再送データと判断し、そのデータは廃棄して次に受信すべき正しい番号を指定したACKを送出し、次に自ホストが送るべきシーケンス番号より小さい番号のACKであれば廃棄を行う。また、UDPの場合はプロセッサが処理対象としている宛先アドレス・ポート番号を入手し、対象外のフレームを廃棄する。このようにしてTCP及びUDP通信において、プロセッサが処理する必要のないフレームを廃棄して処理負荷を低減させていた。
UPnPの規定では、機器制御に利用する制御メッセージに、有効期間に関する情報を付与しており、UPnP対応機器はこの有効期間に基づいた間隔で同じ内容の制御メッセージを繰り返し送出する。制御メッセージは他のUPnP対応機器で受信され、発出したUPnP対応機器の制御情報が現在も有効であると認識する。 According to the UPnP regulations, information related to the valid period is given to the control message used for device control, and UPnP-compatible devices repeatedly transmit control messages having the same contents at intervals based on this valid period. The control message is received by another UPnP compatible device, and the control information of the issued UPnP compatible device is recognized to be still valid.
その他に、伝送路の状態により制御メッセージが他の機器に到達しないことを避けるため、上記有効期間に基づいた間隔で制御メッセージを送出する際に、予備として同じ内容の制御メッセージを続けて送出することが規定されている。しかし、予備としての制御メッセージは、UPnP対応機器にて上記有効期間に基づいた制御メッセージが正常に受信された場合、機器にとって不要なメッセージとなる。 In addition, in order to prevent the control message from reaching other devices due to the state of the transmission path, when the control message is transmitted at intervals based on the valid period, the control message having the same content is continuously transmitted as a spare. It is prescribed. However, the backup control message is an unnecessary message for the device when the UPnP-compatible device normally receives the control message based on the valid period.
現状のホームネットワークでは接続される機器が少ないため顕在化していないが、将来ネット家電の普及により接続機器台数が増大した場合、機器にとっては上記不要なメッセージを大量に処理しなければならないことになる。 Although there are few devices connected in the current home network, it has not become apparent, but if the number of connected devices increases due to the spread of Internet home appliances in the future, the devices will have to process a lot of the above unnecessary messages .
不要なメッセージはHTTP等のUDPより上位のアプリケーションレイヤのメッセージとして流れている。従って、プロセッサでアプリケーションレイヤの処理を行う通常の構成では、受信したイーサネットフレームに既に受信済みで不要なメッセージが含まれているか否かは、プロセッサにて通常のフレーム受信処理を行い、フレームからメッセージを取り出して受信済みのメッセージとの比較処理を行うまで判別できない。つまり、上記不要なメッセージが増大すると、処理する必要がないにも関わらずプロセッサの処理負荷が増大してしまう。 Unnecessary messages flow as messages in the application layer above UDP such as HTTP. Therefore, in a normal configuration in which processing of the application layer is performed by the processor, whether the received Ethernet frame has already been received and an unnecessary message is included is determined by performing normal frame reception processing by the processor, It cannot be determined until the message is taken out and compared with the received message. That is, when the number of unnecessary messages increases, the processing load on the processor increases even though there is no need for processing.
本発明は、上記事情に鑑みてなされたものであって、不要なメッセージの処理に関わるプロセッサの負荷を低減させることができるフレーム処理装置を提供することを目的とする。 The present invention has been made in view of the above circumstances, and an object of the present invention is to provide a frame processing apparatus that can reduce the load on the processor related to the processing of unnecessary messages.
本発明のフレーム処理装置は、通信装置において受信したフレームの中から判別した特定のフレームの通過又は廃棄を決定するフレーム処理装置であって、フレームのヘッダ情報及びペイロード情報を用いて抽出した、フレームに含まれる制御用のメッセージを分類する分類手段と、分類されたメッセージ毎に初めて受信したメッセージを比較の基準である基準メッセージとして、以降受信して分類されたメッセージに対して、前記基準メッセージとの一致比較を行うメッセージ一致比較手段と、前記基準メッセージと一致したメッセージに対して当該メッセージが既に受信済みである同一メッセージであるか否かを判定する冗長メッセージ判定手段と、を有し、前記冗長メッセージ判定手段が、前記基準メッセージを受信した時刻からの受信経過時間を測定する測定手段を備え、判定対象となるメッセージを受信するまでの受信経過時間が、時間に基づいて規定される判定基準値の範囲内にある場合には当該メッセージを既に受信済みであると判定して廃棄し、前記受信経過時間が前記判定基準値を超過している場合には前記基準メッセージをクリアし、前記測定手段が当該メッセージを受信した時刻から新たに受信経過時間を測定するものである。 A frame processing apparatus according to the present invention is a frame processing apparatus that determines whether a specific frame determined from among frames received by a communication apparatus is to be passed or discarded, and is extracted using frame header information and payload information. A classification means for classifying the control messages included in the message, and a message received for the first time for each classified message as a reference message for comparison, with respect to the messages received and classified thereafter, the reference message and Message match comparison means for performing a match comparison of the above, and redundant message determination means for determining whether the message is the same message that has already been received with respect to a message that matches the reference message, The redundant message determination means receives from the time when the reference message is received. A measuring means for measuring the elapsed time is provided, and if the elapsed reception time until receiving the message to be judged is within the range of the criterion value defined based on the time, the message has already been received. If it is determined that there is a message and then discarded, and the reception elapsed time exceeds the determination reference value, the reference message is cleared, and the measurement means newly measures the reception elapsed time from the time when the message is received. To do.
上記構成によれば、受信済みメッセージを含むフレームを廃棄する為、不要なメッセージの処理に関わるプロセッサの負荷を低減させることができる。 According to the above configuration, since the frame including the received message is discarded, it is possible to reduce the load on the processor related to the processing of unnecessary messages.
また、本発明のフレーム処理装置は、前記判定基準値が、予め外部より設定されるものである。 In the frame processing apparatus of the present invention, the determination reference value is set in advance from the outside.
上記構成によれば、不要なメッセージの処理に伴うプロセッサの負荷を低減させることができる。 According to the above configuration, it is possible to reduce the load on the processor accompanying the processing of unnecessary messages.
また、本発明のフレーム処理装置は、前記判定基準値が、メッセージから算出されるメッセージの有効期間情報を用いて算出される値、または、当該有効期間情報とヘッダ情報及びペイロード情報にて特定されたプロトコルの規定に基づき算出されるメッセージのリフレッシュ間隔情報とを用いて算出される値であるものである。 In the frame processing device of the present invention, the determination reference value is specified by a value calculated using message validity period information calculated from a message, or the validity period information, header information, and payload information. It is a value calculated using the message refresh interval information calculated based on the specified protocol.
上記構成によれば、制御メッセージ内容に応じてプロトコル規定に基づいた判定基準値の算出を行うことができ、冗長メッセージ判定手段による不要なメッセージの廃棄を確実に行ってプロセッサの処理負荷をより低減させることができる。 According to the above configuration, it is possible to calculate the determination reference value based on the protocol specification according to the control message content, and to reliably discard unnecessary messages by the redundant message determination means, thereby further reducing the processing load on the processor Can be made.
また、本発明のフレーム処理装置は、前記メッセージ一致比較手段が、前記基準メッセージと前記メッセージ一致比較手段の比較対象となる比較対象メッセージとを、ビット単位、オクテット単位、またはそれらの組み合わせによる比較、若しくは、ハッシュ演算等の一定長へのデータ変換演算を用いた比較を行い、一致不一致を判定するものである。 Further, in the frame processing device of the present invention, the message match comparison unit compares the reference message and the comparison target message to be compared by the message match comparison unit in units of bits, octets, or a combination thereof. Alternatively, a comparison using a data conversion operation to a certain length such as a hash operation is performed to determine a match / mismatch.
上記構成によれば、メッセージの全体一致による判定を行うことができ、メッセージの比較を短期間で行うことができる。 According to the above configuration, it is possible to make a determination based on the overall matching of messages, and to compare messages in a short period of time.
また、本発明のフレーム処理装置は、前記メッセージ一致比較手段が、前記比較に先立ち、メッセージ内の各情報要素フィールドのフォーマットが規定されたフォーマット情報を用いてメッセージ内の情報要素フィールドを並べ替え、前記基準メッセージのフォーマットと前記比較対象メッセージのフォーマットとを整合させるものである。 Further, in the frame processing device of the present invention, the message match comparison unit rearranges the information element fields in the message using format information in which the format of each information element field in the message is defined prior to the comparison, The format of the reference message is matched with the format of the message to be compared.
上記構成によれば、メッセージ内の情報要素の順序が入れ替わっていても一致比較を行うことができる。 According to the above configuration, even if the order of the information elements in the message is changed, the matching comparison can be performed.
また、本発明のフレーム処理装置は、前記メッセージ一致比較手段が、前記比較に先立ち、前記基準メッセージ及び前記比較対象メッセージそれぞれに含まれるスペース・タブ文字列を削除するものである。 In the frame processing apparatus of the present invention, the message match comparison unit deletes the space / tab character string included in each of the reference message and the comparison target message prior to the comparison.
上記構成によれば、メッセージ内のスペース・タブ数が異なっていても一致比較を行うことができる。 According to the above configuration, even if the number of spaces and tabs in the message is different, the matching comparison can be performed.
また、本発明のフレーム処理装置は、応答を行うべき受信フレームのヘッダ情報及びペイロード情報を検出する検出手段と、前記検出手段の検出結果から前記受信フレームに対応する送出フレームを特定する特定手段と、送出フレーム流から、特定した送出フレームを抽出する抽出手段と、抽出した送出フレームの複製フレームを作成して前記送出フレーム流に挿入する挿入手段と、を有する。 Further, the frame processing apparatus of the present invention includes a detecting unit that detects header information and payload information of a received frame to be responded, a specifying unit that specifies a transmission frame corresponding to the received frame from a detection result of the detecting unit, And extraction means for extracting the specified transmission frame from the transmission frame stream, and insertion means for creating a duplicate frame of the extracted transmission frame and inserting it into the transmission frame stream.
上記構成によれば、受信したメッセージに対応した応答メッセージを送出することができ、応答を行うためのプロセッサ処理負荷を低減させることができる。 According to the above configuration, a response message corresponding to the received message can be transmitted, and the processor processing load for performing the response can be reduced.
また、本発明のフレーム処理装置は、前記挿入手段が、前記複製フレームを前記送出フレーム流に挿入する際、予め設定された値に基づいたフレーム間隔を付与する付与手段を有するものである。 The frame processing apparatus according to the present invention further includes an adding unit that applies a frame interval based on a preset value when the inserting unit inserts the duplicated frame into the transmission frame stream.
上記構成によれば、複製した送出フレームと他のフレームとの間隔を調整することができ、他の機器がそれら送出フレームを受信する際の処理負荷を低減させることができる。 According to the above configuration, the interval between the duplicated transmission frame and other frames can be adjusted, and the processing load when other devices receive these transmission frames can be reduced.
本発明によれば、受信済みメッセージを含むフレームを廃棄する為、不要なメッセージの処理に関わるプロセッサの負荷を低減させることができる。 According to the present invention, since a frame including a received message is discarded, it is possible to reduce a load on a processor related to processing of an unnecessary message.
以下、添付図面を参照しながら本発明の実施形態に係るフレーム処理装置について詳細に説明する。 Hereinafter, a frame processing apparatus according to an embodiment of the present invention will be described in detail with reference to the accompanying drawings.
[実施の形態1]
図1は本発明の実施の形態1におけるフレーム処理装置の構成を示す図である。フレーム処理装置は、ネットワークインタフェース機能1000、フレーム通過・廃棄・応答機能1100、フレーム処理機能1200を備える。
[Embodiment 1]
FIG. 1 is a diagram showing a configuration of a frame processing apparatus according to
ネットワークインタフェース機能1000は、接続しているLAN等のネットワークよりイーサネットフレームを送受信する。フレーム通過・廃棄・応答機能1100は、ネットワークから受信したフレームのうち既に受信済みで不要なフレームを廃棄する。フレーム処理機能1200は、プロトコル処理やルーティング処理等を行い、これを必要に応じてネットワークインタフェース1000や図示しない他のネットワークインタフェースへ送信する。
The network interface function 1000 transmits and receives Ethernet frames from a connected network such as a LAN. The frame passing / discarding /
図2は、本発明の実施の形態1におけるフレーム処理装置の、フレーム通過・廃棄・応答機能の構成を示す図である。ネットワークインタフェース1000からの受信フレーム2000は、通過/廃棄判定部2600にて、ヘッダ分類機能判定対象外通過・廃棄通知2130、メッセージ種別分類機能判定対象外通過・廃棄通知2230、通過・廃棄判定結果2510の情報を用いて通過または廃棄が決定される。そして、その結果によりフレーム処理機能1200へ転送されるか、フレーム通過・廃棄・応答機能1100にて廃棄される。
FIG. 2 is a diagram showing a configuration of a frame passing / discarding / response function of the frame processing apparatus according to
次に、上記構成のフレーム通過・廃棄・応答機能の処理について説明する。 Next, the processing of the frame passing / discarding / response function configured as described above will be described.
はじめに、受信フレーム2000の情報がヘッダ分類部2100へ入力され、このフレーム通過・廃棄・応答機能にて予め設定された情報に基づきヘッダに基づく分類を行ってプロトコルを特定し、メッセージ分類の有無及び通過・廃棄を決定する。メッセージ分類の対象外とされた場合、ヘッダ分類部判定対象外通過・廃棄通知2130により通過/廃棄機能2600へ通知され、通過・廃棄の決定結果に基づき処理を行う。一方、メッセージ分類の対象とされた場合、対応するプロトコルのメッセージ種別分類部2200へ分類指示2110を用いて指示を行い、併せてペイロード情報2120を引き渡す。
First, information of the received
指示を受けたメッセージ種別分類部2200は、予め設定された情報に基づき、ペイロード情報に含まれるメッセージが、各プロトコルにて規定されているどのメッセージ種別に該当するかを、メッセージに含まれるヘッダ情報より特定し、メッセージ内容一致比較の有無及び通過・廃棄を決定する。メッセージ内容一致比較の対象外とされた場合、メッセージ種別分類部判定対象外通過・廃棄通知2230により、通過/廃棄機能2600へ通知され、通過・廃棄の決定結果に基づき処理を行う。一方、メッセージ内容一致比較対象とされた場合、対応する複数のメッセージ内容一致比較部2300へ比較指示2210を用いて指示を行い、併せてフォーマット情報/メッセージ内容/プロトコル規定2220を引き渡す。
Upon receiving the instruction, the message
指示を受けたそれぞれのメッセージ内容一致比較部2300は、特定のメッセージ種別における様々なメッセージ内容がどのメッセージに相当するかを判定するため、基準メッセージ情報に基づき、メッセージ内容の一致比較を行う。そして、不一致であった場合はその旨を不一致通知2310を用いて通過/廃棄判定機能2500へ通知する。一方、一致した場合は対応する冗長メッセージ判定部2400へ一致通知2320を用いて通知を行い、併せてメッセージ内容/プロトコル規定2330を引き渡す。
Receiving the instruction, each message content
通知を受けたそれぞれの冗長メッセージ判定部2400は、同一内容の複数のメッセージからどのメッセージが冗長であるかを判定するため、判定基準値を用いて受信したメッセージが冗長メッセージであるかの判定を行う。そして、冗長メッセージである場合は通過/廃棄判定部2500へ、通過・廃棄指示2410を用いて廃棄の指示を行う。一方、冗長メッセージでない場合は同様に通過の指示を行う。
Each redundant
通過/廃棄判定部2500は、受信した複数の通過・廃棄指示2410及び不一致通知2500を用いて通過/廃棄の判定を行い、通過・廃棄判定結果2510を用いて結果を通過/廃棄部2600へ通知する。
The pass / discard
通知を受けた通過/廃棄部2600は、ヘッダ分類部判定対象外通過・廃棄通知2130及びメッセージ種別分類部判定対象外通過・廃棄通知2230を共に用いて受信したフレームの通過/廃棄を決定して、対応した処理を行う。
The passing / discarding
次にUPnPを想定した上記各機能の動作の流れを説明する。 Next, the operation flow of the above functions assuming UPnP will be described.
全体の動作としては、ある機器からメッセージの意味としては同一であるが、フィールドの記述順序が異なるものや、不要な文字列が挿入されたものが混在し、且つメッセージそのものが同一内容である複数のNOTIFYメッセージがマルチキャストで送信され、これを自装置にて受信し、定期的に送出される状態通知メッセージと共に発出される予備メッセージの廃棄を行う。 As the overall operation, the meaning of the message from a certain device is the same, but there are a mixture of fields with different field description orders and those with unnecessary character strings inserted, and the message itself has the same contents. The NOTIFY message is sent by multicast, received by the own device, and the preliminary message issued together with the status notification message periodically sent is discarded.
図3は、本発明の実施の形態1におけるフレーム処理装置で、ネットワークより入力されるフレームフォーマットを示す図である。下位層から順にEthernet/IP/UDP/SSDPが適用されるフレームである。また、図4は、本発明の実施の形態1におけるフレーム処理装置で、ネットワークより入力されるフレームのトラヒックパターン及びペイロード情報の内容を示す図である。
FIG. 3 is a diagram showing a frame format input from the network in the frame processing apparatus according to
ここで、図1に示すフレーム処理装置に、図3に示すフォーマットのフレームが、図4に示すトラヒックパターンにて入力される場合について説明する。 Here, a case where a frame of the format shown in FIG. 3 is input to the frame processing apparatus shown in FIG. 1 in the traffic pattern shown in FIG.
ネットワークインタフェース1000はプリアンブルの検出によるフレーム認識を行い、自装置宛またはブロードキャスト・マルチキャストフレームを受信し、FCSを計算して正常なフレームを内部へ転送する機能を有する。入力されたフレームは、図3に示すEthernet宛先アドレスDA3000がマルチキャストを示すものであるため、ネットワークインタフェース機能1000にて受信され、プリアンブル3800が除去され、FCSの計算結果が正しければ正常フレームとしてFCS3900を除去したあとフレーム通過・廃棄・応答機能1100に転送される。転送されたフレームは、フレーム2000(図2参照)としてヘッダ分類部2100に入力される。
The
図5は、本発明の実施の形態1におけるフレーム処理装置の、フレーム通過・廃棄・応答機能におけるヘッダ分類部の内部構成を示す図である。分類テーブル5000には、各エントリにヘッダ情報として送信元MACアドレス、宛先MACアドレス、イーサタイプ、VLAN PID、プロトコル識別子、送信元IPv4アドレス、宛先IPv4アドレス、送信元IPv6アドレス、宛先IPv6アドレス、送信元ポート番号、宛先ポート番号といったパラメータ及び対応するメッセージ種別分類機能が予め設定されている。
FIG. 5 is a diagram showing an internal configuration of the header classification unit in the frame passing / discarding / response function of the frame processing apparatus according to
ここでは、エントリAのパラメータ値として宛先MACアドレス:01:00:5E:7F:FF:FA、送信元MACアドレス:MAC-A、イーサタイプ:0x0800、VALN PID:なし、プロトコル識別子:0x11、送信元IPv4アドレス:IP-A、宛先IPv4アドレス:239.255.255.250、送信元IPv6アドレス:なし、宛先IPv6アドレス:なし、送信元ポート番号:PortA、宛先ポート番号:1900、メッセージ種別分類機能:α(プロトコル:SSDP、送信元IPv4アドレス:IP-A)が設定されているものとする。 Here, as the parameter value of entry A, destination MAC address: 01: 00: 5E: 7F: FF: FA, source MAC address: MAC-A, ether type: 0x0800, VALN PID: none, protocol identifier: 0x11, transmission Source IPv4 address: IP-A, Destination IPv4 address: 239.255.255.250, Source IPv6 address: None, Destination IPv6 address: None, Source port number: PortA, Destination port number: 1900, Message type classification function: α (protocol : SSDP, source IPv4 address: IP-A).
入力されたフレーム2000は、ヘッダ分類機能5100にてヘッダ情報と、分類テーブル5000との比較が行われる。一致するエントリがある場合には対応する分類指示及びペイロード情報5200〜5500が出力され、一致するエントリがない場合には予め設定されている指示に従い、判定対象外通過・廃棄指示5600が出力され、その情報に基づき通過/廃棄部2600にて通過または廃棄の操作を行う。
The
この場合はエントリAに一致し、対応するメッセージ種別分類機能がαであるため、分類指示α5200がメッセージ種別分類部2200(図2参照)へ出力され、併せて入力フレーム2000のペイロード情報がペイロード情報α5300として出力される。
In this case, since it matches the entry A and the corresponding message type classification function is α, the classification instruction α5200 is output to the message type classification unit 2200 (see FIG. 2), and the payload information of the
図6は、本発明の実施の形態1におけるフレーム処理装置の、フレーム通過・廃棄・応答機能におけるメッセージ種別分類部の内部構成を示す図である。メッセージ種別分類部は、SSDP等の対応するプロトコル毎のメッセージ分類機能及びそれに付属するテーブルから構成される。
FIG. 6 is a diagram showing an internal configuration of a message type classification unit in the frame passing / discarding / response function of the frame processing apparatus according to
ここではメッセージ分類機能6000(SSDP用)に関する部分を説明するが、他のメッセージ分類機能についても動作は同じである。 Here, the part related to the message classification function 6000 (for SSDP) will be described, but the operation is the same for other message classification functions.
分類テーブル6020には、各エントリにプロトコル毎のメッセージ識別情報としてUPnPにおけるNOTIFYやM-SERCHメソッドのリクエスト行といったパラメータが予め設定され、プロトコル規定情報6010にはプロトコル毎の規定情報として、各メッセージのフォーマット情報、有効期間、リフレッシュ間隔、繰り返し回数といったパラメータが予め設定されているものとする。ここでは、分類テーブル6020のエントリAとしてNOTIFYメソッドを表す『NOTIFY * HTTP/1.1』が設定され、プロトコル規定情報6010のエントリAとしてフォーマット情報『NOTIFY\r\n、HOST:\r\n、CACHE-CONTROL:\r\n、LOCATION:\r\n、NT:\r\n、NTS:\r\n、SERVER:\r\n、USN:\r\n、\r\n』、有効期間:120[sec]、リフレッシュ間隔:1/4、繰り返し回数:2、有効期間ヘッダ:CACHE-CONTROL:max-age=、及び対応する比較指示α-A6001が設定されているものとする。
In the classification table 6020, parameters such as NOTIFY in UPnP and the request line of the M-SERCH method are preset in each entry as message identification information for each protocol. Assume that parameters such as format information, valid period, refresh interval, and number of repetitions are set in advance. Here, “NOTIFY * HTTP / 1.1” representing the NOTIFY method is set as entry A of the classification table 6020, and format information “NOTIFY \ r \ n, HOST: \ r \ n, CACHE” is set as entry A of the
メッセージ分類機能6000は、入力された分類指示に従い起動される。併せて入力されたペイロード情報において先頭から最初の行終了コード『\r\n』までの文字列が抽出され、これをメッセージ種別識別情報として、予め設定された分類テーブル6020との比較が行われる。そして、一致するエントリがある場合には、そのエントリに設定された対応するメッセージ種別の比較指示が出力され、対応するメッセージ内容一致比較機能2300(図2参照)が起動される。一方、一致するエントリがない場合には判定対象外通知が対象外判定機能6200へ通知され、ここで予め設定されている指示に従い、判定対象外通過・廃棄指示6201が出力され、その情報に基づき通過/廃棄機能2600にて通過または廃棄の操作が行われる。
The
この場合のペイロード情報5300は、エントリAに一致するので、対応する比較指示6001がメッセージ内容一致比較機能2300へ出力され、併せてフォーマット情報6002、メッセージ内容6003、プロトコル規定情報6004が出力される。
Since the
図7は、本発明の実施の形態1におけるフレーム処理装置の、フレーム通過・廃棄・応答機能におけるメッセージ内容一致比較部の内部構成を示す図である。メッセージ内容一致比較部は、メッセージ種別毎に複数のメッセージ内容一致比較機能から構成され、一つの比較指示に対して複数のメッセージ内容一致比較機能が動作する。ここではメッセージ内容一致比較機能7000に関する部分を説明するが、他のメッセージ内容一致比較機能についても動作は同様である。
FIG. 7 is a diagram showing an internal configuration of the message content match comparison unit in the frame passing / discarding / response function of the frame processing apparatus according to
基準メッセージ情報には、過去に分類された『NOTIFY * HTTP/1.1』等の同一のメッセージ識別情報を持つがそれぞれ他のフィールドの内容が異なるメッセージの情報が登録されている。ここでは基準メッセージ情報7020として、図4のメッセージ4120に示す内容が登録されているものとする。
In the reference message information, information of messages having the same message identification information such as “NOTIFY * HTTP / 1.1” classified in the past but having different contents in other fields is registered. Here, it is assumed that the content shown in the
比較指示6001を受けたメッセージ内容一致比較機能7010は、受信したフォーマット情報6002及びメッセージ内容6003を用いて、それぞれ基準メッセージ7020との比較を行う。
The message content
比較の際には、まず、基準メッセージ7020を先頭から検索してスペース及びタブに該当するキャラクタコードの削除を行い、これをメッセージ終了コードである『\r\n\r\n』が発見されるまで行う。これにより、単にスペースやタブ数の違いによって不一致判定が行われる事態を防止することができる。
In the comparison, first, the
次に、フォーマット情報6002を先頭から検索し、行終了コードである『\r\n』の次から『\r\n』が発見されるまでの文字列を取得し2行目の『HOST:』を得る。これを1回目の比較基準とし、スペース及びタブに該当するキャラクタコードの削除後の基準メッセージを先頭から検索し、行終了コードである『\r\n』の次から始まる文字列を次の行終了コードである『\r\n』まで取得して『HOST: 239.255.255.250:1900』を得る。これを比較基準文字列『HOST:』と先頭部分を比較する。
Next, the
この場合は同一の文字列であるため、同様の処理を3行目以降も行ってこれをフォーマット情報にてメッセージ終了コード『\r\n\r\n』が発見されるまで繰り返す。一方、一致しない場合は基準メッセージにおける次の『\r\n』までの文字列を取得して比較を繰り返し行い、一致した場合はその文字列を2行目としてメッセージ内の行を入れ替えてフォーマット情報の3行目以降について同じ処理を行う。メッセージ終了コードである『\r\n\r\n』が発見されるまで一致しなかった場合は、比較対象外メッセージと判定して不一致通知7002を出力して処理を終了する。
In this case, since they are the same character string, the same processing is performed for the third and subsequent lines, and this is repeated until the message end code “\ r \ n \ r \ n” is found in the format information. On the other hand, if they do not match, the character string up to the next “\ r \ n” in the reference message is acquired and compared, and if it matches, the character string is used as the second line and the lines in the message are swapped and formatted. The same processing is performed for the third and subsequent lines of information. If the message end code “\ r \ n \ r \ n” does not match until it is found, it is determined that the message is not to be compared, a
上記処理をスペース及びタブに該当するキャラクタコード削除後のメッセージ内容についても同様に行う。これにより、単に行の入れ替わりによって不一致判定が行われる事態を防止することができる。 The above processing is performed in the same manner for the message contents after deleting the character code corresponding to the space and tab. As a result, it is possible to prevent a situation where a mismatch determination is simply made by changing the rows.
以上の方法でフォーマット整形を行った基準メッセージとメッセージ内容とは、ビット単位、オクテット単位、またはそれらの組み合わせ、ハッシュ演算等の一定長へのデータ変換演算、などを用いて比較される。 The reference message that has been formatted by the above method and the message content are compared using a bit unit, an octet unit, or a combination thereof, a data conversion operation to a certain length such as a hash operation, and the like.
図4のメッセージ4120、4220、4320、4420の内容が入力された場合にはいずれも一致と判定され、冗長メッセージ判定部2400へ一致通知7003が出力され、併せて基準メッセージの内容7001が出力される。
When the contents of the
尚、不一致の場合は比較エントリ機能7200へ不一致通知7002が出力される。比較エントリ機能7200ではそれらの結果を不一致結果収集機能7210で集計し、全てのメッセージ種別の内容一致比較結果が不一致であれば、比較対象メッセージではないとして通過/廃棄判定部2500へ不一致通知7201を出力する。また、同じ情報をエントリ登録・更新・クリア機能7230へ出力する。これを受けたエントリ登録・更新・クリア機能7230は、エントリ情報保持機能7220を用いて空きエントリまたは更新可能なエントリを有するメッセージ種別内容一致比較機能を検索して受信したメッセージ内容を登録・更新して次回同様のメッセージ内容を受信した場合に一致比較の対象とする。
If there is a mismatch, a
図8は、本発明の実施の形態1におけるフレーム処理装置の、フレーム通過・廃棄・応答機能における冗長メッセージ判定部の内部構成を示す図である。冗長メッセージ判定部は、メッセージ内容一致比較機能に対応した複数の冗長メッセージ判定機能から構成され、一つのメッセージ内容一致比較機能に一つの冗長メッセージ判定機能が対応する。ここでは冗長メッセージ判定機能8000に関する部分を説明するが、他の冗長メッセージ判定機能についても動作は同様である。
FIG. 8 is a diagram showing an internal configuration of the redundant message determination unit in the frame passing / discarding / response function of the frame processing apparatus according to
判定基準値抽出・演算機能8010は受信した基準メッセージ内容7001からプロトコル規定情報6004に基づき必要な情報を抽出し、他の規定情報と併せて判定基準値8011を算出する。
The determination reference value extraction / calculation function 8010 extracts necessary information from the received
ここでは、基準メッセージ内容がメッセージ4120であり、プロトコル規定情報にてリフレッシュ間隔:1/4、有効期間ヘッダ:CACHE-CONTROL:max-age=、との情報を得て、基準メッセージ内容を先頭から検索し、行終了コードである『\r\n』の次から『\r\n』が発見されるまでの文字列を取得する。これを1回目の比較対象とし、この文字列の先頭部分が『CACHE-CONTROL:max-age=』であるかを比較する。
Here, the reference message content is the
一致する場合はその後に続く文字列を取得してそれを有効期間とするが、一致しない場合は基準メッセージにおける次の『\r\n』までの文字列を取得して連続して比較を行って、有効期間を取得する。 If there is a match, the subsequent character string is obtained and used as the valid period, but if it does not match, the character string up to the next “\ r \ n” in the reference message is obtained and compared continuously. To obtain the validity period.
上記をメッセージ4120に適用すると、有効期間として120が得られ、これとリフレッシュ間隔:1/4を乗算して判定基準値8011として30[sec]が得られる。
When the above is applied to the
ここで、図4に示す複数のフレームを受信した場合、PacketA4100を受信すると前段の判定機能により一致通知7003が出力される。このタイミングで判定基準値比較機能8020にて判定基準値8011(30[sec])とタイマ8030の出力値とを比較する。PacketA4100受信以前は充分時間が空いていると考えると、この場合は判定基準値よりタイマ値が大きいため、判定基準値比較機能8020はこれが新規に受信したメッセージであると判定し、通過指示8021を出力してタイマリセット指示8023をタイマ8030に出力してタイマを初期値に戻す。続いてPacketB 4200を受信すると、これも前段の判定機能により一致通知7003が出力される。このタイミングで判定基準値比較機能8020にて判定基準値8011(30[sec])とタイマ8030の出力値とが比較される。
Here, when a plurality of frames shown in FIG. 4 are received, a
PacketA4100とPacketB4200の時間間隔は4110(0.02[sec])であり判定基準値より小さいため、判定基準値比較機能8020はこれを既に受信済みで不要な冗長メッセージと判定し、廃棄指示8022を出力する。続いてPacketC 4300を受信すると、前段の判定機能により一致通知7003が出力される。このタイミングで判定基準値比較機能8020にて判定基準値8011(30[sec])とタイマ8030の出力値とを比較する。PacketA 4100とPacketC 4300の時間間隔は4110(0.02[sec])+4210(31[sec])であり判定基準値より大きいため、判定基準値比較機能8020はこれを新規に受信したメッセージであると判定し、通過指示8021を出力してタイマリセット指示8023をタイマ8030に出力してタイマを初期値に戻す。
Since the time interval between
続いてPacketD 4400を受信すると、これも前段の判定機能により一致通知7003が出力される。このタイミングで判定基準値比較機能8020にて判定基準値8011(30[sec])とタイマ8030の出力値とを比較する。PacketC 4300とPacketD 4400の時間間隔は4310(0.02[sec])であり判定基準値より小さいため、判定基準値比較機能8020はこれを既に受信済みで不要な冗長メッセージと判定し、廃棄指示8022を出力する。以上の方法で冗長メッセージを判定し、その結果を出力する。
Subsequently, when
尚、この形態では判定基準値抽出機能8010がプロトコル規定情報を用いて判定基準値を算出する例を示したが、この値を外部設定8012を用いて設定してもよい。
In this embodiment, an example in which the determination reference value extraction function 8010 calculates the determination reference value using the protocol definition information is shown. However, this value may be set using the
図9は、本発明の実施の形態1におけるフレーム処理装置の、フレーム通過・廃棄・応答機能における通過・廃棄判定部の内部構成を示す図である。通過・廃棄判定部はメッセージ種別毎の通過・廃棄判定機能から構成され、一つのメッセージ種別毎に一つの通過・廃棄判定機能が対応する。ここでは通過・廃棄判定機能9000について説明するが、他の通過・廃棄判定機能についても動作は同様である。
FIG. 9 is a diagram showing an internal configuration of the pass / discard determination unit in the frame pass / discard / response function of the frame processing apparatus according to
通過・廃棄判定機能9000は、比較指示6001にて起動される。不一致通知7201を受信した場合は比較対象外のメッセージ内容であると判定し、冗長メッセージか否かの判定が出来ないとして判定結果9005を通過として出力する。通過指示8021〜8121のいずれかを受信した場合、メッセージ種別及び内容が一致するメッセージにおける新規に受信したメッセージであると判定し、判定結果9005を通過として出力する。廃棄指示8022〜8122のいずれかを受信した場合、メッセージ種別及び内容が一致するフレームの中で既に受信しており不要な冗長メッセージであると判定し、判定結果9005を廃棄として出力する。
The pass / discard
これを受信した最終判定機能9200は、その結果を通過廃棄判定結果9201として、通過/廃棄部2600へ出力する。通過/廃棄部2600はこの情報に基づき、実際のフレームの通過/廃棄制御を行う。
The
以上のように、実施の形態1のフレーム処理装置によれば、UPnPのNOTIFYメソッドに代表される、メッセージ内容が同一にも関わらず既に受信済みで冗長なメッセージが混在するトラヒックにおいて、不要なメッセージのみを判定してこれを取り除くことができ、フレーム処理機能の負荷を低減させることができる。また、ホームネットワークに接続されているUPnP対応機器により定期的に送出される状態通知用のメッセージは処理を行い、状態通知用メッセージの予備として送出される不要なメッセージは廃棄することができ、従って、各UPnP機器の最新の状態を保持しつつ、不要なメッセージの処理に伴うプロセッサの負荷を低減させることができる。 As described above, according to the frame processing apparatus of the first embodiment, unnecessary messages are represented in traffic in which redundant messages are already received even though the message contents are the same, as represented by UPnP NOTIFY method. This can be determined and removed, and the load on the frame processing function can be reduced. Also, status notification messages periodically sent by UPnP compatible devices connected to the home network can be processed, and unnecessary messages sent as spare status notification messages can be discarded. In addition, it is possible to reduce the load on the processor accompanying unnecessary message processing while maintaining the latest state of each UPnP device.
[実施の形態2]
実施の形態2のフレーム処理装置は、実施の形態1のそれに機能を付加した形態となっているため、以降の説明では実施例1にて説明済みの構成要素については同じ符号を付与し、説明を省略するものとする。
[Embodiment 2]
Since the frame processing apparatus according to the second embodiment has a form in which a function is added to that of the first embodiment, the same reference numerals are given to the components already described in the first embodiment in the following description. Shall be omitted.
実施の形態2のフレーム処理装置は、実施の形態1のフレーム処理装置と同様に、ネットワークインタフェース機能1000、フレーム通過・廃棄・応答機能1100、フレーム処理機能1200を備える。
Similar to the frame processing apparatus of the first embodiment, the frame processing apparatus of the second embodiment includes a
図10は、本発明の実施の形態2におけるフレーム処理装置の、フレーム通過・廃棄・応答機能の構成を示す図である。送信フレームに対する構成要素についてのみ説明を行う。まず、送信フレームにおける構成要素11100〜111000は受信フレームに対する構成要素における、通過廃棄指示2410にて『廃棄』の指示が出力されるまでは動作を停止しており、通過/挿入部11600は送信フレーム11000を常に通過させる。
FIG. 10 is a diagram illustrating a configuration of a frame passing / discarding / response function of the frame processing device according to the second embodiment of the present invention. Only the components for the transmission frame will be described. First, the
通信廃棄指示2410にて『廃棄』指示が出力された場合、その直前に通過した同一内容の受信フレームに対応して、フレーム処理機能1200から挿入対象となるフレームが送出される。このため、この情報が起動・停止機能111000に通知され、この機能にて各構成要素11100〜11900が起動される。起動・停止機能111000は予め適切な値を保持または外部から設定された値を保持しており、各構成要素起動後一定時間が経過すると挿入対象とするフレームがないとして各構成要素の機能を停止させる。また、挿入完了通知11610が出力されると、挿入対象フレームが発見され、挿入処理を完了したとして各構成要素の機能を停止させる。
When the “discard” instruction is output in the communication discard
ヘッダ分類情報作成機能11700は、起動後、廃棄の対象となっている受信フレーム2000に関するヘッダ情報11710を受信ヘッダ分類部2100より入手する。この情報に基づき、受信フレームに対応する送信ヘッダ情報を作成してこのヘッダを有するフレームを挿入対象と判定するようヘッダ分類部11100に設定する。
The header classification information creation function 11700 obtains, from the reception
メッセージ種別分類情報作成機能11800は、起動後廃棄の対象となっている受信フレーム2000に関するフォーマット情報11810を受信メッセージ種別分類部2200が出力するフォーマット情報2220より入手する。この情報に基づき、受信メッセージに対応する送信メッセージ種別情報を作成してこのメッセージ種別を有するフレームを挿入対象と判定するようメッセージ種別分類部11200に設定する。
The message type classification information creation function 11800 obtains from the
メッセージ内容分類情報作成機能11900は、起動後廃棄の対象となっている受信フレーム2000に関するメッセージ内容11910を受信メッセージ種別分類部2200が出力するメッセージ内容2220より入手する。この情報に基づき、受信メッセージに対応する送信メッセージ内容情報を作成してこのメッセージ内容を有するフレームを挿入対象と判定するようメッセージ内容一致比較部11300に設定する。
The message content classification information creation function 11900 obtains the
送信フレーム11000は既に受信済みで不要な冗長メッセージとして廃棄される受信フレーム2000より以前に受信されたフレームに対する応答メッセージか否かを判定される。このため、フレーム処理機能から転送された送信フレーム11000の情報はヘッダ分類部11100へ入力される。そして、この機能にてヘッダ分類情報作成機能11700により設定された情報に基づきヘッダに基づく分類を行って、対象となるヘッダを有するフレームかを判断し、メッセージ分類の有無及び通過を決定する。メッセージ分類の対象外とされた場合、ヘッダ分類部判定対象外通過通知11130により通過/挿入部11600へ通知され、通過処理を行う。一方、メッセージ分類の対象とされた場合、対応するプロトコルのメッセージ種別分類部11200へ分類指示11110を用いて指示を行い、併せてペイロード情報11120を引き渡す。
It is determined whether the
指示を受けたメッセージ種別分類部11200は、メッセージ種別分類情報作成機能11800により設定された情報に基づき、ペイロード情報に含まれるメッセージが、プロトコルにて規定されているどのメッセージ種別に該当するかを、メッセージに含まれるヘッダ情報により特定し、メッセージ内容一致比較の有無及び通過を決定する。メッセージ内容一致比較の対象外とされた場合、メッセージ種別分類部判定対象外通過通知11230により、通過/挿入機能11600へ通知され処理を行う。一方、メッセージ内容一致比較対象とされた場合、メッセージ内容一致比較部11300へ比較指示11210を用いて指示を行い、併せてフォーマット情報/メッセージ内容/プロトコル規定11220を引き渡す。
Upon receiving the instruction, the message
指示を受けたメッセージ内容一致比較部11300は、特定のメッセージ種別における様々なメッセージ内容がどのメッセージに相当するかを判定する。このため、メッセージ内容一致比較部11300は、メッセージ種別分類情報作成機能11900により設定された基準メッセージ情報に基づき、メッセージ内容の一致比較を行い、一致または不一致の判定結果を一致通知11320または不一致通知11310を用いて通過/挿入判定機能11500へ通知する。
Upon receiving the instruction, the message content
通知を受けた通過/挿入判定部11500は、受信した一致通知11320及び不一致通知11310を用いて通過/挿入の判定を行い、通過・挿入判定結果11510を用いてその結果を通過/挿入部11600へ通知する。
Upon receipt of the notification, the pass /
通知を受けた通過/挿入部11600は、ヘッダ分類部判定対象外通過通知11130及びメッセージ種別分類部判定対象外通過通知11230を共に用いて受信したフレームの通過または挿入を決定する。通過時には受信したフレームをそのまま通過させ、挿入時には受信したフレームを複製して送出する処理を行い、廃棄された受信フレームに対応する処理が終了したとして、挿入完了通知11610を起動・停止機能111000へ出力して各構成要素を停止させ、再び受信フレームの廃棄が行われるまで待機する。
Upon receipt of the notification, the passing / inserting unit 11600 determines the passing or insertion of the received frame by using both the header classification unit non-target determination notification 11130 and the message type classification unit
次にUPnPを想定した上記各機能の動作の流れを説明する。 Next, the operation flow of the above functions assuming UPnP will be described.
図11は、本発明の実施の形態2におけるフレーム処理装置で、ネットワークより入力されるフレームフォーマットを示す図である。下位層から順にEthernet/IP/UDP/SSDPが適用されるフレームである。また、図12は本発明の実施の形態2におけるフレーム処理装置で、ネットワークより入力されるフレームのトラヒックパターン及びペイロード情報の内容を示す図である。ペイロード情報は、ペイロード情報3700(PacketA/B)及びペイロード情報12700(PacketC/D)である。
FIG. 11 is a diagram showing a frame format input from the network in the frame processing apparatus according to
ここで、実施の形態2のフレーム処理装置に、図11に示す受信フレームが、図12に示すトラヒックパターンで入力される場合について説明する。 Here, a case where the received frame shown in FIG. 11 is input to the frame processing apparatus of the second embodiment with the traffic pattern shown in FIG. 12 will be described.
受信時の処理の詳細については実施例1で述べたので省略するが、結果として、図12に示すPacketB13200が冗長メッセージとして廃棄される。
Details of the processing at the time of reception have been described in the first embodiment and will be omitted. As a result,
この廃棄は通過・廃棄指示2410として起動・停止機能111000へ出力され(図10参照)、各機能が起動される。
This discard is output as a pass / discard
ヘッダ分類情報作成機能11700は、ヘッダ分類部2100よりヘッダ情報11710として廃棄対象としたPacketBに対応するエントリAのパラメータ値として、図11のフォーマット3000〜3600に示すように、宛先MACアドレス:01:00:5E:7F:FF:FA、送信元MACアドレス:MAC-A、イーサタイプ:0x0800、VALN PID:なし、プロトコル識別子:0x11、送信元IPv4アドレス:IP-A、宛先IPv4アドレス:239.255.255.250、送信元IPv6アドレス:なし、宛先IPv6アドレス:なし、送信元ポート番号:PortA、宛先ポート番号:1900、メッセージ種別分類機能:α(プロトコル:SSDP、送信元IPv4アドレス:IP-A)を取得して、対応する送信フレームの分類情報を作成する。
As shown in the
具体的には、アドレスに関する各パラメータの送信元を送信先とし、送信元として予め保有する自装置のパラメータを設定し、ポート番号に関しては送信元と送信先を入れ替える。 Specifically, the transmission source of each parameter relating to the address is set as the transmission destination, the parameters of the own apparatus held in advance as the transmission source are set, and the transmission source and the transmission destination are switched for the port number.
このようにして送信フレームの分類情報として、図11の12000〜12600に示すように、宛先MACアドレス:MAC-A、送信元MACアドレス:MAC-B、イーサタイプ:0x0800、VALN PID:なし、プロトコル識別子:0x11、送信元IPv4アドレス:IP-B、宛先IPv4アドレス:IP-A、送信元IPv6アドレス:なし、宛先IPv6アドレス:なし、送信元ポート番号:1900、宛先ポート番号:PortA、メッセージ種別分類機能:α(プロトコル:SSDP、送信元IPv4アドレス:IP-B)を取得する。 In this way, as shown in 12000 to 12600 in FIG. 11, as transmission frame classification information, destination MAC address: MAC-A, transmission source MAC address: MAC-B, ether type: 0x0800, VALN PID: none, protocol Identifier: 0x11, Source IPv4 address: IP-B, Destination IPv4 address: IP-A, Source IPv6 address: None, Destination IPv6 address: None, Source port number: 1900, Destination port number: PortA, Message type classification Function: Acquires α (protocol: SSDP, source IPv4 address: IP-B).
図13は、本発明の実施の形態2におけるフレーム処理装置の、フレーム通過・廃棄・応答機能におけるヘッダ分類部の内部構成を示す図である。ヘッダ分類情報作成機能11700により作成された情報は、外部設定情報14400として分類テーブル14000に設定される。この情報に基づき入力されたフレーム11000は、分類テーブル14000との比較が行われ、一致する場合には分類指示14200及びペイロード情報14300が出力され、一致するエントリがない場合には判定対象外通過指示14600が出力される。そして、この情報がヘッダ分類部判定対象外通過通知11130として通過/挿入部11600に通知され、この機能にて通過の操作を行う。
FIG. 13 is a diagram showing an internal configuration of the header classification unit in the frame passing / discarding / response function of the frame processing apparatus according to
この場合は一致するため、分類指示14200がメッセージ種別分類部11200(図10参照)へ出力され、併せて入力フレーム11000のペイロード情報がペイロード情報11120として出力される。
In this case, since they match, the
メッセージ種別分類情報作成機能11800は、メッセージ種別分類部2200よりフォーマット情報として、廃棄対象としたPacketBに対応するフォーマット情報11810『M-SEARCH\r\n、Host:\r\n、Man:\r\n、MX:3\r\n、\r\n』を取得する。この情報において先頭から最初の行終了コード『\r\n』までの文字列が抽出され、『M-SERCH』を取得する。
The message type classification information creation function 11800 uses the format information 11810 “M-SEARCH \ r \ n, Host: \ r \ n, Man: \ r corresponding to the packet B to be discarded as format information from the message
この情報に基づき、予め設定された、プロトコル規定によるメッセージ対応情報に基づいた応答メッセージ種別及びフォーマット情報を作成する。具体的には、『M-SERCH』に対応するのはプロトコル規定により『HTTP/1.1 200 OK』であるのでこれをメッセージ種別識別情報として分類テーブル15020に外部設定情報15400として設定する。併せてフォーマット情報としてM-SERCHの応答としてプロトコル規定にて定められているフォーマット『HTTP/1.1 200 OK\r\n、CACHE-CONTROL:\r\n、Location:\r\n、SERVER:\r\n、ST:\r\n、EXT:\r\n、USN:\r\n、\r\n』を分類テーブル15020に外部設定情報15400として設定する。 Based on this information, a response message type and format information based on preset message correspondence information based on the protocol is created. Specifically, since “HTTP / 1.1 200 OK” corresponds to “M-SERCH” according to the protocol, it is set as message type identification information as external setting information 15400 in the classification table 15020. In addition, the format specified in the protocol specification as the M-SERCH response as the format information "HTTP / 1.1 200 OK \ r \ n, CACHE-CONTROL: \ r \ n, Location: \ r \ n, SERVER: \ r \ n, ST: \ r \ n, EXT: \ r \ n, USN: \ r \ n, \ r \ n "are set as the external setting information 15400 in the classification table 15020.
図14は、本発明の実施の形態2におけるフレーム処理装置の、フレーム通過・廃棄・応答機能におけるメッセージ種別分類部の内部構成を示す図である。メッセージ種別分類情報作成機能11800(図10参照)により作成された情報は、外部設定情報15400として分類テーブル15020に設定される。
FIG. 14 is a diagram showing an internal configuration of the message type classification unit in the frame passing / discarding / response function of the frame processing apparatus according to
メッセージ分類機能15000は、入力された分類指示に従い起動される。併せて入力されたペイロード情報において先頭から最初の行終了コード『\r\n』までの文字列が抽出される。これをメッセージ種別識別情報として、予め設定された分類テーブル15020との比較が行われ、一致する場合には、比較指示が出力され、対応するメッセージ一致比較手段11300(図10参照)が起動される。一方、一致するエントリがない場合には判定対象外通過指示15201が出力され、この情報がメッセージ種別分類部判定対象外通過通知11230(図10参照)として通過/挿入部11600に通知され、この機能にて通過の操作を行う。
The
この場合のペイロード情報14300は一致し、比較指示15001がメッセージ一致比較手段11300へ出力され、併せてフォーマット情報15002、メッセージ内容15003が出力される。
In this case, the
メッセージ内容分類情報作成機能11900(図10参照)は、メッセージ種別分類部2200よりメッセージ内容として、廃棄対象としたPacketBに対応するメッセージ内容11910を取得する。具体的な内容は図12のメッセージ13220に示す通りである。
The message content classification information creation function 11900 (see FIG. 10) acquires the
この情報に基づき、予め設定された、プロトコル規定によるメッセージ対応情報及び自装置の情報に基づいた基準応答メッセージを作成する。具体的には、メッセージ種別分類部から出力された、応答メッセージのフォーマット情報『HTTP/1.1 200 OK\r\n、CACHE-CONTROL:\r\n、Location:\r\n、SERVER:\r\n、ST:\r\n、EXT:\r\n、USN:\r\n、\r\n』に対して、廃棄されたメッセージ内容『M-SEARCH * HTTP/1.1\r\n、Host:239.255.255.250:1900\r\n、ST:urn:schemas-upnp-org:device:InternetGatewayDevice:1\r\n、Man:"ssdp:discover"\r\n、MX:3\r\n、\r\n』及び自装置にて予め設定された情報から必要な情報を抽出して各パラメータを挿入する。 Based on this information, a reference response message based on preset message correspondence information based on the protocol and information on the device itself is created. Specifically, the response message format information output from the message type classification part “HTTP / 1.1 200 OK \ r \ n, CACHE-CONTROL: \ r \ n, Location: \ r \ n, SERVER: \ r \ n, ST: \ r \ n, EXT: \ r \ n, USN: \ r \ n, \ r \ n ", discarded message content" M-SEARCH * HTTP / 1.1 \ r \ n , Host: 239.255.255.250: 1900 \ r \ n, ST: urn: schemas-upnp-org: device: InternetGatewayDevice: 1 \ r \ n, Man: "ssdp: discover" \ r \ n, MX: 3 \ r Necessary information is extracted from “\ n, \ r \ n” and information set in advance by the own device, and each parameter is inserted.
まず、『CACHE-CONTROL:』には自装置にて予め設定された情報『max-age=120』を挿入し、『Location:』には同じく自装置にて予め設定された情報『IGD-HTTP/1.1 UPnP/1.0 UPnP-Device-Host/1.0』を挿入し、『ST:』にはメッセージ内容から抽出した『urn:schemas-upnp-org:device:InternetGatewayDevice:1』を挿入し、『EXT:』には自装置にて予め設定された情報『』(null)を挿入し、『USN:』には自装置にて予め設定された情報『uuid:0208591c-00dc0301::』及びメッセージ内容から抽出した『urn:schemas-upnp-org:device:InternetGatewayDevice:1』を挿入する。これを基準メッセージ情報16020へ外部設定情報16202として設定する。
First, the information “max-age = 120” preset in the own device is inserted in “CACHE-CONTROL:”, and the information “IGD-HTTP” preset in the own device is also inserted in “Location:”. /1.1 UPnP / 1.0 UPnP-Device-Host / 1.0 '', insert `` urn: schemas-upnp-org: device: InternetGatewayDevice: 1 '' extracted from the message content into `` ST: '', and `` EXT: ”Is inserted from the information“ ”(null) preset in the own device, and“ USN: ”is extracted from the information“ uuid: 0208591c-00dc0301 :: ”preset in the own device and the message contents Insert "urn: schemas-upnp-org: device: InternetGatewayDevice: 1". This is set as the
図15は、本発明の実施の形態2におけるフレーム処理装置の、フレーム通過・廃棄・応答機能におけるメッセージ一致比較部の内部構成を示す図である。 FIG. 15 is a diagram showing an internal configuration of the message match comparison unit in the frame passing / discarding / response function of the frame processing apparatus according to the second embodiment of the present invention.
比較指示15001を受けたメッセージ内容一致比較機能16010は、受信したフォーマット情報15002及びメッセージ内容15003を用いて、それぞれ基準メッセージ16020との比較を行う。
The message content
比較の際には、まず、基準メッセージ16020を先頭から検索してスペース及びタブに該当するキャラクタコードの削除を行い、これをメッセージ終了コードである『\r\n\r\n』が発見されるまで行う。これによりスペース、タブ数の違いによる不一致判定結果を防止する。これと同じ操作をメッセージ内容15003についても行う。
In the comparison, first, the
次に、フォーマット情報15002を先頭から検索し、行終了コードである『\r\n』の次から『\r\n』が発見されるまでの文字列を取得し2行目の『CACHE-CONTROL:』を得る。これを1回目の比較基準とし、スペース及びタブに該当するキャラクタコードの削除後の基準メッセージを先頭から検索し、行終了コードである『\r\n』の次から始まる文字列を次の行終了コードである『\r\n』まで取得して『CACHE-CONTROL: max-age=120』を得る。これを比較基準文字列『CACHE-CONTROL:』と先頭部分を比較する。
Next, the
この場合は同一の文字列であるため、同様の処理を3行目以降も行ってこれをフォーマット情報にてメッセージ終了コード『\r\n\r\n』が発見されるまで繰り返す。一方、一致しない場合は基準メッセージにおける次の『\r\n』までの文字列を取得して比較を繰り返し行い、一致した場合はその文字列を2行目としてメッセージ内の行を入れ替えてフォーマット情報の3行目以降について同じ処理を行う。メッセージ終了コードである『\r\n\r\n』が発見されるまで一致しなかった場合は、比較対象外メッセージと判定して不一致通知16201を出力して処理を終了する。
In this case, since they are the same character string, the same processing is performed for the third and subsequent lines, and this is repeated until the message end code “\ r \ n \ r \ n” is found in the format information. On the other hand, if they do not match, the character string up to the next “\ r \ n” in the reference message is acquired and compared, and if it matches, the character string is used as the second line and the lines in the message are swapped and formatted. The same processing is performed for the third and subsequent lines of information. If the message end code “\ r \ n \ r \ n” does not match until it is found, it is determined that the message is not subject to comparison, and a
これをスペース及びタブに該当するキャラクタコードの削除後のメッセージ内容についても同様に行う。これにより、単に行の入れ替わりによって不一致判定が行われる事態を防止することができる。 This is similarly performed for the message contents after deletion of the character codes corresponding to the spaces and tabs. As a result, it is possible to prevent a situation where a mismatch determination is simply made by changing the rows.
以上の方法でフォーマット整形を行った基準メッセージとメッセージ内容とは、ビット単位、オクテット単位、またはそれらの組み合わせ、ハッシュ演算等の一定長へのデータ変換演算、などを用いて比較される。 The reference message that has been formatted by the above method and the message content are compared using a bit unit, an octet unit, or a combination thereof, a data conversion operation to a certain length such as a hash operation, and the like.
PacketCである13400のメッセージ内容が入力された場合には一致と判定され、通過・挿入判定部11500へ一致通知16003が出力される。
If the message content of 13400, which is PacketC, is input, it is determined to be a match, and a
判定結果に基づき、通過/挿入判定部11500は送信フレーム11000の通過・挿入判定結果11510を通知する。通知を受けた通過/挿入部11600では通過指示の場合は何もせずに送信フレーム11000を通過させ、挿入指示の場合は図12に示すようにPacketC13400の複製を作成し、PacketD13300として挿入を行い、挿入完了通知11610を出力して起動・停止機能111000に対し停止指示を行う(図10参照)。尚、この挿入操作の際に、予め設定した情報に基づき、PacketD13300の送出タイミングを一定時間経過後行うようにしても良い。
Based on the determination result, the pass /
通知を受けた起動・停止機能111000は各構成要素の停止を行い、次回の受信フレーム廃棄が発生するまで待機を行う。
Upon receiving the notification, the start /
以上のように、実施の形態2のフレーム処理装置によれば、既に受信済みで不要な冗長メッセージと判定して廃棄したメッセージに対応した応答メッセージを送出することができ、複製した送出フレームと他のフレームとの間隔を調整することができる。 As described above, according to the frame processing apparatus of the second embodiment, it is possible to send a response message corresponding to a discarded message determined as an unnecessary redundant message that has already been received. The distance from the frame can be adjusted.
本発明は、受信済みメッセージを含むフレームを廃棄する為、不要なメッセージの処理に関わるプロセッサの負荷を低減させることができる効果を有し、ネットワークインタフェースを通じてイーサネットなどのフレームを送受信処理する装置において、フレームを識別して、受信フレームの廃棄、通過、またはフレーム送出等の制御を行うフレーム処理装置等に有用である。 The present invention discards a frame including a received message, and thus has an effect of reducing the load on the processor related to processing of an unnecessary message. In an apparatus for transmitting and receiving a frame such as Ethernet through a network interface, The present invention is useful for a frame processing apparatus that identifies a frame and performs control such as discarding, passing, or sending out a received frame.
1000 ネットワークインターフェース機能
1100 フレーム通過・廃棄・応答機能
1200 フレーム処理機能
2100 ヘッダ分類部
2200 メッセージ種別分類部
2300 メッセージ一致比較部
2400 冗長メッセージ判定部
2500 通過/廃棄判定部
2600 通過/廃棄部
11100 ヘッダ分類部
11200 メッセージ種別分類部
11300 メッセージ一致比較部
11500 通過/挿入判定部
11600 通過/挿入部
1000
Claims (8)
フレームのヘッダ情報及びペイロード情報を用いて抽出した、フレームに含まれる制御用のメッセージを分類する分類手段と、
分類されたメッセージ毎に初めて受信したメッセージを比較の基準である基準メッセージとして、以降受信して分類されたメッセージに対して、前記基準メッセージとの一致比較を行うメッセージ一致比較手段と、
前記基準メッセージと一致したメッセージに対して当該メッセージが既に受信済みである同一メッセージであるか否かを判定する冗長メッセージ判定手段と、を有し、
前記冗長メッセージ判定手段は、前記基準メッセージを受信した時刻からの受信経過時間を測定する測定手段を備え、判定対象となるメッセージを受信するまでの受信経過時間が、時間に基づいて規定される判定基準値の範囲内にある場合には当該メッセージを既に受信済みであると判定して廃棄し、前記受信経過時間が前記判定基準値を超過している場合には前記基準メッセージをクリアし、前記測定手段が当該メッセージを受信した時刻から新たに受信経過時間を測定するフレーム処理装置。 A frame processing device that determines passage or discard of a specific frame determined from frames received by a communication device,
Classification means for classifying control messages included in the frame, extracted using the header information and payload information of the frame,
A message match comparison means for performing a match comparison with the reference message for messages classified after received as a reference message that is a reference for comparison for the first received message for each classified message;
Redundant message determination means for determining whether the message is the same message that has already been received with respect to a message that matches the reference message,
The redundant message determination unit includes a measurement unit that measures an elapsed reception time from the time when the reference message is received, and the determination that the elapsed reception time until the message to be determined is received is defined based on the time. When it is within the range of the reference value, it is determined that the message has already been received and discarded, and when the reception elapsed time exceeds the determination reference value, the reference message is cleared, A frame processing apparatus for newly measuring the elapsed reception time from the time when the measuring means receives the message.
前記検出手段の検出結果から前記受信フレームに対応する送出フレームを特定する特定手段と、
送出フレーム流から、特定した送出フレームを抽出する抽出手段と、
抽出した送出フレームの複製フレームを作成して前記送出フレーム流に挿入する挿入手段と、
を有する請求項1記載のフレーム処理装置。 Detecting means for detecting header information and payload information of a received frame to be responded;
Specifying means for specifying a transmission frame corresponding to the received frame from the detection result of the detection means;
Extraction means for extracting the specified transmission frame from the transmission frame stream;
Insertion means for creating a duplicate frame of the extracted transmission frame and inserting it into the transmission frame stream;
The frame processing apparatus according to claim 1, comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005224136A JP2007043382A (en) | 2005-08-02 | 2005-08-02 | Frame processor |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005224136A JP2007043382A (en) | 2005-08-02 | 2005-08-02 | Frame processor |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2007043382A true JP2007043382A (en) | 2007-02-15 |
Family
ID=37800967
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2005224136A Withdrawn JP2007043382A (en) | 2005-08-02 | 2005-08-02 | Frame processor |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2007043382A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009071753A (en) * | 2007-09-18 | 2009-04-02 | Fujitsu Ltd | Communication suppressing method, communication suppressing apparatus, communication suppressing program, service providing server and service utilizing terminal |
JP2013110586A (en) * | 2011-11-21 | 2013-06-06 | Hitachi Ltd | Communication system, communication device, and communication method |
-
2005
- 2005-08-02 JP JP2005224136A patent/JP2007043382A/en not_active Withdrawn
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009071753A (en) * | 2007-09-18 | 2009-04-02 | Fujitsu Ltd | Communication suppressing method, communication suppressing apparatus, communication suppressing program, service providing server and service utilizing terminal |
JP2013110586A (en) * | 2011-11-21 | 2013-06-06 | Hitachi Ltd | Communication system, communication device, and communication method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP6500304B2 (en) | Method for acquiring accurate flow entry by SDN switch, and SDN switch, controller and system | |
US10382309B2 (en) | Method and apparatus for tracing paths in service function chains | |
JP5720668B2 (en) | Packet transfer apparatus, communication system, processing rule update method and program | |
JP4829896B2 (en) | Method, system and article for improved network performance by avoiding data corruption | |
US7489682B2 (en) | Packet relay system | |
US7554959B1 (en) | Apparatus and method for cluster network device discovery | |
JP4564228B2 (en) | Structure and method for transparently encoding and transmitting network communication data online and in cross session | |
JP3717836B2 (en) | Dynamic load balancer | |
US9407503B2 (en) | Control apparatus, communication system, communication method, and program | |
EP3972226A1 (en) | Network packet flow controller with extended session management | |
US7373407B2 (en) | Communications system for establishing PPP connections between IEEE 1394 terminals and IP networks | |
EP1928127A1 (en) | Method and system for tunneling MACSEC packets through non-MACSEC nodes | |
WO2012159481A1 (en) | Path maximum transmission unit discovery method and node | |
US6697872B1 (en) | Distributed packet processing using encapsulation and decapsulation chains | |
JP4126856B2 (en) | TAG-VLAN ID automatic identification method | |
US20100135310A1 (en) | Token bus communication system | |
JP2007043382A (en) | Frame processor | |
US20040249923A1 (en) | Efficient home network management system and method | |
JP2006324981A (en) | Multicast packet transfer system | |
CN107683594B (en) | Communication control device, communication control method, network switch, route control method, and communication system | |
JP2008109357A (en) | Packet transfer device and packet transfer method | |
Cisco | Banyan VINES | |
JP4384951B2 (en) | Access point management apparatus and access point software version upgrade method | |
JP3834157B2 (en) | Service attribute assignment method and network device | |
JP2003229880A (en) | Wide area monitor and control system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD02 | Notification of acceptance of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7422 Effective date: 20071113 |
|
RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20071120 |
|
A300 | Application deemed to be withdrawn because no request for examination was validly filed |
Free format text: JAPANESE INTERMEDIATE CODE: A300 Effective date: 20081007 |