KR20020067106A - SYSTEM AND METHOD FOR THE AUTOMATIC CONVERSION OF IPv4 TO IPv6 SOCKET API - Google Patents
SYSTEM AND METHOD FOR THE AUTOMATIC CONVERSION OF IPv4 TO IPv6 SOCKET API Download PDFInfo
- Publication number
- KR20020067106A KR20020067106A KR1020010007483A KR20010007483A KR20020067106A KR 20020067106 A KR20020067106 A KR 20020067106A KR 1020010007483 A KR1020010007483 A KR 1020010007483A KR 20010007483 A KR20010007483 A KR 20010007483A KR 20020067106 A KR20020067106 A KR 20020067106A
- Authority
- KR
- South Korea
- Prior art keywords
- code
- application
- network
- token
- ipv4
- Prior art date
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q50/00—Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
- G06Q50/10—Services
Landscapes
- Business, Economics & Management (AREA)
- Tourism & Hospitality (AREA)
- Health & Medical Sciences (AREA)
- Economics (AREA)
- General Health & Medical Sciences (AREA)
- Human Resources & Organizations (AREA)
- Marketing (AREA)
- Primary Health Care (AREA)
- Strategic Management (AREA)
- Physics & Mathematics (AREA)
- General Business, Economics & Management (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer And Data Communications (AREA)
Abstract
IPv4(Internet Protocol version-4) 호스트(10)에서 사용되는 IPv4 애플리케이션이 IPv6 호스트(40)에서 실행될 수 있도록 IPv6 애플리케이션의 소스 코드 변환을 자동으로 수행하는 시스템 및 방법이 제공된다. 본 발명의 시스템 및 방법은 IPv4 호스트(10)으로부터 제공된 IPv4 애플리케이션을 라인 단위로 추출하며, 추출된 각 라인 정보를 문자 단위로 파싱하여 각 라인 정보에 대응하는 일련의 토큰을 생성하고, 소정의 맵핑 테이블(55)에 기초하여, 생성된 각 토큰을 IPv6 애플리케이션에 적합한 코드 형태로 변환한다. 맵핑 테이블(55)은 IPv4 애플리케이션에서 사용되는 IPv4 코드 그룹과, IPv4 코드 그룹의 각 코드에 대응하는 복수의 코드를 갖는 IPv6 코드 그룹을 구비한 것으로, 사용자에 의해 사전에 작성되거나 갱신될 수 있다.A system and method are provided for automatically performing source code conversion of IPv6 applications such that IPv4 applications used on an Internet Protocol version-4 (IPv4) host 10 can run on an IPv6 host 40. The system and method of the present invention extracts the IPv4 application provided from the IPv4 host 10 on a line basis, parses each extracted line information on a character basis to generate a series of tokens corresponding to each line information, and maps a predetermined mapping. Based on the table 55, each generated token is converted into a code form suitable for an IPv6 application. The mapping table 55 includes an IPv4 code group used in an IPv4 application and an IPv6 code group having a plurality of codes corresponding to respective codes of the IPv4 code group. The mapping table 55 may be previously created or updated by a user.
Description
본 발명은 네트웍 통신 프로토콜에 관한 것으로서, 특히, 네트웍 상에서 호스트 사이의 차세대 인터넷 프로토콜 (IPv6) 기반 통신을 원활하게 지원할 수 있는 시스템 및 방법에 관한 것이다.The present invention relates to a network communication protocol, and more particularly, to a system and a method capable of smoothly supporting next generation Internet Protocol (IPv6) based communication between hosts on a network.
현재, 네트웍 상에서 데이터를 전송하는 프로토콜로는 IP 버전이 4.0인 TCP/IP 통신 프로토콜(IPv4)이 주로 사용되고 있다. TCP/IP 프로그램은 주지하는 바와 같이 사용자가 인터넷에 접속하기 위해 자신의 컴퓨터를 실행시킬 때 설치되는 것으로, 이를 통하여 동일한 TCP/IP 통신 프로토콜을 사용하는 다른 컴퓨터 사용자와 메시지를 주고 받거나 또는 정보를 얻을 수 있게 된다. 네트웍 상에서 클라이언트 프로그램과 서버 프로그램 사이의 통신 방법인 소켓 API(Socket Application Program Interface)는 그러한 TCP/IP 프로토콜에 종속적이며 IP 어드레스에 적합하게 구성되어 있다. 주지하는 바와 같이, IP 어드레스는 인터넷과 같은 네트웍 상에서 라우팅을 효율적으로 수행하기 위하여 물리적인 네트웍 주소와 일치하는 개념으로 부여된 32비트의 주소로서, 이러한 IP 주소를 이용하면 네트웍 상의 유일한 호스트를 식별하는 것뿐만 아니라 호스트가 있는 네트웍을 식별할 수 있다.Currently, the TCP / IP communication protocol (IPv4) having an IP version 4.0 is mainly used as a protocol for transmitting data on a network. TCP / IP programs are installed when a user runs his or her computer to access the Internet, as is well known, through which messages can be sent to or received from other computer users using the same TCP / IP communication protocol. It becomes possible. Socket API (Socket Application Program Interface), a method of communication between a client program and a server program on a network, is dependent on such a TCP / IP protocol and is configured for IP address. As is well known, an IP address is a 32-bit address given in the concept of matching a physical network address in order to efficiently perform routing on a network such as the Internet. This IP address identifies a unique host on the network. It can also identify the network on which the host resides.
그러나, 현재의 32비트의 IP 주소 체계로는 전세계의 증가하는 호스트에 주소를 할당하기가 어렵기 때문에, 128비트의 주소 체계를 채용하는 IP 버전이 6.0인 TCP/IP 프로토콜(IPv6)에 대한 연구가 활발하게 진행되고 있다. 즉, IPv6의 주소 체계는 차세대 인터넷을 위한 새로운 주소 방식으로서, 128비트의 주소 체계를 사용함으로 주소 공간을 거의 무제한으로 제공할 수 있다. 이를 위해, 현재의 IPv4 네트웍 상에서 사용되는 IPv4 소켓 API(IPv4용 애플리케이션)가 IPv6 네트웍 상에서 실행되기 위해서는 IPv4 소켓 API를 IPv6 소켓 API로 변환할 필요가 있다.However, the current 32-bit IP address system makes it difficult to assign addresses to an increasing number of hosts around the world. Therefore, a study on the TCP / IP protocol (IPv6) with IP version 6.0 employing a 128-bit address system Is actively underway. In other words, IPv6 addressing system is a new addressing method for next generation internet, and it can provide almost unlimited address space by using 128-bit addressing system. To do this, IPv4 socket APIs (applications for IPv4) used on current IPv4 networks need to be converted to IPv6 socket APIs in order to run on IPv6 networks.
그러한 IPv6 소켓 API 변환을 위한 일 예로서, 미국 선(SUN)사 및 마이크로소프트사에 의해서 개발된 "Socket Scrubber" 및 "Checkv4"로 명명된 제품이 있다. 이들 제품은 IPv4 네트웍으로부터 제공된 IPv4 버전의 디렉토리 및 파일의 소스 코드를 분석하여 IPv6 소스 코드로 변환되어야 할 라인 및 해당 내용을 표시하는 것으로, 사용자는 표시된 해당 라인 및 내용을 참조하여 IPv4 버전의 해당 소스 코드를 IPv6 소스 코드로 변환함으로써 IPv6 네트웍 상에서의 통신이 가능하게 된다.그러나, 전술한 바와 같이, 종래의 IPv6 코드 변환 제품은 IPv6 소스 코드로 변환되어야 할 라인 및 해당 내용만을 표시하여 줌으로써, 사용자가 해당 파일을 직접 열어서 해당 부분을 변환하여 컴파일하여야 하는 번거로움이 있다.As an example for such IPv6 socket API conversion, there are products named "Socket Scrubber" and "Checkv4" developed by Sun Corporation and Microsoft. These products analyze the source code of IPv4 versions of directories and files provided from an IPv4 network to indicate the lines and their contents that need to be converted to IPv6 source code. By converting the code into IPv6 source code, communication on an IPv6 network is possible. However, as described above, the conventional IPv6 code conversion product displays only the lines and the corresponding contents to be converted into the IPv6 source code, so that the user can It is a hassle to open the file and convert the part to compile.
따라서, 본 발명의 주된 목적은, 사전에 등록된 코드 맵핑 테이블을 사용하여 IPv4 네트웍에서 사용되는 IPv4 소켓 API 코드를 IPv6 소켓 API 코드로 자동으로 변환함으로써, IPv4 네트웍에서 사용되는 애플리케이션이 IPv6 네트웍에서도 실행될 수 있도록 하는 IPv6 코드 자동 변환 시스템 및 방법을 제공하는 데에 있다.Therefore, the main object of the present invention is to automatically convert the IPv4 socket API code used in the IPv4 network to the IPv6 socket API code using a pre-registered code mapping table, so that applications used in the IPv4 network can be executed in the IPv6 network. The present invention provides a system and method for automatically converting IPv6 codes.
도 1은 본 발명에 따른 IPv6 코드 자동 변환 시스템을 설명하기 위한 네트웍 구성도.1 is a network configuration for explaining the automatic IPv6 code conversion system according to the present invention.
도 2는 도 1에 도시한 본 발명의 IPv6 코드 자동 변환 시스템의 상세한 블럭도.Figure 2 is a detailed block diagram of the IPv6 code automatic conversion system of the present invention shown in FIG.
도 3은 본 발명에 따라 IPv4 소스 파일의 각 라인으로부터 토큰을 생성하기 위한 과정을 설명하기 위한 도면.3 is a diagram illustrating a process for generating a token from each line of an IPv4 source file according to the present invention.
도 4는 본 발명에 이용되는 맵핑 테이블을 도시한 도면.4 illustrates a mapping table used in the present invention.
도 5 및 도 6은 각각 본 발명에 따른 IPv6 코드 자동 변환 시스템의 동작을 설명하기 위한 흐름도.5 and 6 are flow charts for explaining the operation of the IPv6 code automatic conversion system according to the present invention, respectively.
<도면의 주요 부분에 대한 부호의 설명><Explanation of symbols for the main parts of the drawings>
10: IPv4 호스트10: IPv4 host
20: IPv4 네트웍20: IPv4 Network
30: IPv6 네트웍30: IPv6 network
40: IPv6 호스트40: IPv6 host
50: IPv6 코드 자동 변환 시스템50: IPv6 code automatic conversion system
51: 데이터 판단부51: data judgment unit
52: 라인 추출부52: line extraction unit
53: 토큰 생성부53: token generator
54: 토큰 비교부54: token comparison unit
55: 맵핑 테이블55: mapping table
56: 코드 변환부56: code conversion unit
57: 라인 생성부57: line generator
58: 데이터 출력부58: data output unit
59: 맵핑 테이블 갱신부59: mapping table update unit
상기 목적을 달성하기 위해서, 본 발명에 따른 자동 코드 변환 방법은, 제 1 네트웍에서 사용되는 애플리케이션이 제 2 네트웍에서 실행될 수 있도록 애플리케이션의 코드를 자동으로 변환하는 방법으로서, 제 1 네트웍에서 사용되는 애플리케이션 데이터를 라인 단위로 추출하는 단계, 추출된 애플리케이션 데이터의 각 라인 정보에 대응하는 일련의 토큰을 생성하는 단계 및 소정의 맵핑 테이블에 기초하여 생성된 각 토큰을 제 2 네트웍에서 실행되기에 적합한 코드 형태를 갖는 애플리케이션으로 변환하는 단계를 포함한다.In order to achieve the above object, the automatic code conversion method according to the present invention is a method for automatically converting the code of the application so that the application used in the first network can be executed in the second network, the application used in the first network Extracting data line by line, generating a series of tokens corresponding to each line information of the extracted application data, and code forms suitable to be executed in the second network for each generated token based on a predetermined mapping table Converting to an application having a.
또한, 본 발명의 맵핑 테이블은, 제 1 네트웍의 애플리케이션에서 사용되는 제 1 코드 그룹과, 변환된 애플리케이션에서 사용되며 제 1 코드 그룹의 각 코드에 대응하는 복수의 코드를 갖는 제 2 코드 그룹을 갖는 것으로, 사용자에 의해 사전에 작성되거나 갱신될 수 있다.In addition, the mapping table of the present invention has a first code group used in an application of the first network and a second code group having a plurality of codes used in the converted application and corresponding to each code of the first code group. It can be created or updated in advance by the user.
이하, 본 발명의 바람직한 실시예를 첨부한 도면을 참조하여 상세히 설명한다.Hereinafter, with reference to the accompanying drawings, preferred embodiments of the present invention will be described in detail.
도 1은 본 발명의 IPv6 코드 자동 변환 시스템을 설명하는 데에 이용되는 네트웍 개념도이다. 도 1 에 있어서, 좌측의 복수의 호스트(10)는 32비트의 주소 체계를 이용하는 IPv4 네트웍(20)에 접속되어 IPv4 애플리케이션을 사용한다. 또한, 우측의 복수의 호스트(40)는 128비트의 주소 체계를 이용하는 IPv6 네트웍(30)에 접속되어 IPv4 애플리케이션과 같은 기능을 하는 애플리케이션을 사용한다. 본 발명의 시스템은 IPv4 애플리케이션을 사용하는 각 호스트(10)에 내장되는 것으로, 사전 결정된 코드 변환 테이블을 사용하여 IPv4 네트웍(20)에서 사용되는 IPv4 코드를 IPv6 코드로 자동 변환함으로써, IPv4 네트웍(20)에서의 IPv4 애플리케이션이 IPv6 네트웍(30)에서 실행되도록 하는 기능을 한다.1 is a conceptual diagram of a network used to describe the IPv6 automatic code conversion system of the present invention. In Fig. 1, a plurality of hosts 10 on the left side are connected to an IPv4 network 20 using a 32-bit address system to use IPv4 applications. In addition, the plurality of hosts 40 on the right side are connected to the IPv6 network 30 using the 128-bit address system and use an application that functions as an IPv4 application. The system of the present invention is embedded in each host 10 using an IPv4 application, and by automatically converting an IPv4 code used in the IPv4 network 20 to an IPv6 code using a predetermined code conversion table, the IPv4 network 20 IPv4 application in ()) to run in the IPv6 network (30).
이하, 본 발명의 IPv6 코드 자동 변환 시스템(50)의 동작 및 기능에 대하여 도 1 및 도 2를 참조하여 상세히 설명한다.Hereinafter, operations and functions of the IPv6 automatic code conversion system 50 of the present invention will be described in detail with reference to FIGS. 1 and 2.
도 2는 본 발명에 따른 IPv6 코드 자동 변환 시스템(50)의 개략적인 블럭도로서, 데이터 판단부(51), 라인 추출부(52), 토큰 생성부(53), 토큰 비교부(54), 맵핑 테이블(55), 코드 변환부(56), 라인 생성부(57), 데이터 출력부(58) 및 맵핑 테이블 갱신부(59)를 포함한다.2 is a schematic block diagram of an IPv6 automatic code conversion system 50 according to the present invention, a data determining unit 51, a line extracting unit 52, a token generating unit 53, a token comparing unit 54, It includes a mapping table 55, a code converter 56, a line generator 57, a data output unit 58, and a mapping table updater 59.
데이터 판단부(51)는 IPv4 네트웍(20)으로부터 변환 대상으로서 제공된 IPv4 입력 데이터가 파일 또는 디렉토리인지를 판단한다. 즉, 데이터 판단부(51)는 입력 데이터가 파일인 경우는 해당 입력 파일을 라인 추출부(52)에 전송하고, 디렉토리인 경우는 입력 디렉토리 내에 파일이 존재하는지를 판단하고, 파일이 존재하면, 해당 파일을 라인 추출부(52)에 전송한다.The data determination unit 51 determines whether the IPv4 input data provided as a conversion target from the IPv4 network 20 is a file or a directory. That is, if the input data is a file, the data determination unit 51 transmits the input file to the line extracting unit 52, and if the directory is a directory, determines whether the file exists in the input directory. The file is transmitted to the line extraction unit 52.
라인 추출부(52)는 데이터 판단부(51)로부터 입력된 파일의 내용을 라인별로 추출하여 순차적으로 토큰 생성부(53)에 전송한다.The line extracting unit 52 extracts the contents of the file input from the data determining unit 51 for each line and sequentially transmits the contents of the file to the token generating unit 53.
토큰 생성부(53)는 라인 추출부(52)로부터 제공된 각 라인 정보를 한 문자씩 읽어 들여, 해당 문자가 변수 또는 함수 스트럭쳐에 사용되는 문자인지 연산자나 기타 문자인지를 파싱(parsing)하여 각 라인에 대응하는 토큰(token)을 생성한다. 주지하는 바와 같이, 토큰은 문법적으로 더 이상 나눌 수 없는 기본적인 언어 요소로서 하나의 키워드, 연산자 또는 구두점이 될 수 있다. 일반적으로, C, C++ 등의 프로그래밍 언어에서 사용하는 변수, 상수, 데이터 타입 등은 a∼z, A∼Z, 0∼9, _ 등의 문자만을 사용할 수 있고, 이들 문자는 ASCⅡ 코드로서 설정되어 있다. 즉, 토큰 생성부(53)는 이러한 ASCⅡ 코드를 저장한 내부 메모리(도시하지 않음)를 이용하여 파싱된 각 문자가 a∼z, A∼Z, 0∼9, _ 의 ASCⅡ 코드에 존재하는지를 판단하고, 존재하면, 토큰으로서 결정하고, 그렇치 않으면, 기타 문자로 분류하여 새로운 토큰을 생성한다.The token generating unit 53 reads each line information provided by the line extracting unit 52 by one character, and parses each line as whether the corresponding character is a character used in a variable or function structure, an operator, or other character. Create a token corresponding to. As will be appreciated, tokens can be a keyword, operator or punctuation as a basic language element that can no longer be grammatically divided. In general, variables, constants, data types, and the like used in programming languages such as C and C ++ can use only characters a to z, A to Z, 0 to 9, _, and these characters are set as ASCII codes. have. That is, the token generating unit 53 determines whether each character parsed is present in the ASCII codes of a to z, A to Z, 0 to 9, _ using an internal memory (not shown) that stores such ASCII codes. If present, it is determined as a token, otherwise it is classified by other characters to generate a new token.
예를 들면, 라인 추출부(52)에 의해 추출된 하나의 라인 정보가 s=socket(AF_INET, SOCK_STREAM,0)인 경우, 토큰 생성부(53)는 도 3에 도시한 바와 같은 방식으로 추출된 해당 라인에 대한 토큰 정보를 생성한다. 즉, 도 3에 도시한 바와 같이, 토큰 생성부(53)는 우선 s=socket(AF_INET, SOCK_STREAM,0) 중에서 "s"에 대한 ASCⅡ 코드가 내부 메모리에 존재하는지를 판단한다. 다음에, 토큰 생성부(53)는 "s"에 후속하는 "="의 ASCⅡ 코드가 내부 메모리에 존재하는지를 판단하고, "="의 ASCⅡ 코드가 없으면, "s"를 제 1 토큰으로서 생성하고 다음의 토큰 생성을 위해 리셋된다. 이러한 방식으로, 토큰 생성부(53)는 "="에 후속하는 일련의 s, o, c, k, e, t에 대한 ASCⅡ 코드가 내부 메모리에 존재하는지를 판단한 후, "t"에 후속하는 "("의 ASCⅡ 코드가 내부 메모리에 존재하는지를 판단한다. "("의 ASCⅡ 코드가 없으면, 토큰 생성부(53)는 "socket"를 제 2 토큰으로서 생성하고 전술한 바와 같은 다음의 토큰 생성을 위해 리셋된다. 마찬가지로, 토큰 생성부(53)는 "("에 후속하는 일련의 "A", "F", "_", "I", "N", "E", "T" 및 ","의 ASCⅡ 코드 판단 과정을 수행하여 "AF_INET"를 제 3 토큰으로서 생성한다. 이와 같은 방식으로, 토큰 생성부(53)는 "SOCK_STREAM"을 제 4 토큰으로서, "0"를 제 5 토큰으로서 생성한다.For example, when one line information extracted by the line extracting unit 52 is s = socket (AF_INET, SOCK_STREAM, 0), the token generating unit 53 is extracted in the manner as shown in FIG. Generate token information for the line. That is, as shown in FIG. 3, the token generating unit 53 first determines whether an ASCII code for "s" exists in the internal memory among s = socket (AF_INET, SOCK_STREAM, 0). Next, the token generating unit 53 judges whether the ASCII code of "=" following "s" exists in the internal memory, and if there is no ASCII code of "=", generates "s" as the first token. Reset for the next token generation. In this way, the token generating unit 53 determines whether the ASCII codes for the series of s, o, c, k, e, and t following "=" exist in the internal memory, and then "" following the "t". It is determined whether the ASCII code of "" exists in the internal memory. If there is no ASCII code of "(", the token generating unit 53 generates "socket" as the second token and generates the next token as described above. Similarly, the token generating unit 53 is a series of "A", "F", "_", "I", "N", "E", "T" and "," following "(". ASCII code determination process of "" is performed to generate "AF_INET" as the third token. In this manner, the token generator 53 generates "SOCK_STREAM" as the fourth token and "0" as the fifth token. do.
즉, 추출된 라인 정보 s=socket(AF_INET, SOCK_STREAM, 0)에 있어서 "=", "(", ",", ",", ")"는 토큰 생성부(53)의 내부 메모리에 저장된 ASCⅡ 코드에 없는 문자 코드로서, 새로운 토큰을 생성하기 위한 리셋 코드로서 이용된다. 그 결과, 도 3에 도시한 바와 같이, 추출된 라인 정보 s=socket(AF_INET, SOCK_STREAM, 0)에서의 토큰은 "s", "socket", "AF_INET", "SOCK_STREAM", "0"의 5개임을 알 수 있다. 해당 라인에 대응하는 5개의 토큰 정보는 토큰 비교부(54)에 전송된다.That is, in the extracted line information s = socket (AF_INET, SOCK_STREAM, 0), "=", "(", ",", ",", ")" is the ASCII stored in the internal memory of the token generating unit 53. As a character code not in the code, it is used as a reset code to generate a new token. As a result, as shown in Fig. 3, the token in the extracted line information s = socket (AF_INET, SOCK_STREAM, 0) is 5 of "s", "socket", "AF_INET", "SOCK_STREAM", and "0". You can see the game. Five token information corresponding to the line is transmitted to the token comparison unit 54.
본 발명의 맵핑 테이블(55)은 도 4에 도시한 바와 같이 각 IPv4 소켓 API와 그에 대응하는 IPv6 소켓 API 정보를 저장한 것으로, 본 발명의 코드 변환 기능을 제공하는 운영자에 의해 사전에 등록될 수 있다. 도 4의 맵핑 테이블에서, 좌측리스트(60)는 IPv4 소켓 API에 대응하는 사전 등록된 IPv4 키 데이터를 나타내고, 우측 리스트(70)는 IPv6 소켓 API에 대응하는 사전 등록된 IPv6 키 데이터를 나타낸다. 본 발명에 따르면, 사용자는 도 2의 맵핑 테이블 갱신부(59)를 사용하여 맵핑 테이블(55)에 저장된 맵핑 정보를 갱신할 수 있다. 즉, 맵핑 테이블(55)에 저장된 맵핑 정보는 사용자에 의해 추가, 삭제 또는 편집될 수 있다.The mapping table 55 of the present invention stores each IPv4 socket API and corresponding IPv6 socket API information as shown in FIG. 4, and may be registered in advance by an operator providing a code conversion function of the present invention. have. In the mapping table of FIG. 4, the left list 60 represents pre-registered IPv4 key data corresponding to the IPv4 socket API, and the right list 70 represents pre-registered IPv6 key data corresponding to the IPv6 socket API. According to the present invention, the user may update the mapping information stored in the mapping table 55 by using the mapping table updater 59 of FIG. 2. That is, mapping information stored in the mapping table 55 may be added, deleted or edited by the user.
맵핑 테이블(55)에 접속된 토큰 비교부(54)는 토큰 생성부(53)로부터 입력된 각 토큰 정보를 맵핑 테이블(55)의 좌측 리스트(60)에서의 IPv4 키 데이터와 비교한다. 비교 결과, IPv4 키 데이터에 속하는 토큰 정보가 존재하면, 토큰 비교부(54)는 해당 토큰 정보(즉, AF_INET)와 그에 일치하는 IPv4 키 데이터를 코드 변환부(56)에 전송한다. 한편, IPv4 키 데이터에 속하지 않은 토큰 정보가 존재하는 경우는, 해당 토큰 정보(즉, s, socket, SOCK_STREAM, 0)만을 코드 변환부(56)에 전송한다.The token comparing unit 54 connected to the mapping table 55 compares each token information input from the token generating unit 53 with IPv4 key data in the left list 60 of the mapping table 55. As a result of the comparison, if there is token information belonging to the IPv4 key data, the token comparison unit 54 transmits the corresponding token information (that is, AF_INET) and IPv4 key data corresponding thereto to the code conversion unit 56. On the other hand, if there is token information that does not belong to the IPv4 key data, only the token information (that is, s, socket, SOCK_STREAM, 0) is transmitted to the code conversion unit 56.
토큰 비교부(54) 및 맵핑 테이블(55)에 접속된 코드 변환부(56)는 토큰 비교부(54)로부터의 비교 결과 정보에 기초하여 IPv6 코드 변환을 수행한다. 즉, 코드 변환부(56)는 도 4에 도시한 맵핑 데이터를 참조하여 IPv4 소켓 API의 토큰 정보 "AF_INET"를 IPv6 소켓 API의 "AF_INET6"로 변환하고, 그 외의 토큰 정보는 변환하지 않고 출력한다.The code conversion unit 56 connected to the token comparison unit 54 and the mapping table 55 performs IPv6 code conversion based on the comparison result information from the token comparison unit 54. That is, the code conversion unit 56 converts the token information "AF_INET" of the IPv4 socket API into "AF_INET6" of the IPv6 socket API with reference to the mapping data shown in FIG. 4, and outputs other token information without conversion. .
라인 생성부(57)는 코드 변환부(56)로부터 출력된 코드 변환 정보에 기초하여, 라인 추출부(52)에 의해 추출된 1라인 정보에 대응하는 1라인의 IPv6 소켓 API 데이터(즉, s=socket(AF_INET6, SOCK_STREAM, 0)를 생성하여 데이터 출력부(58)에전송한다. 데이터 출력부(58)는 라인 생성부(57)로부터 입력된 1라인의 IPv6 소켓 API 데이터를 입력 파일의 모든 라인에 대한 IPv6 소켓 API 데이터가 모드 입력될 때까지 일시 저장한다.The line generation unit 57, based on the code conversion information output from the code conversion unit 56, IPv6 socket API data of one line corresponding to the one line information extracted by the line extraction unit 52 (that is, s = socket (AF_INET6, SOCK_STREAM, 0) is generated and sent to the data output unit 58. The data output unit 58 transmits one line of IPv6 socket API data input from the line generation unit 57 to all of the input files. Temporarily store the IPv6 socket API data for a line until the mode is entered.
IPv4 네트웍(20)으로부터 변환 대상으로서 제공된 입력 파일의 다음 라인의 IPv4 소켓 API 데이터에 대한 코드 변환 과정은 전술한 바와 같은 방식으로 수행되므로, 그에 대한 상세한 설명은 생략한다. 이와 같이 하여, IPv4 네트웍(20)으로부터 제공된 입력 파일의 모든 라인에 대한 코드 변환 과정이 종료되고, 변환된 각 라인 정보는 데이터 출력부(58)에 저장된다.Since the code conversion process for the IPv4 socket API data of the next line of the input file provided as the conversion target from the IPv4 network 20 is performed in the same manner as described above, a detailed description thereof will be omitted. In this way, the code conversion process for all the lines of the input file provided from the IPv4 network 20 is terminated, and each converted line information is stored in the data output unit 58.
본 발명의 IPv6 코드 자동 변환 시스템(50)의 데이터 출력부(58)는 저장된 복수의 라인으로 이루어지는 변환된 IPv6 소켓 API 데이터를 이용하여 IPv6 네트웍(30) 상에서 실행될 IPv6 애플리케이션을 생성한다. 이와 같이 하여, IPv6 네트웍(30)에 접속된 모든 호스트(40)는 변환된 애플리케이션을 이용함으로써 IPv4에 기초한 프로그램 등을 실행시킬 수 있다. 본 발명에 따라 IPv6 코드로 변환된 IPv6 소켓 API 프로그램은, 콤팩트 디스크와 같은 기록 매체 또는 통신 네트웍을 통하여 IPv6 소켓 API를 사용하는 다수의 호스트에게 배포될 수 있음은 물론이다.The data output unit 58 of the IPv6 automatic code conversion system 50 of the present invention generates an IPv6 application to be executed on the IPv6 network 30 using the converted IPv6 socket API data consisting of a plurality of stored lines. In this way, all the hosts 40 connected to the IPv6 network 30 can execute the IPv4 based program or the like by using the converted application. The IPv6 socket API program converted to the IPv6 code according to the present invention can be distributed to a plurality of hosts using the IPv6 socket API through a recording medium such as a compact disk or a communication network.
또한, 본 발명에 따르면, IPv4 네트웍(20)에서 사용되는 IPv4 애플리케이션을 IPv6 애플리케이션으로 자동으로 변환하는 것에 대해서 설명하였지만, 전술한 코드 맵핑 테이블을 이용하여 IPv4 네트웍(30)에서 사용되는 IPv6 애플리케이션을 IPv4 애플리케이션으로 변환함으로써, IPv6 네트웍에서 사용되는 애플리케이션이 IPv4 네트웍에서도 실행될 수 있는 것은 물론이다.In addition, according to the present invention, a description has been made of automatically converting an IPv4 application used in the IPv4 network 20 to an IPv6 application, but the IPv6 application used in the IPv4 network 30 may be IPv4 using the above-described code mapping table. Of course, by converting to an application, an application used on an IPv6 network can also run on an IPv4 network.
도 5 및 도 6은 각각 본 발명에 따른 IPv6 코드 자동 변환 시스템의 동작을 설명하기 위한 흐름도이다.5 and 6 are flowcharts for explaining the operation of the IPv6 code automatic conversion system according to the present invention, respectively.
도 5의 단계 S1에서, IPv4 네트웍(20)으로부터 변환 대상인 IPv4 데이터가 데이터 판단부(51)에 입력된다. 단계 S2에서 데이터 판단부(51)에 의해 입력 데이터가 디렉토리 또는 파일인지에 대한 판단이 수행된다. 입력 데이터가 디렉토리가 아닌 경우, 본 발명의 프로세스는 입력 데이터를 소스 파일로 판단하여 탭 A를 통해 도 6의 단계 S6으로 진행하고(후술함), 입력 데이터가 디렉토리인 경우는 단계 S3에서 디렉토리 내에 파일이 존재하는지를 판단한다. 단계 S4에서 파일이 존재하면, 해당 파일이 소스 파일인지를 판단한다. 해당 파일이 소스 파일이면, 탭 A를 경유하여 도 6의 단계 S6으로 진행하고(후술함), 그렇치 않으면, 단계 S5에서 해당 파일을 복사하고 단계 S3으로 복귀하여 디렉토리 내에 다른 파일에 대하여 본 발명의 프로세스를 전술한 바와 같이 수행한다.In step S1 of FIG. 5, IPv4 data to be converted from the IPv4 network 20 is input to the data determination unit 51. In step S2, the data determining unit 51 determines whether the input data is a directory or a file. If the input data is not a directory, the process of the present invention judges the input data as a source file and proceeds to step S6 of FIG. 6 through tab A (to be described later), and if the input data is a directory, in the directory at step S3. Determine if the file exists. If the file exists in step S4, it is determined whether the file is a source file. If the file is a source file, then proceed to step S6 of FIG. 6 via tab A (to be described later); otherwise, copy the file in step S5 and return to step S3 to find another file in the directory. The process is carried out as described above.
도 6의 단계 S6에서, 본 발명의 프로세스는 소스 파일 및 해당 소스 파일이 변환될 타겟 파일을 오픈한다. 단계 S7에서는 소스 파일의 내용을 라인별로 추출하여 순차적으로 출력한다. 단계 S8에서 본 발명의 프로세스는 추출된 라인이 소스 파일의 마지막 라인인지를 판단하고, 마지막 라인이 아닌 경우, 단계 S9에서 추출된 각 라인의 정보를 한 문자씩 읽어 들여, 해당 문자가 변수 또는 함수 스트럭쳐에 사용되는 문자인지 연산자나 기타 문자인지를 파싱(parsing)하여 각 라인에 대응하는 토큰(token)을 전술한 바와 같은 방식으로 생성한다.In step S6 of FIG. 6, the process of the present invention opens a source file and a target file to which the source file is to be converted. In step S7, the contents of the source file are extracted line by line and sequentially output. In step S8, the process of the present invention determines whether the extracted line is the last line of the source file, and if it is not the last line, reads information of each line extracted in step S9 by one character, and the character is a variable or function. Parses the character, operator, or other character used in the structure to generate a token corresponding to each line in the manner described above.
단계 S10에서, 생성된 각 토큰이 사전 등록된 맵핑 테이블에 존재하는지를판단하고, 존재하면, 해당 토큰을 IPv4 코드로서 판단하고, 그렇치 않으면, 단계 S12로 진행한다. 단계 S11에서 IPv4 코드로 판단된 토큰은 사전 등록된 맵핑 테이블에 기초하여 그에 대응하는 IPv6 코드로 변환되고, IPv4 코드에 해당하지 않는 토큰은 그대로 출력되며 단계 S12에서 IPv6 코드로 변환된 1라인의 정보가 생성된다. 그 후, 단계 S13에서 본 발명의 프로세스는 IPv6 코드로 변환된 1라인의 정보에 기초하여 타겟 파일의 1라인을 작성하고, 소스 파일의 모든 라인에 대한 정보가 입력될 때 까지 일시 저장한다.In step S10, it is determined whether each generated token exists in the pre-registered mapping table, and if present, the corresponding token is determined as an IPv4 code, otherwise, the flow goes to step S12. The token determined as an IPv4 code in step S11 is converted into an IPv6 code corresponding to it based on the pre-registered mapping table, and a token that does not correspond to the IPv4 code is output as it is. Is generated. Then, in step S13, the process of the present invention creates one line of the target file based on one line of information converted into an IPv6 code, and temporarily stores it until information on all the lines of the source file is input.
다음에, 본 발명의 프로세스는 단계 S7로 복귀하여 소스 파일의 다음 라인에 대한 정보를 추출하고 전술한 바와 같은 단계 S8 내지 단계 S13을 반복하여 수행한다. 이와 같이 하여, IPv4 네트웍(20)으로부터 제공된 소스 파일의 모든 라인에 대한 코드 변환 과정이 종료되고 IPv6 코드의 타겟 파일이 작성되면, 소스 파일 및 타겟 파일을 닫고 본 발명의 프로세스는 종료된다.Next, the process of the present invention returns to step S7 to extract information on the next line of the source file, and repeats steps S8 to S13 as described above. In this way, when the code conversion process for all the lines of the source file provided from the IPv4 network 20 is finished and the target file of the IPv6 code is created, the source file and the target file are closed and the process of the present invention is terminated.
본 발명에 따르면, IPv4 코드의 IPv6 코드로의 변환 과정시, 사전 등록된 맵핑 테이블에 기초하여 IPv6 코드로 변환된 내용 및/또는 멥핑 테이블에 사전에 등록되지 않음으로 인해 IPv6 코드로 변환되어야 할 내용을 화면 상에서 표시할 수 있다. 그에 따라, 사용자는 맵핑 테이블에 등록되지 않은 정보를 화면 상에서 용이하게 편집하거나 맵핑 테이블에 새로이 등록할 수 있다. 또한, 본 발명은 옵션으로서 미국 선(SUN)사의 솔라리스(Solaris) 또는 마이크로소프트사의 윈도우(Window) 및 리눅스(Linux)와 같은 다양한 운영 체제(OS) 상에서 사용되는 IPv4 애플리케이션이 IPv6 네트웍에서 실행될 수 있도록 자동 코드 변환 기능을 제공할 수 있다.According to the present invention, in the process of converting an IPv4 code into an IPv6 code, content to be converted to an IPv6 code based on a pre-registered mapping table and / or content to be converted to an IPv6 code because it is not registered in advance in the shopping table. Can be displayed on the screen. Accordingly, the user can easily edit on the screen information not registered in the mapping table or newly register the mapping table. In addition, the present invention provides an option to allow IPv4 applications used on various operating systems (OS), such as Solaris from US Sun or Microsoft's Windows and Linux, to run on an IPv6 network. It can provide automatic code conversion.
상기에 있어서, 본 발명의 바람직한 실시예에 대해서 설명하였는데, 본 발명의 특허 청구 범위를 이탈하지 않으면서 당업자는 다양한 변경을 행할 수 있음은 물론이다.As mentioned above, although preferred embodiment of this invention was described, those skilled in the art can change variously, without deviating from the claim of this invention.
따라서, 본 발명에 따르면, 사전에 등록된 코드 맵핑 테이블을 사용하여 IPv4 네트웍에서 사용되는 IPv4 소켓 API 코드를 IPv6 소켓 API 코드로 자동으로 변환함으로써, IPv4 네트웍에서 사용되는 IPv4 애플리케이션이 IPv6 네트웍에서도 용이하게 실행될 수 있도록 지원할 수 있다.Therefore, according to the present invention, by automatically converting the IPv4 socket API code used in the IPv4 network to the IPv6 socket API code using a pre-registered code mapping table, IPv4 applications used in the IPv4 network can be easily used in the IPv6 network. It can be supported to run.
Claims (13)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020010007483A KR20020067106A (en) | 2001-02-15 | 2001-02-15 | SYSTEM AND METHOD FOR THE AUTOMATIC CONVERSION OF IPv4 TO IPv6 SOCKET API |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020010007483A KR20020067106A (en) | 2001-02-15 | 2001-02-15 | SYSTEM AND METHOD FOR THE AUTOMATIC CONVERSION OF IPv4 TO IPv6 SOCKET API |
Publications (1)
Publication Number | Publication Date |
---|---|
KR20020067106A true KR20020067106A (en) | 2002-08-22 |
Family
ID=27694441
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020010007483A KR20020067106A (en) | 2001-02-15 | 2001-02-15 | SYSTEM AND METHOD FOR THE AUTOMATIC CONVERSION OF IPv4 TO IPv6 SOCKET API |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR20020067106A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP1562348B1 (en) * | 2004-02-06 | 2008-04-02 | Samsung Electronics Co., Ltd. | Method and Apparatus for Connecting Heterogeneous Protocol Nodes |
-
2001
- 2001-02-15 KR KR1020010007483A patent/KR20020067106A/en not_active Application Discontinuation
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP1562348B1 (en) * | 2004-02-06 | 2008-04-02 | Samsung Electronics Co., Ltd. | Method and Apparatus for Connecting Heterogeneous Protocol Nodes |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7401086B2 (en) | Translating configuration files among network devices | |
JP3295667B2 (en) | Method and system for accessing information on a network | |
JP3492580B2 (en) | Multilingual domain name service | |
JP3272014B2 (en) | Method and apparatus for creating a data processing dictionary including hierarchical data processing information | |
US6519626B1 (en) | System and method for converting a file system path into a uniform resource locator | |
US6560596B1 (en) | Multiscript database system and method | |
KR20010103670A (en) | Method and system for accessing information on a network using message aliasing functions having shadow callback functions | |
US7272792B2 (en) | Kana-to-kanji conversion method, apparatus and storage medium | |
JPH10326255A (en) | Method for handling message independent of language | |
US20020029204A1 (en) | Computer architecture using self-manipulating trees | |
KR20050103192A (en) | Method and apparatus for local ip address translation | |
JPH1196016A (en) | GDMO translator, GDMO translation method, and recording medium recording GDMO translator program | |
TWI494010B (en) | Internet domain name super variants | |
WO2000000897A1 (en) | Function expanding device and function expanding method | |
KR20020067106A (en) | SYSTEM AND METHOD FOR THE AUTOMATIC CONVERSION OF IPv4 TO IPv6 SOCKET API | |
CN114285823B (en) | DNS system-based universal network identification analysis method and system | |
JP3489216B2 (en) | File system | |
KR100598341B1 (en) | How to manage Internet Protocol (IP) address information in database using binary notation string | |
AU654721B2 (en) | Routing of messages in a data processing system | |
JP2007122398A (en) | Method for determining identity of fragment, and computer program | |
JP5557469B2 (en) | Character search device, character search system, character search method, input terminal device, search server, and program | |
JP2009070206A (en) | Data retrieval system, data retrieval method, data retrieval device, retrieval executer terminal and program | |
JPH08194611A (en) | A device that analyzes the range of influence of program modification | |
JPH0730575A (en) | Router with address translation function | |
JP3390471B2 (en) | Specification generator |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A201 | Request for examination | ||
PA0109 | Patent application |
Patent event code: PA01091R01D Comment text: Patent Application Patent event date: 20010215 |
|
PA0201 | Request for examination | ||
PG1501 | Laying open of application | ||
E902 | Notification of reason for refusal | ||
PE0902 | Notice of grounds for rejection |
Comment text: Notification of reason for refusal Patent event date: 20030925 Patent event code: PE09021S01D |
|
E601 | Decision to refuse application | ||
PE0601 | Decision on rejection of patent |
Patent event date: 20040129 Comment text: Decision to Refuse Application Patent event code: PE06012S01D Patent event date: 20030925 Comment text: Notification of reason for refusal Patent event code: PE06011S01I |