KR20210037895A - Secure coding system and method thereof - Google Patents
Secure coding system and method thereof Download PDFInfo
- Publication number
- KR20210037895A KR20210037895A KR1020190120363A KR20190120363A KR20210037895A KR 20210037895 A KR20210037895 A KR 20210037895A KR 1020190120363 A KR1020190120363 A KR 1020190120363A KR 20190120363 A KR20190120363 A KR 20190120363A KR 20210037895 A KR20210037895 A KR 20210037895A
- Authority
- KR
- South Korea
- Prior art keywords
- code
- client computer
- function
- secure coding
- attack
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/50—Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
- G06F21/55—Detecting local intrusion or implementing counter-measures
- G06F21/56—Computer malware detection or handling, e.g. anti-virus arrangements
- G06F21/562—Static detection
- G06F21/563—Static detection by source code analysis
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/50—Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
- G06F21/57—Certifying or maintaining trusted computer platforms, e.g. secure boots or power-downs, version controls, system software checks, secure updates or assessing vulnerabilities
- G06F21/577—Assessing vulnerabilities and evaluating computer system security
Landscapes
- Engineering & Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Computer Hardware Design (AREA)
- General Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Physics & Mathematics (AREA)
- Virology (AREA)
- Health & Medical Sciences (AREA)
- General Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- Computer And Data Communications (AREA)
Abstract
Description
본 발명은 시큐어 코딩(Secure Coding) 시스템 및 방법에 관한 것으로, 특히 클라이언트 컴퓨터로부터 코드를 작성하여 웹서버에 전송하면 해당 코드를 기초로 JSP(Java Server Pages) 파일을 생성하고 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트(Redirect)시킨 후, 클라이언트 컴퓨터가 공격 코드 또는 시큐어 코딩이 적용된 코드를 코드가 적용된 기능(예컨대, 게시판 또는 로그인창)에 삽입하여 전송하면 웹서버에서는 코드가 적용된 기능에 해킹 정보를 삽입하거나 또는 해킹 정보를 삽입하지 않고 클라이언트 컴퓨터에 전달하여 시큐어 코딩과정을 실습할 수 있게 하는 시큐어 코딩 시스템 및 방법에 관한 것이다. The present invention relates to a secure coding system and method. In particular, when a code is created from a client computer and transmitted to a web server, a JSP (Java Server Pages) file is generated based on the code, and the JSP generated by the client computer is generated. After redirecting to a file, the client computer inserts the attack code or secure coded code into the code-applied function (e.g., bulletin board or login window) and transmits it, and the web server inserts hacking information into the code-applied function. The present invention relates to a secure coding system and method for practicing a secure coding process by transferring the information to a client computer without inserting or inserting hacking information.
기존의 네트워크에서 진행되는 취약점 점검은 패킷을 스니핑(sniffing)하거나 열려진 포트에 접근하여 대상 시스템에서 동작하는 소프트웨어 버전 정보를 식별하고 식별된 버전 정보를 이용하여 취약점 정보 데이터베이스(CVE, NVD, ETC 등)에 조회하여 취약 여부를 확인한다.Vulnerability checks in the existing network include sniffing packets or accessing an open port to identify software version information running on the target system, and use the identified version information to identify vulnerability information databases (CVE, NVD, ETC, etc.) Check whether it is vulnerable by referring to.
특정 소프트웨어 버전이 취약한 것으로 판명된 경우 이에 대한 정보를 대상 시스템으로 알리고, 대상 시스템은 취약한 버전으로 판명된 경우 후속 조치를 취하도록 구성된다.If a specific software version is found to be vulnerable, information about it is notified to the target system, and if the target system is found to be a vulnerable version, it is configured to take follow-up measures.
하지만, 최근에는 소프트웨어의 버전이 외부에 노출되지 않는 경우가 많아 기존 방식으로는 제대로 된 취약점 점검을 진행할 수 없다. 더욱이 네트워크를 사용하지 않는 소프트웨어는 취약점 점검이 용이치 않다. 예를 들어 문서 편집 소프트웨어 등은 그 동작 과정에서 네트워크를 활용하지 않아서 취약점 점검이 매우 어려운 실정이다.However, in recent years, the version of the software is not exposed to the outside in many cases, so it is not possible to properly check for vulnerabilities with the existing method. Moreover, it is not easy to check for vulnerabilities in software that does not use the network. For example, document editing software, etc., do not use the network in the process of operation, so it is very difficult to check vulnerabilities.
취약점을 공격하는 파일들은 메일, HTTP 등과 같은 네트워크 프로토콜을 통해서 내부에 유입되고 이 파일들이 실행되는 경우에 대응하는 소프트웨어의 취약점 공격을 통해 대상 시스템을 해킹하거나 공격하거나 중요 정보를 추출할 수 있다.Files that attack the vulnerability are introduced into the inside through network protocols such as e-mail and HTTP, and when these files are executed, they can hack or attack the target system or extract important information through a vulnerability attack of the corresponding software.
따라서 악의적인 파일의 오픈 이전에 이 파일을 실행하는 소프트웨어의 취약점 점검이 필요하고 특히 네트워크를 통해 유입되는 파일의 실행 이전에 이 파일을 수행하는 소프트웨어에 대한 동적 취약점 점검 방안이 필요하다.Therefore, it is necessary to check the vulnerabilities of the software that executes this file before opening the malicious file, and in particular, it is necessary to check the dynamic vulnerability of the software that executes this file before the execution of the file that flows through the network.
이와 같은 필요성에 의해 국내 특허 공개 2019-0090436호 공보(이하, 인용 문헌이라 함)에는 파일을 실행하는 소프트웨어의 취약점을 소프트웨어 버전 확인 없이 모의 공격용 파일을 통해 점검할 수 있는 취약점 점검 장치, 방법 및 시스템이 개시되어 있다.Due to this necessity, Korean Patent Publication No. 2019-0090436 (hereinafter referred to as cited literature) discloses a vulnerability inspection device, method, and system that can check vulnerabilities of software executing files through a simulated attack file without checking the software version. Is disclosed.
그러나 인용문헌은 호스트 기기에 의해 실행되는 소프트웨어에 대한 점검을 위한 모의공격 파일을 호스트 기기에 전달하여 분석하게 하는 방식이므로, 점검하고자 하는 소프트웨어 별로 모의공격 파일을 작성하여 분석해야 하는 번거러움이 있었으며 이를 위한 개발환경이 필요하므로 개발비용이 많이 든다는 문제점이 있었다. However, since the cited literature is a method of sending a simulated attack file for checking the software executed by the host device to the host device for analysis, there was a hassle of creating and analyzing a simulated attack file for each software to be checked. There is a problem that development costs are high because a development environment is required.
따라서 본 발명은 상기와 같은 종래의 문제점을 해결하기 위해 이루어진 것으로서, 본 발명의 목적은 소프트웨어 별로 모의공격 파일을 작성하여 분석하기 위한 개발환경이 필요 없이 간단하게 웹페이지에 접속하여 취약점 방어 실습을 할 수 있게 하는 시큐어 코딩 시스템 및 방법을 제공하는 데에 있다.Therefore, the present invention has been made to solve the conventional problems as described above, and an object of the present invention is to perform vulnerability defense practice by simply accessing a web page without the need for a development environment for creating and analyzing a mock attack file for each software. It is to provide a secure coding system and method to enable it.
상기의 목적을 달성하기 위해 본 발명의 실시형태에 의한 시큐어 코딩 시스템은 코드 작성툴을 이용하여 코드를 작성하여 전송하고, 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드를 삽입하여 전송하며, 코드가 적용된 기능에 해킹 정보가 삽입되거나 또는 삽입되지 않은 화면을 디스플레이 하도록 구성된 클라이언트 컴퓨터; 및 상기 클라이언트 컴퓨터에 코드 작성툴을 제공하여 작성된 코드를 수신하면 해당 코드를 기초로 동적으로 JSP(Java Server Pages) 파일을 생성하고, 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트(Redirect)시킨 후, 상기 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되면, 상기 코드가 적용된 기능에 해킹 정보를 삽입하거나 또는 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하도록 구성된 웹서버;를 포함하는 것을 특징으로 한다.In order to achieve the above object, the secure coding system according to the embodiment of the present invention writes and transmits a code using a code writing tool, and inserts and transmits an attack code or a code to which secure coding is applied to a function to which the code is applied, A client computer configured to display a screen in which hacking information is inserted or not inserted into the function to which the code is applied; And upon receiving the code written by providing the code writing tool to the client computer, a Java Server Pages (JSP) file is dynamically generated based on the code, and the client computer is redirected to the generated JSP file, and the Web configured to transmit hacking information to the function to which the code is applied or to transmit hacking information to the client computer without inserting hacking information when an attack code or a code to which secure coding is applied is inserted and transmitted to the function to which the code is applied by the client computer It characterized in that it comprises a; server.
상기 실시형태에 의한 시큐어 코딩 시스템에 있어서, 상기 웹서버는 상기 클라이언트 컴퓨터에 코드 작성툴을 제공하는 코드 생성부; 상기 클라이언트 컴퓨터로부터 코드를 수신하는 코드 수신부; 상기 코드 수신부에서 수신된 코드를 기초로 JSP 파일을 생성하는 JSP 파일 생성부; 상기 생성된 JSP 파일로 상기 클라이언트 컴퓨터를 리다이렉트 시키는 리다이렉트부; 상기 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되면, 상기 코드가 적용된 기능에 해킹 정보를 삽입하거나 또는 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하는 시큐어 코딩 적용 확인부;를 포함할 수 있다.In the secure coding system according to the above embodiment, the web server comprises: a code generator for providing a code writing tool to the client computer; A code receiving unit for receiving a code from the client computer; A JSP file generator that generates a JSP file based on the code received from the code receiver; A redirect unit for redirecting the client computer to the generated JSP file; When an attack code or a code to which secure coding is applied is inserted and transmitted to the function to which the code is applied by the client computer, the secure transmitting the hacking information to the function to which the code is applied or without inserting the hacking information to the client computer It may include a; coding application confirmation unit.
상기 실시형태에 의한 시큐어 코딩 시스템에 있어서, 상기 코드가 적용된 기능은 게시판 또는 로그인창일 수 있다.In the secure coding system according to the above embodiment, the function to which the code is applied may be a bulletin board or a login window.
상기의 목적을 달성하기 위해 본 발명의 다른 실시형태에 의한 시큐어 코딩 방법은 클라이언트 컴퓨터가 웹서버의 코드 생성부를 이용하여 코드를 작성하여 전송하는 단계; 상기 웹서버가 작성된 코드를 수신하는 단계; 상기 웹서버가 상기 코드를 기초로 JSP(Java Server Pages) 파일을 생성하고, 상기 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트(Redirect)시키는 단계; 상기 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되는 단계; 상기 코드가 적용된 기능에 공격 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하여 상기 클라이언트 컴퓨터에 전송하는 단계; 및 상기 코드가 적용된 기능에 시큐어 코딩이 적용된 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하는 단계;를 포함하는 것을 특징으로 한다.In order to achieve the above object, a secure coding method according to another embodiment of the present invention includes the steps of creating and transmitting a code using a code generator of a web server by a client computer; Receiving the code written by the web server; Generating, by the web server, a Java Server Pages (JSP) file based on the code, and redirecting the client computer to the generated JSP file; Inserting and transmitting an attack code or a code to which the secure coding is applied to the function to which the code is applied by the client computer; Inserting hacking information into the function to which the code is applied and transmitting the hacking information to the client computer when the attack code is inserted into the function to which the code is applied; And transmitting the hacking information to the client computer without inserting hacking information into the function to which the code is applied when the code to which the secure coding is applied is inserted into the function to which the code is applied.
본 발명의 실시형태들에 의한 시큐어 코딩 시스템 및 방법에 의하면, 웹서버가 클라이언트 컴퓨터에 코드 작성툴을 제공하여 작성된 코드를 수신하면 해당 코드를 기초로 동적으로 JSP 파일을 생성하고, 상기 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트시킨 후, 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되고, 상기 코드가 적용된 기능에 공격 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하여 상기 클라이언트 컴퓨터에 전송하는 한편, 상기 코드가 적용된 기능에 시큐어 코딩이 적용된 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하도록 구성됨으로써, 소프트웨어 별로 모의공격 파일을 작성하여 분석하기 위한 개발환경이 필요 없이 간단하게 웹페이지에 접속하여 취약점 방어 실습을 할 수 있게 한다는 뛰어난 효과가 있다.According to the secure coding system and method according to embodiments of the present invention, when a web server provides a code writing tool to a client computer and receives a code written, a JSP file is dynamically generated based on the code, and the client computer is After redirecting to the generated JSP file, an attack code or a code applied with secure coding is inserted and transmitted to the function to which the code is applied by the client computer, and the function to which the code is applied when the attack code is inserted into the function to which the code is applied. The hacking information is inserted into the client computer and transmitted to the client computer, and when a secure coded code is inserted in the function to which the code is applied, the hacking information is not inserted into the function to which the code is applied, and transmitted to the client computer, There is an excellent effect that it allows you to practice vulnerability defense by simply accessing a web page without the need for a development environment to create and analyze a mock attack file for each software.
도 1은 본 발명의 제 1 실시예에 의한 시큐어 코딩 시스템의 구성도이다.
도 2는 본 발명의 제 2 실시예에 의한 시큐어 코딩 시스템의 구성도이다.
도 3은 본 발명의 제 1 실시예에 의한 시큐어 코딩 방법을 나타낸 플로우챠트이다.
도 4는 본 발명의 제 2 실시예에 의한 시큐어 코딩 방법을 나타낸 플로우챠트이다.
도 5는 코드가 적용된 기능을 예시적으로 나타낸 도면이다.
도 6은 도 5의 코드가 적용된 기능에 해킹 정보를 삽입한 도면이다.
도 7은 도 5의 코드가 적용된 기능에 해킹 정보를 삽입하지 않은 도면이다1 is a block diagram of a secure coding system according to a first embodiment of the present invention.
2 is a block diagram of a secure coding system according to a second embodiment of the present invention.
3 is a flowchart showing a secure coding method according to the first embodiment of the present invention.
4 is a flowchart showing a secure coding method according to a second embodiment of the present invention.
5 is a diagram illustrating a function to which a code is applied.
6 is a diagram in which hacking information is inserted into a function to which the code of FIG. 5 is applied.
FIG. 7 is a diagram in which hacking information is not inserted into the function to which the code of FIG. 5 is applied
본 발명의 실시예를 설명함에 있어서, 본 발명과 관련된 공지기술에 대한 구체적인 설명이 본 발명의 요지를 불필요하게 흐릴 수 있다고 판단되는 경우에는 그 상세한 설명을 생략하기로 한다. 그리고 후술되는 용어들은 본 발명에서의 기능을 고려하여 정의된 용어들로서 이는 사용자, 운용자의 의도 또는 관례 등에 따라 달라질 수 있다. 그러므로 그 정의는 본 명세서 전반에 걸친 내용을 토대로 내려져야 할 것이다. 상세한 설명에서 사용되는 용어는 단지 본 발명의 실시예를 기술하기 위한 것이며, 결코 제한적으로 해석되어서는 안 된다. 명확하게 달리 사용되지 않는 한, 단수 형태의 표현은 복수 형태의 의미를 포함한다. 본 설명에서, "포함" 또는 "구비"와 같은 표현은 어떤 특성들, 숫자들, 단계들, 동작들, 요소들, 이들의 일부 또는 조합을 가리키기 위한 것이며, 기술된 것 이외에 하나 또는 그 이상의 다른 특성, 숫자, 단계, 동작, 요소, 이들의 일부 또는 조합의 존재 또는 가능성을 배제하는 것으로 해석되어서는 안 된다.In describing the embodiments of the present invention, when it is determined that a detailed description of known technologies related to the present invention may unnecessarily obscure the subject matter of the present invention, a detailed description thereof will be omitted. In addition, terms to be described later are terms defined in consideration of functions in the present invention, which may vary according to the intention or custom of users or operators. Therefore, the definition should be made based on the contents throughout the present specification. The terms used in the detailed description are merely for describing the embodiments of the present invention and should not be construed as limiting. Unless explicitly used otherwise, expressions in the singular form include the meaning of the plural form. In the present description, expressions such as "comprising" or "feature" are intended to refer to certain features, numbers, steps, actions, elements, some or combination thereof, and one or more It should not be construed as excluding the presence or possibility of other features, numbers, steps, actions, elements, any part or combination thereof.
도면에서 도시된 각 시스템에서, 몇몇 경우에서의 요소는 각각 동일한 참조 번호 또는 상이한 참조 번호를 가져서 표현된 요소가 상이하거나 유사할 수가 있음을 시사할 수 있다. 그러나 요소는 상이한 구현을 가지고 본 명세서에서 보여지거나 기술된 시스템 중 몇몇 또는 전부와 작동할 수 있다. 도면에서 도시된 다양한 요소는 동일하거나 상이할 수 있다. 어느 것이 제1 요소로 지칭되는지 및 어느 것이 제2 요소로 불리는지는 임의적이다.In each of the systems shown in the drawings, the elements in some cases each have the same reference number or a different reference number, suggesting that the elements represented may be different or similar. However, elements may have different implementations and operate with some or all of the systems shown or described herein. The various elements shown in the figures may be the same or different. Which is referred to as the first element and which is referred to as the second element is arbitrary.
본 명세서에서 어느 하나의 구성요소가 다른 구성요소로 데이터 또는 신호를 '전송', '전달' 또는 '제공'한다 함은 어느 한 구성요소가 다른 구성요소로 직접 데이터 또는 신호를 전송하는 것은 물론, 적어도 하나의 또 다른 구성요소를 통하여 데이터 또는 신호를 다른 구성요소로 전송하는 것을 포함한다.In the present specification, "transmitting", "transmitting" or "providing" data or signals from one component to another component means that one component directly transmits data or signals to another component, as well as It includes transmitting data or signals to other components through at least one other component.
이하, 본 발명의 실시예를 도면을 참조하여 상세히 설명하기로 한다.Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.
[제 1 실시예][First Example]
도 1은 본 발명의 제 1 실시예에 의한 시큐어 코딩 시스템의 구성도이다.1 is a block diagram of a secure coding system according to a first embodiment of the present invention.
본 발명의 제 1 실시예에 의한 시큐어 코딩 시스템은, 도 1에 도시된 바와 같이, 클라이언트 컴퓨터(100) 및 웹서버(200)를 포함한다.The secure coding system according to the first embodiment of the present invention includes a
클라이언트 컴퓨터(100)는 웹서버(200)로부터 불러들인 코드 작성툴을 이용하여 코드를 작성하여 웹서버(200)전송하고, 코드가 적용된 기능(예컨대, 게시판 또는 로그인창)(도 5에 예시됨)에 공격 코드 또는 시큐어 코딩이 적용된 코드를 삽입하여 웹서버(200)에 전송하며, 코드가 적용된 기능에 해킹 정보가 삽입된 화면(도 6에 예시됨)을 디스플레이하거나 또는 해킹 정보가 삽입되지 않은 화면(도 7에 예시됨)을 디스플레이 하는 역할을 한다.The
웹서버(200)는 클라이언트 컴퓨터(100)에 코드 작성툴을 제공하여 코드를 작성하게 하고, 작성된 코드를 수신하면 해당 코드를 기초로 동적으로 JSP(Java Server Pages) 파일을 생성하고, 클라이언트 컴퓨터(100)를 생성된 JSP 파일로 리다이렉트 시킨 후, 클라이언트 컴퓨터(100)에 의해 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되면, 코드가 적용된 기능에 해킹 정보를 삽입하거나 또는 해킹 정보를 삽입하지 않고 클라이언트 컴퓨터(100)에 전송하는 역할을 한다.The web server 200 provides a code writing tool to the
웹서버(200)는 코드 생성부(210), 코드 수신부(220), JSP 파일 생성부(230), 리다이렉트부(240), 및 시큐어 코딩 적용 확인부(250)를 포함한다.The web server 200 includes a
코드 생성부(210)는 클라이언트 컴퓨터(100)의 요청시 코드를 작성하는데 필요한 코드 작성툴을 제공하는 역할을 한다.The
코드 수신부(220)는 클라이언트 컴퓨터(100)로부터 작성된 코드를 수신하는 역할을 한다.The
JSP 파일 생성부(230)는 코드 수신부(220)에서 수신된 코드를 기초로 JSP 파일을 생성하는 역할을 한다.The JSP
리다이렉트부(240)는 JSP 파일 생성부(230)에 의해 생성된 JSP 파일로 클라이언트 컴퓨터(100)를 리다이렉트 시키는 역할을 한다.The
시큐어 코딩 적용 확인부(250)는 클라이언트 컴퓨터(100)에 의해 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송될 경우, 공격 코드 삽입 시에는 코드가 적용된 기능에 해킹 정보를 삽입하여 클라이언트 컴퓨터(100)에 전송하는 한편, 시큐어 코딩이 적용된 코드 삽입시에는 해킹 정보를 삽입하지 않고 클라이언트 컴퓨터(100)에 전송하는 역할을 한다.The secure coding
이하, 상기한 바와 같이 구성된 본 발명의 제 1 실시예에 의한 시큐어 코딩 시스템을 이용한 시큐어 코딩 방법에 대해서 설명하기로 한다.Hereinafter, a secure coding method using the secure coding system according to the first embodiment of the present invention constructed as described above will be described.
도 3은 본 발명의 제 1 실시예에 의한 시큐어 코딩 방법을 나타낸 플로우챠트로서, 여기서 S는 스텝(step)을 나타낸다.3 is a flowchart showing a secure coding method according to the first embodiment of the present invention, where S represents a step.
먼저, 클라이언트 컴퓨터(100)가 웹서버(200)에 접속하여 코드 생성부(210)를 불러들여 이를 이용하여 코드를 작성하고 웹서버(200)에 전송하면(S10), 웹서버(200)는 스텝(S10)에서 작성된 코드를 수신한다(S20).First, when the
이어서, 웹서버(200)는 작성된 코드를 기초로 JSP 파일을 생성하고(S30), 클라이언트 컴퓨터(100)를 스텝(S30)에서 생성된 JSP파일로 리다이렉트 시킨다(S40).Subsequently, the web server 200 generates a JSP file based on the created code (S30), and redirects the
이때, 클라이언트 컴퓨터(100)는 작성된 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드를 삽입하여 웹서버(200)에 전송한다(S50).At this time, the
웹서버(200)는 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입된 코드가 적용된 기능을 수신한다(S60).The web server 200 receives an attack code or a function to which a code to which a secure coding is applied is applied is applied (S60).
코드가 적용된 기능에 공격 코드가 삽입되었을 경우(S70의 YES), 웹서버(200)는 코드가 적용된 기능에 해킹 정보를 삽입하여 클라이언트 컴퓨터(100)에 전송한다.When the attack code is inserted into the function to which the code is applied (YES in S70), the web server 200 inserts hacking information into the function to which the code is applied and transmits it to the
한편, 코드가 적용된 기능에 시큐어 코딩이 적용된 코드가 삽입되었을 경우(S70의 NO), 웹서버(200)는 코드가 적용된 기능에 해킹 정보를 삽입하지 않고 클라이언트 컴퓨터(100)에 전송한다.On the other hand, when the code to which the secure coding is applied is inserted in the function to which the code is applied (NO in S70), the web server 200 transmits the hacking information to the
본 발명의 제 1 실시예에 의한 시큐어 코딩 시스템 및 방법에 의하면, 웹서버가 클라이언트 컴퓨터에 코드 작성툴을 제공하여 작성된 코드를 수신하면 해당 코드를 기초로 동적으로 JSP 파일을 생성하고, 상기 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트시킨 후, 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되고, 상기 코드가 적용된 기능에 공격 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하여 상기 클라이언트 컴퓨터에 전송하는 한편, 상기 코드가 적용된 기능에 시큐어 코딩이 적용된 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하도록 구성됨으로써, 소프트웨어 별로 모의공격 파일을 작성하여 분석하기 위한 개발환경이 필요 없이 간단하게 웹페이지에 접속하여 취약점 방어 실습을 할 수 있게 한다.According to the secure coding system and method according to the first embodiment of the present invention, when a web server receives a code written by providing a code writing tool to a client computer, a JSP file is dynamically generated based on the code, and the client computer Is redirected to the generated JSP file, an attack code or a code applied with secure coding is inserted and transmitted to the function to which the code is applied by the client computer, and the code is applied when the attack code is inserted into the function to which the code is applied. By inserting hacking information into a function and transmitting it to the client computer, it is configured to transmit the hacking information to the client computer without inserting the hacking information into the function to which the code is applied, when a secure coded code is inserted into the function to which the code is applied. , Without the need for a development environment to create and analyze a mock attack file for each software, it is possible to practice vulnerability defense by simply accessing a web page.
[제 2 실시예][Second Example]
도 2는 본 발명의 제 2 실시예에 의한 시큐어 코딩 시스템의 구성도이다.2 is a block diagram of a secure coding system according to a second embodiment of the present invention.
본 발명의 제 2 실시예에 의한 시큐어 코딩 시스템은, 도 2에 도시된 바와 같이, 클라이언트 컴퓨터(100) 및 웹서버(200)를 포함한다.The secure coding system according to the second embodiment of the present invention includes a
클라이언트 컴퓨터(100)는 웹서버(200)로부터 불러들인 코드 작성툴을 이용하여 코드를 작성하여 웹서버(200)전송하고, 코드가 적용된 기능(예컨대, 게시판 또는 로그인창)(도 5에 예시됨)에 공격 코드 또는 시큐어 코딩이 적용된 코드를 삽입하여 웹서버(200)에 전송하며, 코드가 적용된 기능에 해킹 정보가 삽입된 화면(도 6에 예시됨)을 디스플레이하거나 또는 해킹 정보가 삽입되지 않은 화면(도 7에 예시됨)을 디스플레이 하는 역할을 한다.The
웹서버(200)는 클라이언트 컴퓨터(100)에 코드 작성툴을 제공하여 코드를 작성하게 하고, 작성된 코드를 수신하면 해당 코드를 기초로 동적으로 JSP 파일을 생성하고, 클라이언트 컴퓨터(100)를 생성된 JSP 파일로 리다이렉트 시킨 후, 클라이언트 컴퓨터(100)에 의해 코드가 적용된 기능(예컨대, 게시판 또는 로그인창)에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되면 공격 코드 쿼리를 실행하여 도커(260)에 있는 데이터를 공격하고, 그 공격 결과를 도커(260)로부터 전달받아 클라이언트 컴퓨터(100)에 전달하고, 공격 결과에 따라 실행을 종료하거나 클라이언트 컴퓨터(100)에 코드 작성툴을 제공하여 계속해서 코드를 작성하게 한다. The web server 200 provides a code writing tool to the
웹서버(200)는 코드 생성부(210), 코드 수신부(220), JSP 파일 생성부(230), 리다이렉트부(240), 시큐어 코딩 적용 확인부(250), 및 도커(260)를 포함한다.The web server 200 includes a
코드 생성부(210)는 클라이언트 컴퓨터(100)에 코드를 작성하는데 필요한 코드 작성툴을 제공하는 역할을 한다.The
코드 수신부(220)는 클라이언트 컴퓨터(100)로부터 작성된 코드를 수신하는 역할을 한다.The
JSP 파일 생성부(230)는 코드 수신부(220)에서 수신된 코드를 기초로 JSP 파일을 생성하는 역할을 한다.The JSP
리다이렉트부(240)는 JSP 파일 생성부(230)에 의해 생성된 JSP 파일로 클라이언트 컴퓨터(100)를 리다이렉트 시키는 역할을 한다.The
시큐어 코딩 적용 확인부(250)는 코드가 적용된 기능에 클라이언트 컴퓨터(100)가 공격 코드 또는 시큐어 코딩이 적용된 코드를 삽입하여 전송하면 이를 수신하고, 코드가 적용된 기능에 삽입된 공격 코드 또는 시큐어 코딩이 적용된 코드에 따라 공격 코드 쿼리를 실행하여 도커(260)에 있는 데이터를 공격한 후에, 도커(260)로부터 공격 결과를 수신하여 클라이언트 컴퓨터(100)에 전달하고, 공격 결과의 성공 여부를 결정하여 실행을 종료하거나 클라이언트 컴퓨터(100)에 코드 작성툴을 제공하여 재차 시큐어 코딩 과정을 수행하게 하는 역할을 한다.When the
도커(260)는 보안이 필요한 데이터(예컨대, 사용자 ID 및 비밀번호)(도 6 참조)를 저장하고, 웹서버(200)에 의해 공격 코드 쿼리가 실행되어 데이터가 공격받으면 공격 결과(즉, 공격 성공 또는 공격 실패)를 전달하는 역할을 한다.The
이하, 상기한 바와 같이 구성된 본 발명의 제 2 실시예에 의한 시큐어 코딩 시스템을 이용한 시큐어 코딩 방법에 대해서 설명하기로 한다.Hereinafter, a secure coding method using the secure coding system according to the second embodiment of the present invention constructed as described above will be described.
도 4는 본 발명의 실시예에 의한 시큐어 코딩 방법을 나타낸 플로우챠트로서, 여기서 S는 스텝(step)을 나타낸다.4 is a flowchart showing a secure coding method according to an embodiment of the present invention, where S represents a step.
먼저, 클라이언트 컴퓨터(100)가 웹서버(200)에 접속하여 코드 생성부(210)를 불러들여 이를 이용하여 코드를 작성하고 웹서버(200)에 전송하면(S10'), 웹서버(200)는 스텝(S10)에서 작성된 코드를 수신한다(S20').First, when the
이어서, 웹서버(200)는 작성된 코드를 기초로 JSP 파일을 생성하고(S30'), 클라이언트 컴퓨터(100)를 스텝(S30')에서 생성된 JSP파일로 리다이렉트 시킨다(S40').Subsequently, the web server 200 generates a JSP file based on the created code (S30'), and redirects the
이때, 클라이언트 컴퓨터(100)는 작성된 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드를 삽입하여 웹서버(200)에 전송한다(S50').At this time, the
웹서버(200)는 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입된 코드가 적용된 기능을 수신하고(S60'), 공격 코드 쿼리를 실행하여 도커(260)에 있는 데이터를 공격한다(S70').The web server 200 receives an attack code or a function to which a code to which a secure coding is applied is applied (S60'), and executes an attack code query to attack data in the docker 260 (S70').
이어서, 웹서버(200)가 도커(260)로부터 공격결과를 전달받고(S80'), 공격결과를 클라이언트 컴퓨터(100)에 전달한다(S90').Subsequently, the web server 200 receives the attack result from the docker 260 (S80'), and transmits the attack result to the client computer 100 (S90').
이때, 공격이 실패할 경우(S100'의 공격 실패)는 시큐어 코딩 작업을 종료한다.At this time, if the attack fails (the attack fails in S100'), the secure coding operation is terminated.
한편, 공격이 성공할 경우(S100'의 공격 성공)는 스텝(S10')으로 진행된다.On the other hand, if the attack is successful (the attack is successful in S100'), the process proceeds to step S10'.
본 발명의 제 2 실시예에 의한 시큐어 코딩 시스템 및 방법에 의하면, 웹서버가 클라이언트 컴퓨터에 코드 작성툴을 제공하여 작성된 코드를 수신하면 해당 코드를 기초로 동적으로 JSP 파일을 생성하고, 상기 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트시킨 후, 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되면 공격 코드 쿼리를 실행하여 도커에 있는 데이터를 공격하고, 그 공격 결과를 상기 도커로부터 전달받아 클라이언트 컴퓨터에 전달하고, 상기 공격 결과에 따라 실행을 종료하거나 상기 클라이언트 컴퓨터에 코드 작성툴을 제공하도록 구성됨으로써, 소프트웨어 별로 모의공격 파일을 작성하여 분석하기 위한 개발환경이 필요 없이 간단하게 웹페이지에 접속하여 취약점 방어 실습을 할 수 있게 한다.According to the secure coding system and method according to the second embodiment of the present invention, when a web server receives a code written by providing a code writing tool to a client computer, a JSP file is dynamically generated based on the code, and the client computer Is redirected to the generated JSP file, and when the attack code or code applied with secure coding is inserted and transmitted to the function to which the code is applied by the client computer, the attack code query is executed to attack the data in Docker, and the result of the attack. Is delivered from the Docker and delivered to the client computer, and is configured to terminate execution according to the attack result or provide a code writing tool to the client computer, so that there is no need for a development environment for creating and analyzing a mock attack file for each software. It allows you to practice vulnerability defense by simply accessing a web page.
도면과 명세서에는 최적의 실시예가 개시되었으며, 특정한 용어들이 사용되었으나 이는 단지 본 발명의 실시형태를 설명하기 위한 목적으로 사용된 것이지 의미를 한정하거나 특허청구범위에 기재된 본 발명의 범위를 제한하기 위하여 사용된 것은 아니다. 그러므로 본 기술 분야의 통상의 지식을 가진 자라면 이로부터 다양한 변형 및 균등한 타 실시예가 가능하다는 점을 이해할 수 있을 것이다. 따라서 본 발명의 진정한 기술적 보호범위는 첨부된 특허청구범위의 기술적 사상에 의해 정해져야 할 것이다.In the drawings and specification, an optimal embodiment has been disclosed, and specific terms are used, but these are used only for the purpose of describing the embodiments of the present invention, and are used to limit the meaning or the scope of the present invention described in the claims. Was not done. Therefore, those of ordinary skill in the art will understand that various modifications and equivalent other embodiments are possible therefrom. Therefore, the true technical protection scope of the present invention should be determined by the technical spirit of the appended claims.
100: 클라이언트 컴퓨터
200: 웹서버
210: 코드 생성부
220: 코드 수신부
230: JSP 파일 생성부
240: 리다이렉트부
250: 시큐어 코딩 적용 확인부
260: 도커100: client computer
200: web server
210: code generation unit
220: code receiver
230: JSP file generation unit
240: redirect part
250: secure coding application confirmation unit
260: docker
Claims (4)
상기 클라이언트 컴퓨터에 코드 작성툴을 제공하여 작성된 코드를 수신하면 해당 코드를 기초로 동적으로 JSP(Java Server Pages) 파일을 생성하고, 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트(Redirect)시킨 후, 상기 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되면, 상기 코드가 적용된 기능에 해킹 정보를 삽입하거나 또는 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하도록 구성된 웹서버;를 포함하는 시큐어 코딩 시스템.
Write and transmit a code using a code writing tool, insert and transmit an attack code or a code with secure coding applied to the function to which the code is applied, and display a screen with or without hacking information inserted into the function to which the code is applied. Configured client computer; And
When a code written by providing a code writing tool to the client computer is received, a Java Server Pages (JSP) file is dynamically generated based on the code, and the client computer is redirected to the generated JSP file, and then the client A web server configured to transmit hacking information to the function to which the code is applied or to transmit hacking information to the client computer without inserting the hacking information or when the code to which the code is applied is inserted and transmitted by the computer. Secure coding system including;
상기 웹서버는,
상기 클라이언트 컴퓨터에 코드 작성툴을 제공하는 코드 생성부;
상기 클라이언트 컴퓨터로부터 코드를 수신하는 코드 수신부;
상기 코드 수신부에서 수신된 코드를 기초로 JSP 파일을 생성하는 JSP 파일 생성부;
상기 생성된 JSP 파일로 상기 클라이언트 컴퓨터를 리다이렉트 시키는 리다이렉트부;
상기 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되면, 상기 코드가 적용된 기능에 해킹 정보를 삽입하거나 또는 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하는 시큐어 코딩 적용 확인부;를 포함하는 시큐어 코딩 시스템.
The method of claim 1,
The web server,
A code generation unit providing a code writing tool to the client computer;
A code receiving unit for receiving a code from the client computer;
A JSP file generator that generates a JSP file based on the code received from the code receiver;
A redirect unit for redirecting the client computer to the generated JSP file;
When an attack code or a code to which secure coding is applied is inserted and transmitted to the function to which the code is applied by the client computer, the secure transmitting the hacking information to the function to which the code is applied or without inserting the hacking information to the client computer A secure coding system comprising a; coding application confirmation unit.
상기 코드가 적용된 기능은 게시판 또는 로그인창인 시큐어 코딩 시스템.
The method of claim 1,
The function to which the code is applied is a bulletin board or a login window, a secure coding system.
클라이언트 컴퓨터가 웹서버의 코드 생성부를 이용하여 코드를 작성하여 전송하는 단계;
상기 웹서버가 작성된 코드를 수신하는 단계;
상기 웹서버가 상기 코드를 기초로 JSP(Java Server Pages) 파일을 생성하고, 상기 클라이언트 컴퓨터를 생성된 JSP파일로 리다이렉트(Redirect)시키는 단계;
상기 클라이언트 컴퓨터에 의해 상기 코드가 적용된 기능에 공격 코드 또는 시큐어 코딩이 적용된 코드가 삽입되어 전송되는 단계;
상기 코드가 적용된 기능에 공격 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하여 상기 클라이언트 컴퓨터에 전송하는 단계; 및
상기 코드가 적용된 기능에 시큐어 코딩이 적용된 코드가 삽입되었을 경우 상기 코드가 적용된 기능에 해킹 정보를 삽입하지 않고 상기 클라이언트 컴퓨터에 전송하는 단계;를 포함하는 시큐어 코딩 방법.
As a secure coding method using the secure coding system according to claim 1,
Creating and transmitting a code by using a code generator of a web server by a client computer;
Receiving the code written by the web server;
Generating, by the web server, a Java Server Pages (JSP) file based on the code, and redirecting the client computer to the generated JSP file;
Inserting and transmitting an attack code or a code to which the secure coding is applied to the function to which the code is applied by the client computer;
Inserting hacking information into the function to which the code is applied and transmitting the hacking information to the client computer when the attack code is inserted into the function to which the code is applied; And
And transmitting the hacking information to the client computer without inserting hacking information into the function to which the code is applied when the code to which the secure coding is applied is inserted into the function to which the code is applied.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020190120363A KR20210037895A (en) | 2019-09-30 | 2019-09-30 | Secure coding system and method thereof |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020190120363A KR20210037895A (en) | 2019-09-30 | 2019-09-30 | Secure coding system and method thereof |
Publications (1)
Publication Number | Publication Date |
---|---|
KR20210037895A true KR20210037895A (en) | 2021-04-07 |
Family
ID=75469723
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020190120363A KR20210037895A (en) | 2019-09-30 | 2019-09-30 | Secure coding system and method thereof |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR20210037895A (en) |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20190090436A (en) | 2018-01-25 | 2019-08-02 | 주식회사 엑스게이트 | Apparatus, method and system for checking vulnerable point |
-
2019
- 2019-09-30 KR KR1020190120363A patent/KR20210037895A/en not_active Application Discontinuation
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20190090436A (en) | 2018-01-25 | 2019-08-02 | 주식회사 엑스게이트 | Apparatus, method and system for checking vulnerable point |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3295359B1 (en) | Detection of sql injection attacks | |
US10009381B2 (en) | System and method for threat-driven security policy controls | |
US10868819B2 (en) | Systems for detecting a headless browser executing on a client computer | |
US7752662B2 (en) | Method and apparatus for high-speed detection and blocking of zero day worm attacks | |
EP3424178B1 (en) | Deterministic reproduction of client/server computer state or output sent to one or more client computers | |
US7870610B1 (en) | Detection of malicious programs | |
US9973531B1 (en) | Shellcode detection | |
JP4405248B2 (en) | Communication relay device, communication relay method, and program | |
KR101497742B1 (en) | System and method for authentication, data transfer, and protection against phising | |
US8887278B2 (en) | Restricting a processing system being compromised with a threat | |
US20170177314A1 (en) | Application randomization mechanism | |
US20190052651A1 (en) | Real-time prevention of malicious content via dynamic analysis | |
AU2017234260A1 (en) | System and method for reverse command shell detection | |
Peter et al. | A practical guide to honeypots | |
RU2726032C2 (en) | Systems and methods for detecting malicious programs with a domain generation algorithm (dga) | |
US20190081977A1 (en) | Mitigating attacks on server computers by enforcing platform policies on client computers | |
US10284592B1 (en) | Application randomization mechanism | |
US10514962B2 (en) | Web comm channel system and method | |
US11586726B2 (en) | Secure web framework | |
US20140026217A1 (en) | Methods for identifying key logging activities with a portable device and devices thereof | |
EP3532980B1 (en) | Method in computer assisted operation | |
US10827349B2 (en) | SEALANT: security for end-users of android via light-weight analysis techniques | |
Imamura et al. | Web access monitoring mechanism via Android WebView for threat analysis | |
US8613097B2 (en) | Methods and systems for detecting an access attack | |
US8904487B2 (en) | Preventing information theft |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
E902 | Notification of reason for refusal | ||
E601 | Decision to refuse application |