WO2023032210A1 - ゲートウェイ装置、通信方法、及びプログラム - Google Patents

ゲートウェイ装置、通信方法、及びプログラム Download PDF

Info

Publication number
WO2023032210A1
WO2023032210A1 PCT/JP2021/032696 JP2021032696W WO2023032210A1 WO 2023032210 A1 WO2023032210 A1 WO 2023032210A1 JP 2021032696 W JP2021032696 W JP 2021032696W WO 2023032210 A1 WO2023032210 A1 WO 2023032210A1
Authority
WO
WIPO (PCT)
Prior art keywords
packet
gateway device
terminal
address
response packet
Prior art date
Application number
PCT/JP2021/032696
Other languages
English (en)
French (fr)
Inventor
克真 宮本
伸也 河野
幸司 杉園
浩輝 加納
Original Assignee
日本電信電話株式会社
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 日本電信電話株式会社 filed Critical 日本電信電話株式会社
Priority to PCT/JP2021/032696 priority Critical patent/WO2023032210A1/ja
Priority to JP2023544985A priority patent/JPWO2023032210A1/ja
Publication of WO2023032210A1 publication Critical patent/WO2023032210A1/ja

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/66Arrangements for connecting between networks having differing types of switching systems, e.g. gateways
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/09Mapping addresses
    • H04L61/25Mapping addresses of the same type
    • H04L61/2503Translation of Internet protocol [IP] addresses
    • H04L61/2514Translation of Internet protocol [IP] addresses between local and global IP addresses

Definitions

  • the present invention relates to a gateway device that performs address translation.
  • IPv4 address exhaustion is a problem, and although IPv6 appeared to solve this problem, IPv4 is still widely used in minimal implementation such as existing IPv6-incompatible NW devices and IoT terminals. ing.
  • NAT Network Address Translation
  • NAPT Network Address Port Translation
  • the present invention has been made in view of the above points, and it is an object of the present invention to provide a technique for transferring response packets at high speed in a gateway device that performs address translation.
  • a packet is received from a terminal, the address of the packet is translated, the packet after the address translation is transmitted to the server, and part of the response packet to be transmitted to the terminal is calculated in advance.
  • an address translation unit comprising: a packet generator that generates a response packet to be transmitted to the terminal using the data part and the part of the response packet received from the server.
  • FIG. 1 is a system configuration diagram in an embodiment of the present invention
  • FIG. It is a figure for demonstrating operation
  • IPv4 and TCP are given as specific examples, but these are only examples.
  • the technology according to the present invention can be applied to any protocol that can communicate with NAPT.
  • IPMP there is no port number, and ICMP Identifier is used instead.
  • NAPT Network-to-Network Protocol
  • a client terminal 20 exists on the LAN side
  • a server 30 exists on the WAN side
  • a gateway device 10 implementing NAPT exists between them.
  • the gateway device 10 Upon receiving the packet, the gateway device 10 performs the following processing.
  • the IP address/port conversion of the packet is performed, and the conversion information is recorded in the NAPT table.
  • S2 Record the source port number and source IP address in the NAPT table together with the converted port number.
  • the gateway device 10 when the gateway device 10 receives a response packet, it is necessary to repeatedly perform "table search ⁇ IP address/port number conversion ⁇ checksum calculation/replacement" for each packet. Transfer delays occur. In particular, the delay increases when large data is divided.
  • FIG. 2 shows the system configuration in this embodiment. As shown in FIG. 2, this system includes a gateway device 100, a client terminal 200 as a device on the LAN side, and a server 300 as a device on the WAN side. connected to the device 100;
  • the client terminal 200 and the server 300 may each be a device that operates according to conventional technology.
  • the gateway device 100 is basically a device that performs the NAPT operation, but as will be described below, performs an operation for solving the above problems.
  • the operation of the gateway device 100 will be described with reference to FIG.
  • the table shown in the upper part of FIG. 3 is the NAPT table held by the gateway device 100 .
  • the gateway device 100 applies NAPT to the received packet (S101), transmits the NAPTed packet to the WAN side, and at the same time calculates a part of the response packet (IP header, etc.) in advance and stores it in the output queue on the LAN side.
  • Store (S102).
  • the gateway device 100 stores the IP address of the source of the received packet, the pre-translation port number of the source, and the post-translation port number of the source in the NAPT table, and also stores the pre-calculated information in the output queue number. is also stored in the NAPT table (S103).
  • the gateway device 100 receives a response packet from the WAN side, if the IP header or the like has been calculated in advance, the uncalculated portion of the packet (referred to as the “data portion”) is stored in the corresponding output queue. , and the calculated part and the uncalculated part are concatenated to generate a packet and output it.
  • the gateway device 100 when the gateway device 100 receives a response packet, it searches (looks up) the NAPT table using the port number of the transmission destination of the response packet as a key (S104). As a result of the search, if the port number matches (hits) the NAPT table and the output queue number exists in that row (entry), the data part of the response packet is stored in the queue (S105).
  • the pre-calculated and already stored part is concatenated with the data part to complete the packet (S106) and output it.
  • response packets are converted in advance, so high-speed transfer of response packets is possible.
  • the gateway device 100 preliminarily calculates part of the response packet from the IP address and port number of the packet received from the LAN side.
  • the gateway device 100 pre-calculates the IP header and IP header checksum in the response packet as shown in FIG. If the conversion of received packet information into response packet information is expressed as "information ⁇ information", as shown in FIG. 4, "destination port number (dstPort) ⁇ source port number (srcPort)” source port number (srcPort) ⁇ destination port number (dstPort)”, “destination IP address (dstIP) ⁇ source IP address (srcIP)”, and “source IP address (srcIP) ⁇ destination IP address (dstIP)”
  • the conversion (calculation) is done as follows. In addition, an IP header checksum is calculated.
  • NAPT processing converts the source port number (srcPort) and the source IP address (srcIP) to generate a transmission packet.
  • the area surrounded by a thick frame indicated by A in FIG. 5 is the range of pre-calculation. That is, all IP headers and TCP header source port numbers and destination port numbers are calculated in advance. That is, the portion from the top of the IP header to 32 ⁇ 7 bits is calculated in advance.
  • the checksum of the IP header enclosed in the thick frame indicated by B is also calculated in advance. At this time, provisional fixed values are used for survival time and total length.
  • FIG. 6 shows an example of the NAPT table.
  • gateway device 100 adds the information to the NAPT table as an entry if the information related to that NAPT does not exist in the NATP table. note that, In the case of the most recently converted flow, the entry remains, so addition is unnecessary.
  • the converted port number is preferably a hash value based on the IP address and port number. However, it is not limited to this.
  • the output queue number in the NAPT table is information that indicates a data store that can uniquely identify a calculated bit string, such as a cache memory address or register number.
  • the NAPT table may store the pre-calculated packet bit string itself.
  • the gateway device 100 that performs the above-described operations may have any configuration (functional blocks) as long as it is capable of executing the above-described operations. As an example, FIG. show.
  • the gateway device 100 includes a NAPT table 110, an address conversion section 120, a packet generation section 130, an output queue 140, an output queue 150, and a table search section 160.
  • PHY in FIG. 7 is the function of the physical layer that serves as an interface with the network.
  • the address translation unit 120 executes NAPT address translation processing.
  • the packet generator 130 generates a packet by concatenating the header after address translation and the data part. Also, the address conversion unit 120 performs pre-calculation. The pre-computation may be performed by the packet generator 130 .
  • the address translation unit 120 receives a packet from a terminal, translates the address of the packet, and transmits the address-translated packet to the server. is calculated in advance.
  • the packet generator 130 generates a response packet to be transmitted to the terminal using the data part and the part of the response packet received from the server.
  • the table search unit 160 searches the NAPT table 110 based on the destination port number when a response packet arrives.
  • the output queue 140 stores pre-calculated information. If there is a corresponding output queue in the search by the table search unit 160, the data portion is stored in the output queue 140, and the packet generation unit 130 generates a packet to be output by linking the precalculated information and the data portion. .
  • a packet is generated by the packet generation unit 130 and stored in the output queue 150 by the same processing as when receiving a normal NAPT response packet.
  • the gateway device 100 shown in FIG. 7 can be realized by hardware implementation using ASIC or FPGA, or by software implementation that causes a computer having a CPU and memory to execute a program.
  • the address conversion unit 120 may be implemented by software, and other components may be implemented by hardware.
  • the processing of the address conversion unit 120, the packet generation unit 130, the table search unit 160, etc. be implemented on the FPGA circuit. Furthermore, by parallelizing each process with a pipeline, many flows can be processed.
  • the NAPT table is a storage device with a capacity capable of holding port numbers and queue numbers.
  • a RAM SRAM, DRAM, etc.
  • Hard configuration example A hardware configuration example in which the gateway device 100 is implemented by a computer and software will be described.
  • This computer may be a physical computer or a virtual machine on the cloud.
  • the gateway device 100 can be implemented by executing a program corresponding to the processing performed by the gateway device 100 using hardware resources such as a CPU and memory built into the computer.
  • the above program can be recorded in a computer-readable recording medium (portable memory, etc.), saved, or distributed. It is also possible to provide the above program through a network such as the Internet or e-mail.
  • FIG. 8 is a diagram showing a hardware configuration example of the computer.
  • the computer of FIG. 8 has a drive device 1000, an auxiliary storage device 1002, a memory device 1003, a CPU 1004, an interface device 1005, a display device 1006, an input device 1007, an output device 1008, etc., which are interconnected by a bus BS.
  • a bus BS bus BS
  • a program that implements the processing in the computer is provided by a recording medium 1001 such as a CD-ROM or memory card, for example.
  • a recording medium 1001 such as a CD-ROM or memory card
  • the program is installed from the recording medium 1001 to the auxiliary storage device 1002 via the drive device 1000 .
  • the program does not necessarily need to be installed from the recording medium 1001, and may be downloaded from another computer via the network.
  • the auxiliary storage device 1002 stores installed programs, as well as necessary files and data.
  • the memory device 1003 reads and stores the program from the auxiliary storage device 1002 when a program activation instruction is received.
  • the CPU 1004 implements functions related to the gateway device 100 according to programs stored in the memory device 1003 .
  • the interface device 1005 is used as an interface for connecting to a network or the like.
  • a display device 1006 displays a GUI (Graphical User Interface) or the like by a program.
  • An input device 1007 is composed of a keyboard, a mouse, buttons, a touch panel, or the like, and is used to input various operational instructions.
  • the output device 1008 outputs the calculation result.
  • This specification discloses at least the following gateway device, communication method, and program.
  • (Section 1) an address translation unit that receives a packet from a terminal, performs address translation on the packet, transmits the address-translated packet to a server, and pre-calculates part of a response packet to be transmitted to the terminal;
  • a gateway device comprising: a packet generation unit that generates a response packet to be transmitted to the terminal using the data part and the part of the response packet received from the server.
  • the address conversion unit stores information before conversion in a packet received from the terminal, information after conversion of the information, and information indicating the part in a table held by the gateway device. Gateway device as described.
  • (Section 3) further comprising a table search unit for searching the table based on the response packet received from the server; When the table search unit detects an entry corresponding to the response packet, the packet generation unit generates a response packet to be transmitted to the terminal using the part specified by the information of the entry. 3.
  • the gateway device according to item 2. (Section 4) The gateway device according to any one of items 1 to 3, wherein the part includes an IP header of a response packet to be transmitted to the terminal. (Section 5)
  • the address conversion unit stores the portion calculated in advance in an output queue, and the packet generation unit uses the portion stored in the output queue and the data unit to transmit to the terminal. 5.
  • the gateway device according to any one of items 1 to 4, which generates a response packet.
  • (Section 7) A communication method executed by a gateway device, receiving a packet from a terminal, performing address translation on the packet, transmitting the address-translated packet to a server, and pre-calculating a portion of a response packet to be transmitted to the terminal; and generating a response packet to be transmitted to the terminal using the data part and the part of the response packet received from the server.
  • (Section 8) A program for causing a computer to function as each unit in the gateway device according to any one of items 1 to 5.
  • gateway device 110 NAPT table 120 address conversion unit 130 packet generation unit 140 output queue 150 output queue 160 table search unit 20, 200 client terminals 30, 300 server 1000 drive device 1001 recording medium 1002 auxiliary storage device 1003 memory device 1004 CPU 1005 interface device 1006 display device 1007 input device 1008 output device

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

端末からパケットを受信し、当該パケットに対するアドレス変換を行って、アドレス変換後のパケットをサーバに送信するとともに、前記端末へ送信する応答パケットの一部を事前に計算するアドレス変換部と、前記サーバから受信した応答パケットのデータ部と前記一部とを用いて前記端末へ送信する応答パケットを生成するパケット生成部とを備えるゲートウェイ装置。

Description

ゲートウェイ装置、通信方法、及びプログラム
 本発明は、アドレス変換を行うゲートウェイ装置に関連するものである。
 昨今、PCやモバイル端末のみならずM2M/IoTデバイスがインターネットに接続され、IPv4アドレス空間を超える数へと増大している。
 その中でIPv4アドレス枯渇が課題とされており、この課題を解決するためにIPv6が登場したものの、既存のIPv6非対応なNW機器やIoT端末のようなミニマルな実装では未だIPv4が広く使用されている。
 有限なIPv4アドレスを複数の端末で共有する方法としてNAT(Network Address Translation)/NAPT(Network Address Port Translation)が使用されるのが一般的である。NAT/NAPTを用いることで、1つのグローバルIPを複数の端末で共有することができる。また、内部NWのアドレスを変換することから、外部からの侵入を防ぐことができる。
F.Liu et al, "The Design and Implementation of NAPT Function in Border Gateway Based on LKM," 978-1-5090-1997-7/16 (c)2016 IEEE. https://ieeexplore.ieee.org/document/7589735
 しかし、従来のNAT/NAPT等のアドレス変換技術を用いる場合、応答パケットが大量に発生すると、所望の性能が得られず、応答パケットを高速に転送できない可能性がある。
 本発明は上記の点に鑑みてなされたものであり、アドレス変換を行うゲートウェイ装置において、応答パケットを高速に転送するための技術を提供することを目的とする。
 開示の技術によれば、端末からパケットを受信し、当該パケットに対するアドレス変換を行って、アドレス変換後のパケットをサーバに送信するとともに、前記端末へ送信する応答パケットの一部を事前に計算するアドレス変換部と、
 前記サーバから受信した応答パケットのデータ部と前記一部とを用いて前記端末へ送信する応答パケットを生成するパケット生成部と
 を備えるゲートウェイ装置が提供される。
 開示の技術によれば、アドレス変換を行うゲートウェイ装置において、応答パケットを高速に転送することが可能となる。
課題を説明するための図である。 本発明の実施の形態におけるシステム構成図である。 本発明の実施の形態におけるゲートウェイ装置の動作を説明するための図である。 事前計算を説明するための図である。 事前計算を説明するための図である。 NAPTテーブルの例を示す図である。 装置構成例を示す図である。 装置のハードウェア構成例を示す図である。
 以下、図面を参照して本発明の実施の形態(本実施の形態)を説明する。以下で説明する実施の形態は一例に過ぎず、本発明が適用される実施の形態は、以下の実施の形態に限られるわけではない。
 以下の説明において、具体例としてIPv4とTCPを挙げて説明を行っているが、これらは一例に過ぎない。本発明に係る技術は、NAPTを疎通可能なプロトコルであればどのプロトコルにも適用可能である。例えば、IPv6、UDP、ICMPなどにも本発明に係る技術を適用することが可能である。なお、ICMPの場合は、ポート番号はなく、代わりにICMP Identifierが使用される。
 以下では、NAPTの従来動作と課題について詳細に説明し、その後に、本発明に係る技術の実施形態を説明する。なお、従来動作と課題の説明における分析内容は公知ではない。
 (従来動作について)
 図1を参照してNAPTの一般的な動作の例について説明する。図1の例において、LAN側にクライアント端末20が存在し、WAN側にサーバ30が存在し、これらの間にNAPTを実装したゲートウェイ装置10が存在する。
 IPアドレス及びポート番号は図示のとおりであるとする。図1に示すように、A=10.0.0.1:10080、B=8.8.8.8:80、C=192.168.11.8:11111としている。
 ゲートウェイ装置10は、パケットを受信すると、以下の処理を行う。
 ・LAN側→WAN側の通信では、パケットのIPアドレス/ポート変換を行い、NAPTテーブルに変換情報を記録する。
 ・WAN側→LAN側の通信では、NAPTテーブルを基に、元のIPアドレス/ポートへの変換を行う。
 より詳細には下記のとおりである。
 <LAN側→WAN側の通信におけるゲートウェイ装置による処理>
 S1:受信パケットの送信元IPアドレスと送信元ポート番号から変換後のポート番号を生成する。
 S2:送信元ポート番号と送信元IPアドレスを変換後のポート番号とともにNAPTテーブルに記録する。
 S3:受信パケットの送信元IPアドレスをWAN側IPアドレスに置換する。
 S4:受信パケットの送信元ポート番号をWAN側ポート番号に置換する。
 S5:チェックサムの計算・置換を行う。
 <WAN側→LAN側の通信におけるゲートウェイ装置による処理>
 S1:受信パケットについて、送信先ポート番号を基にNAPTテーブルからIPアドレスとポート番号を検索する。
 S2:パケットの送信先ポート番号を検索したポート番号に置換する。
 S3:パケットの送信先IPアドレスを検索したIPアドレスに置換する。
 S4:チェックサムの計算・置換を行う。
 (課題について)
 上記のような動作を行う従来のNAPTを実装したゲートウェイ装置10では、応答パケットが大量に発生すると、十分な性能が得られない可能性がある。その理由は下記のとおりである。
 すなわち、上記動作例で説明したとおり、ゲートウェイ装置10は、応答パケットを受信した際に、「テーブル検索→IPアドレス・ポート番号変換→チェックサム計算・置換」をパケットごとに繰り返し行う必要があり、転送の遅延が発生する。特に、大きいデータが分割される場合などにおいて遅延が大きくなる。
 また、応答パケットの数(クライアント端末数)が多くなると、テーブルlook-upにより大きな時間がかかってしまう。
 以下、上記の課題を解決する本実施の形態に係る技術を説明する。
 (システム構成)
 本実施の形態におけるシステム構成を図2に示す。図2に示すように、本システムは、ゲートウェイ装置100、LAN側の装置であるクライアント端末200、及びWAN側の装置であるサーバ300を備え、クライアント端末200とサーバ300は、ネットワークを介してゲートウェイ装置100に接続される。
 クライアント端末200とサーバ300はそれぞれ従来技術に基づき動作する装置であてよい。ゲートウェイ装置100は、基本的にはNAPT動作を行う装置であるが、以下で説明するように、上記課題を解決するための動作を実行する。
 (ゲートウェイ装置100の動作)
 本実施の形態では、従来方式の課題であった応答パケットのアドレス変換処理について、応答パケットの一部を事前に計算・生成しておき、応答パケット受信時に、事前に計算・生成しておいたビット列を応答パケットのデータ部分に結合して送信することとしている。
 図3を参照してゲートウェイ装置100の動作を説明する。図3において、受信パケットについて、宛先アドレス(IPアドレス+ポート番号)=B、送信元アドレス=Aである。他のパケットについても同様に、図示のとおりに宛先アドレス、送信元アドレスが付与される。また、図3の上段に示すテーブルは、ゲートウェイ装置100が保持するNAPTテーブルである。
 <LAN側→WAN側の通信>
 ゲートウェイ装置100は、受信パケットに対してNAPTを施し(S101)、NAPTしたパケットをWAN側へ送信すると同時に、応答パケットの一部(IPヘッダなど)を事前に計算し、LAN側の出力キューに格納する(S102)。
 また、ゲートウェイ装置100は、受信パケットの送信元のIPアドレス、送信元の変換前ポート番号、送信元の変換後ポート番号をNAPTテーブルに格納するとともに、事前計算した情報を格納した出力キューの番号もNAPTテーブルに格納する(S103)。
 NAPTテーブルへの情報格納の際には、LRU方式に基づき、最新の情報をNAPTテーブルの上位に格納する。これは、受信パケット送信後すぐに応答パケットが来ることを想定し、より早くテーブルにヒットさせるためである。これにより、端末数が増えてもlookup性能低下を少なくすることができる。
 <WAN側→LAN側の通信>
 ゲートウェイ装置100が応答パケットをWAN側から受信するとき、IPヘッダ等を事前に計算済みのパケットである場合には、当該パケットの未計算部分(「データ部」と呼ぶ)を、対応する出力キューへ振り分け、計算済み部分と未計算部分とを連結させてパケットを生成し、出力する。
 より具体的には、図3において、ゲートウェイ装置100が応答パケットを受信すると、応答パケットの送信先のポート番号をキーにしてNAPTテーブルを検索(Look-up)する(S104)。検索の結果、ポート番号がNAPTテーブルに該当(ヒット)し、その行(エントリ)に出力キュー番号が存在する場合は当該キューに応答パケットのデータ部を格納する(S105)。
 出力キュー(図3の例では出力キュー#1)において、事前計算して既に格納されている部分とデータ部とを連結することによりパケットを完成させ(S106)、出力する。
 上記のとおり、本実施の形態では、応答パケットの変換を事前に実施するため、応答パケットについて高速な転送が可能になる。
 (事前計算方法の例)
 上述したとおり、ゲートウェイ装置100は、LAN側からの受信パケットのIPアドレスとポート番号から応答パケットの一部を事前に計算しておく。
 具体例を図4に示す。ゲートウェイ装置100は、図4に示すとおり、応答パケットにおけるIPヘッダ及びIPヘッダチェックサムを事前に計算する。受信パケットの情報を応答パケットの情報に変換することを「情報→情報」と表すことにすると、図4に示すように、「宛先ポート番号(dstPort)→送信元ポート番号(srcPort)」、「送信元ポート番号(srcPort)→宛先ポート番号(dstPort)」、「宛先IPアドレス(dstIP)→送信元IPアドレス(srcIP)」、「送信元IPアドレス(srcIP)→宛先IPアドレス(dstIP)」のように変換(計算)がなされる。更に、IPヘッダチェックサムの計算を行う。
 一方、NAPT処理により、送信元ポート番号(srcPort)の変換と、送信元IPアドレス(srcIP)の変換がなされ、送信パケットが生成される。
 TCPの場合における事前計算の範囲の例を、図5を参照して説明する。この例では、図5のAで示す太枠で囲んだ部分が事前計算の範囲となる。すなわち、IPヘッダの全てとTCPヘッダの送信元ポート番号と宛先ポート番号を事前に計算する。すなわち、IPヘッダの先頭から32×7ビットまでの部分を事前に計算する。
 Bで示す太枠で囲んだIPヘッダのチェックサムについても事前に計算する。このとき生存時間や全長については仮の固定値を使用する。
 Cで示す太枠で囲んだTCPヘッダのチェックサムに関しては、IPアドレス・ポート番号が変わるため、応答パケット到着後に再計算が必要である。ペイロードも含んで計算するため、事前計算は不可である。
 (NAPTテーブルについて)
 次に、NAPTテーブルについてより詳細に説明する。図6にNAPTテーブルの例を示している。
 ゲートウェイ装置100は、NAPT後に、そのNAPTに係る情報がNATPテーブルに存在しない場合に、当該情報をエントリとしてNAPTテーブルに追加する。なお、
直近で変換したフローの場合はエントリが残っているので追加不要である。
 各エントリには生存時間を設けることが望ましい。また、変換後のポート番号は、IPアドレスとポート番号を基にしたハッシュ値が望ましい。ただし、これに限定されるわけではない。
 NAPTテーブルにおける出力キュー番号は、計算済みのビット列を一意に特定できるデータストアを示す情報であり、例えば、キャッシュメモリのアドレス番地やレジスタの番号等である。ここで、NAPTテーブルに事前計算したパケットのビット列そのものを格納することととしてもよい。
 また、出力キューを持たないエントリが存在することも可能である。出力キューを持たない場合とは、例えば、出力キューに空きがない場合、キューが削除された場合、そもそもキューに格納する必要がない場合等である。
 (装置構成例)
 上述した動作を行うゲートウェイ装置100は、上述した動作を実行できる構成であればどのような構成(機能ブロック)を有してもよいが、一例として、図7に、ゲートウェイ装置100の構成例を示す。
 図7の例において、ゲートウェイ装置100は、NAPTテーブル110、アドレス変換部120、パケット生成部130、出力キュー140、出力キュー150、テーブル検索部160を備える。図7における「PHY」は、ネットワークとのインタフェースとなる物理層の機能である。
 アドレス変換部120は、NAPTのアドレス変換処理を実行する。パケット生成部130は、アドレス変換後のヘッダとデータ部を連結することでパケットを生成する。また、アドレス変換部120は事前計算を行う。事前計算をパケット生成部130が実行してもよい。
 より具体的には、アドレス変換部120は、端末からパケットを受信し、当該パケットに対するアドレス変換を行って、アドレス変換後のパケットをサーバに送信するとともに、前記端末へ送信する応答パケットの一部を事前に計算する。パケット生成部130は、前記サーバから受信した応答パケットのデータ部と前記一部とを用いて前記端末へ送信する応答パケットを生成する。
 テーブル検索部160は、応答パケット到着時に、送信先ポート番号に基づくNAPTテーブル110の検索を行う。
 出力キュー140には、事前計算した情報が格納される。テーブル検索部160による検索で該当する出力キューが存在する場合、出力キュー140にデータ部が格納され、パケット生成部130は、事前計算した情報とデータ部を連結することで出力するパケットを生成する。
 また、テーブル検索部160による検索で該当する出力キューが存在しない場合、通常のNAPTの応答パケット受信時と同様の処理により、パケット生成部130によりパケットが生成され、出力キュー150に格納される。
 図7に示すゲートウェイ装置100は、ASICやFPGAを用いたハードウェア実装により実現することもできるし、CPUとメモリを有するコンピュータにプログラムを実行させるソフトウェア実装で実現することも可能である。
 また、ハードウェア実装とソフトウェア実装を混在させた構成を採用してもよい。例えば、アドレス変換部120をソフトウェアで実装し、それ以外をハードウェアで実装することとしてもよい。
 ゲートウェイ装置100をFPGAで実装する場合、アドレス変換部120、パケット生成部130、テーブル検索部160などの処理はFPGA回路上で実装されることが望ましい。更に、各処理をパイプラインで並列化することで、多くのフローを処理可能となる。
 FPGAでの実装の場合、NAPTテーブルはポート番号とキュー番号を保持可能な容量を持つ記憶装置である。ただし、より高速なlookupのためには、NAPTテーブルをFPGAと接続されるRAM(SRAM,DRAMなど)に保存することが望ましい。また、FPGAでの実装の場合、キューはレジスタやRAMに保存することが望ましい。
 (ハードウェア構成例)
 ゲートウェイ装置100をコンピュータとソフトウェアで実装する場合におけるハードウェア構成例を説明する。このコンピュータは、物理的なコンピュータであってもよいし、クラウド上の仮想マシンであってもよい。
 すなわち、ゲートウェイ装置100は、コンピュータに内蔵されるCPUやメモリ等のハードウェア資源を用いて、ゲートウェイ装置100で実施される処理に対応するプログラムを実行することによって実現することが可能である。上記プログラムは、コンピュータが読み取り可能な記録媒体(可搬メモリ等)に記録して、保存したり、配布したりすることが可能である。また、上記プログラムをインターネットや電子メール等、ネットワークを通して提供することも可能である。
 図8は、上記コンピュータのハードウェア構成例を示す図である。図8のコンピュータは、それぞれバスBSで相互に接続されているドライブ装置1000、補助記憶装置1002、メモリ装置1003、CPU1004、インタフェース装置1005、表示装置1006、入力装置1007、出力装置1008等を有する。なお、ハードウェア実装とソフトウェア実装を組み合わせてゲートウェイ装置100を実現する場合において、図8に示す構成は、ゲートウェイ装置100におけるソフトウェア実装(例えばアドレス変換部)を実現するための構成であってもよい。
 当該コンピュータでの処理を実現するプログラムは、例えば、CD-ROM又はメモリカード等の記録媒体1001によって提供される。プログラムを記憶した記録媒体1001がドライブ装置1000にセットされると、プログラムが記録媒体1001からドライブ装置1000を介して補助記憶装置1002にインストールされる。但し、プログラムのインストールは必ずしも記録媒体1001より行う必要はなく、ネットワークを介して他のコンピュータよりダウンロードするようにしてもよい。補助記憶装置1002は、インストールされたプログラムを格納すると共に、必要なファイルやデータ等を格納する。
 メモリ装置1003は、プログラムの起動指示があった場合に、補助記憶装置1002からプログラムを読み出して格納する。CPU1004は、メモリ装置1003に格納されたプログラムに従って、ゲートウェイ装置100に係る機能を実現する。インタフェース装置1005は、ネットワーク等に接続するためのインタフェースとして用いられる。表示装置1006はプログラムによるGUI(Graphical User Interface)等を表示する。入力装置1007はキーボード及びマウス、ボタン、又はタッチパネル等で構成され、様々な操作指示を入力させるために用いられる。出力装置1008は演算結果を出力する。
 (付記)
 本明細書には、少なくとも下記各項のゲートウェイ装置、通信方法、及びプログラムが開示されている。
(第1項)
 端末からパケットを受信し、当該パケットに対するアドレス変換を行って、アドレス変換後のパケットをサーバに送信するとともに、前記端末へ送信する応答パケットの一部を事前に計算するアドレス変換部と、
 前記サーバから受信した応答パケットのデータ部と前記一部とを用いて前記端末へ送信する応答パケットを生成するパケット生成部と
 を備えるゲートウェイ装置。
(第2項)
 前記アドレス変換部は、前記端末から受信したパケットにおける変換前の情報、当該情報の変換後の情報、及び、前記一部を示す情報を、前記ゲートウェイ装置が保持するテーブルに格納する
 第1項に記載のゲートウェイ装置。
(第3項)
 前記サーバから受信した応答パケットに基づいて、前記テーブルを検索するテーブル検索部を更に備え、
 前記パケット生成部は、前記テーブル検索部により前記応答パケットに該当するエントリを検出した場合に、当該エントリの情報により指定される前記一部を用いて、前記端末へ送信する応答パケットを生成する
 第2項に記載のゲートウェイ装置。
(第4項)
 前記一部は、前記端末へ送信する応答パケットのIPヘッダを含む
 第1項ないし第3項のうちいずれか1項に記載のゲートウェイ装置。
(第5項)
 前記アドレス変換部は、事前に計算した前記一部を出力キューに格納し、前記パケット生成部は、前記出力キューに格納された前記一部と、前記データ部を用いて、前記端末へ送信する応答パケットを生成する
 第1項ないし第4項のうちいずれか1項に記載のゲートウェイ装置。
(第7項)
 ゲートウェイ装置が実行する通信方法であって、
 端末からパケットを受信し、当該パケットに対するアドレス変換を行って、アドレス変換後のパケットをサーバに送信するとともに、前記端末へ送信する応答パケットの一部を事前に計算するステップと、
 前記サーバから受信した応答パケットのデータ部と前記一部とを用いて前記端末へ送信する応答パケットを生成するステップと
 を備える通信方法。
(第8項)
 コンピュータを、第1項ないし第5項のうちいずれか1項に記載のゲートウェイ装置における各部として機能させるためのプログラム。
 以上、本実施の形態について説明したが、本発明はかかる特定の実施形態に限定されるものではなく、特許請求の範囲に記載された本発明の要旨の範囲内において、種々の変形・変更が可能である。
10、100 ゲートウェイ装置
110 NAPTテーブル
120 アドレス変換部
130 パケット生成部
140 出力キュー
150 出力キュー
160 テーブル検索部
20、200 クライアント端末
30、300 サーバ
1000 ドライブ装置
1001 記録媒体
1002 補助記憶装置
1003 メモリ装置
1004 CPU
1005 インタフェース装置
1006 表示装置
1007 入力装置
1008 出力装置

Claims (7)

  1.  端末からパケットを受信し、当該パケットに対するアドレス変換を行って、アドレス変換後のパケットをサーバに送信するとともに、前記端末へ送信する応答パケットの一部を事前に計算するアドレス変換部と、
     前記サーバから受信した応答パケットのデータ部と前記一部とを用いて前記端末へ送信する応答パケットを生成するパケット生成部と
     を備えるゲートウェイ装置。
  2.  前記アドレス変換部は、前記端末から受信したパケットにおける変換前の情報、当該情報の変換後の情報、及び、前記一部を示す情報を、前記ゲートウェイ装置が保持するテーブルに格納する
     請求項1に記載のゲートウェイ装置。
  3.  前記サーバから受信した応答パケットに基づいて、前記テーブルを検索するテーブル検索部を更に備え、
     前記パケット生成部は、前記テーブル検索部により前記応答パケットに該当するエントリを検出した場合に、当該エントリの情報により指定される前記一部を用いて、前記端末へ送信する応答パケットを生成する
     請求項2に記載のゲートウェイ装置。
  4.  前記一部は、前記端末へ送信する応答パケットのIPヘッダを含む
     請求項1ないし3のうちいずれか1項に記載のゲートウェイ装置。
  5.  前記アドレス変換部は、事前に計算した前記一部を出力キューに格納し、前記パケット生成部は、前記出力キューに格納された前記一部と、前記データ部を用いて、前記端末へ送信する応答パケットを生成する
     請求項1ないし4のうちいずれか1項に記載のゲートウェイ装置。
  6.  ゲートウェイ装置が実行する通信方法であって、
     端末からパケットを受信し、当該パケットに対するアドレス変換を行って、アドレス変換後のパケットをサーバに送信するとともに、前記端末へ送信する応答パケットの一部を事前に計算するステップと、
     前記サーバから受信した応答パケットのデータ部と前記一部とを用いて前記端末へ送信する応答パケットを生成するステップと
     を備える通信方法。
  7.  コンピュータを、請求項1ないし5のうちいずれか1項に記載のゲートウェイ装置における各部として機能させるためのプログラム。
PCT/JP2021/032696 2021-09-06 2021-09-06 ゲートウェイ装置、通信方法、及びプログラム WO2023032210A1 (ja)

Priority Applications (2)

Application Number Priority Date Filing Date Title
PCT/JP2021/032696 WO2023032210A1 (ja) 2021-09-06 2021-09-06 ゲートウェイ装置、通信方法、及びプログラム
JP2023544985A JPWO2023032210A1 (ja) 2021-09-06 2021-09-06

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2021/032696 WO2023032210A1 (ja) 2021-09-06 2021-09-06 ゲートウェイ装置、通信方法、及びプログラム

Publications (1)

Publication Number Publication Date
WO2023032210A1 true WO2023032210A1 (ja) 2023-03-09

Family

ID=85411100

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2021/032696 WO2023032210A1 (ja) 2021-09-06 2021-09-06 ゲートウェイ装置、通信方法、及びプログラム

Country Status (2)

Country Link
JP (1) JPWO2023032210A1 (ja)
WO (1) WO2023032210A1 (ja)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005094050A (ja) * 2003-09-11 2005-04-07 Matsushita Electric Ind Co Ltd パケット転送装置およびパケット転送方法
JP2011103566A (ja) * 2009-11-11 2011-05-26 Hitachi Ltd ゲートウェイ装置およびポート番号割当て方法
JP2012156656A (ja) * 2011-01-24 2012-08-16 Fujitsu Ltd アドレス変換方法、アドレス変換代理応答方法、アドレス変換装置及びアドレス変換代理応答装置

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005094050A (ja) * 2003-09-11 2005-04-07 Matsushita Electric Ind Co Ltd パケット転送装置およびパケット転送方法
JP2011103566A (ja) * 2009-11-11 2011-05-26 Hitachi Ltd ゲートウェイ装置およびポート番号割当て方法
JP2012156656A (ja) * 2011-01-24 2012-08-16 Fujitsu Ltd アドレス変換方法、アドレス変換代理応答方法、アドレス変換装置及びアドレス変換代理応答装置

Also Published As

Publication number Publication date
JPWO2023032210A1 (ja) 2023-03-09

Similar Documents

Publication Publication Date Title
US7158526B2 (en) Packet communication method and apparatus and a recording medium storing a packet communication program
US7957405B2 (en) Packet communication method and apparatus and a recording medium storing a packet communication program
US6453357B1 (en) Method and system for processing fragments and their out-of-order delivery during address translation
CN101217493B (zh) 一种tcp数据包的传输方法
JP2004364141A (ja) Ipアドレス変換装置およびパケット転送装置
WO2017000878A1 (zh) 报文处理
EP2815564A1 (en) Load balancing using dns in a ipv4/ipv6 environment
WO2010108431A1 (zh) 实现IPv6主机访问IPv4主机的方法、获取IPv6地址前缀的方法和转换装置
JP4591893B2 (ja) Tcpトラフィックのフロー特性に基づくキャッシング・ルックアップのための装置及び方法
CN104270475B (zh) 基于NAT64实现IPv4网络与IPv6网络互通的系统及方法
JP2003348173A5 (ja)
JP2013532438A5 (ja)
JP2006287932A (ja) ネットワーク接続テーブルを提供するための方法および装置
CN112671938B (zh) 业务服务提供方法及系统、远端加速网关
US9525661B2 (en) Efficient method of NAT without reassemling IPV4 fragments
CN110752989A (zh) 一种东西向流量转发方法与装置
WO2023032210A1 (ja) ゲートウェイ装置、通信方法、及びプログラム
Sutter et al. Fpga-based tcp/ip checksum offloading engine for 100 gbps networks
JP3017217B1 (ja) IPv4―IPv6変換装置
JP2000270004A (ja) ルータ
CN112165539B (zh) 一种IPv6地址转换方法
Song et al. Adaptive Addresses for Next Generation IP Protocol in Hierarchical Networks
JP4499622B2 (ja) トラフィック分散装置,トラフィック分散プログラム及びパケット中継方法
CN114827078A (zh) 节点访问方法以及数据传输系统
JP3376941B2 (ja) ルータ装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21956095

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2023544985

Country of ref document: JP

NENP Non-entry into the national phase

Ref country code: DE