KR20070023873A - Vulnerability rule based system for software development - Google Patents

Vulnerability rule based system for software development Download PDF

Info

Publication number
KR20070023873A
KR20070023873A KR1020050078172A KR20050078172A KR20070023873A KR 20070023873 A KR20070023873 A KR 20070023873A KR 1020050078172 A KR1020050078172 A KR 1020050078172A KR 20050078172 A KR20050078172 A KR 20050078172A KR 20070023873 A KR20070023873 A KR 20070023873A
Authority
KR
South Korea
Prior art keywords
vulnerability
software
rule
function
module
Prior art date
Application number
KR1020050078172A
Other languages
Korean (ko)
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 KR1020050078172A priority Critical patent/KR20070023873A/en
Publication of KR20070023873A publication Critical patent/KR20070023873A/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3604Software analysis for verifying properties of programs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/75Structural analysis for program understanding

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Debugging And Monitoring (AREA)

Abstract

A vulnerability rule based system for developing software is provided to reduce expense with prevention of security accidents by safely developing the software in a source level and shorten software development time by detecting the vulnerability through the system without making a developer develop the software in consideration of each vulnerability. A software structure analyzing module analyzes a structure of the software to obtain correct contents for a vulnerability function before a function related to the vulnerability is searched. A vulnerability detecting module searches the vulnerability of the software by using the generated software structure and a vulnerability rule. An alert module displays the contents for the vulnerability detected by the vulnerability detecting module to a screen. A rule generating module generates and stores the vulnerability rule to correctly discriminate the vulnerability not simple pattern matching of the vulnerability function. The rule generating module applies a rule generating module according to diverse vulnerability.

Description

소프트웨어 개발을 위한 취약성 룰 기반 시스템{VULNERABILITY RULE BASED SYSTEM FOR SOFTWARE DEVELOPMENT}Vulnerability rule based system for software development {VULNERABILITY RULE BASED SYSTEM FOR SOFTWARE DEVELOPMENT}

도 1은 본 발명을 적용하기 위한 취약성 rule 기반 시스템의 전체 구성도1 is an overall configuration diagram of a vulnerability rule-based system for applying the present invention

도 2는 본 발명에 의한 소프트웨어 구조 분석 절차를 나타낸 그림2 is a diagram illustrating a software structure analysis procedure according to the present invention.

도 3은 본 발명에서 제안하는 취약성 함수 상태 전이도를 나타낸 그림3 is a diagram showing a vulnerability function state transition diagram proposed in the present invention

인터넷과 컴퓨터의 발달로 많은 프로그램들이 개발되어 사용되어짐에 따라 소프트웨어가 가지고 있는 취약성으로 많은 보안상 문제점이 발생할 수 있다. 따라서 본 발명의 목적은 민과 군에서 동시에 프로그램을 개발할 경우 보다 안전한 소프트웨어를 개발하여, 보안 사고를 사전에 방지하도록 하는 것이다.As many programs are developed and used due to the development of the Internet and computers, many security problems may occur due to the vulnerability of the software. Therefore, it is an object of the present invention to develop a more secure software when developing programs at the same time in both civil and military, to prevent security incidents in advance.

본 발명은 안전한 소프트웨어를 개발하기 위해서 취약성 rule을 생성하고 이를 기반으로 소프트웨어의 취약성을 탐지해내는 시스템에 관한 것이다. The present invention relates to a system for generating vulnerability rules and detecting software vulnerabilities based on them in order to develop secure software.

여기에서, 본 발명을 이루기 위한 종래의 개념에 대해서 설명하도록 한다. Here, the conventional concept for achieving the present invention will be described.

버퍼 오버플로우 취약성(Buffer Overflow Vulnerability)은 1997년 Phrack magazine 49호에 실린 Aleph One의 “Smashing the Stack for Fun and Profit”에서 버퍼 오버플로우에 대한 자세한 원리와 제작 방법을 소개한 이후로 지금까지도 많은 양의 버퍼 오버플로우 취약성을 이용한 공격방법이 생겨나고 있다. 버퍼 오버플로우 취약성을 이용한 공격은 스택 영역에 존재하는 지역 배열 변수를 의도적으로 넘치게 하여 주변에 위치한 복귀주소를 덮어씀으로써 이루어진다. 즉, 스택에 있는 버퍼에 오버플로우를 일으켜 동일 프레임 내에 저장된 리턴 주소값이나 기반 포인터(base pointer) 값을 바꾸어 버리는 것이다. 이 때 배열(버퍼)에 입력되는 문자열에 악성 코드(malicious code)를 포함시키고, 복귀주소가 위치한 스택부분을 악성 코드가 위치한 곳의 주소(버퍼의 주소)로 변경시키기 위하여 프로그램에서 확보한 버퍼보다 큰 문자열을 구성하여 입력을 시도한다. 이 때 버퍼의 주소와 크기를 예측할 수 있어야 하는데 이는 조합 가능한 모든 버퍼의 주소와 버퍼의 크기에 대하여 수없이 시도되는 시행착오를 통해서 얻어질 수 있다. 즉, 버퍼 오버플로우는 지정된 양보다 더 많은 데이터를 버퍼에 넣음으로써 발생한다. 다음의 코드는 간단한 버퍼 오버플로우 예제 코드이다. 버퍼를 채워 오버플로우 시키는데 사용될 데이터는 보통 egg라고 불리다.The Buffer Overflow Vulnerability has been a huge issue since Aleph One's “Smashing the Stack for Fun and Profit” in Phrack magazine 49, 1997, when he introduced the detailed principles and methods of buffer overflow. An attack method has been developed that exploits buffer overflow vulnerabilities. Attacks using buffer overflow vulnerabilities are done by deliberately overflowing local array variables in the stack region and overwriting the return addresses located nearby. That is, it overflows the buffer on the stack and replaces the return address or base pointer value stored in the same frame. At this time, the malicious code is included in the string inputted into the array (buffer), and the stack area where the return address is located is changed to the address (buffer address) where the malicious code is located. Try to construct a large string. At this time, the address and size of the buffer must be predictable. This can be obtained by trial and error attempting on the address and the size of the buffers. That is, a buffer overflow occurs by putting more data into the buffer than the specified amount. The following code is a simple buffer overflow example. The data that will be used to overflow the buffer is usually called egg.

void function(char *str){void function (char * str) {

char buffer[16];     char buffer [16];

strcpy(buffer, str);     strcpy (buffer, str);

}}

void main(){void main () {

char large_string[256];     char large_string [256];

int i;     int i;

for(i=0; i<255; I++)     for (i = 0; i <255; I ++)

large_string[i]='A';        large_string [i] = 'A';

function(large_string);     function (large_string);

}}

위 의 코드는 아주 극단적으로 버퍼 오버플로우 코딩 에러를 보이는 함수를 가지고 있는 예이다. 이 프로그램은 strncpy() 대신 strcpy()를 사용함으로써 경계 검사 없이 공급된 스트링을 복사한다. 좀 더 자세히 설명하면, 먼저 str에 255개의 ‘A’를 넣는다. 그런 다음 str을 buffer에 복사한다. buffer는 16 byte를 할당 받은 상태이다. 따라서 255개의 ‘A’ 중에서 16개만 buffer에 복사된다. 나머지는 buffer에 들어갈 수 없으므로 SFP 영역으로 들어간다. SFP는 4 byte이므로 SFP 영역으로 들어가도 아직 235개가 남아있다. 그 다음은 RET 영역으로 들어가게 된다. 즉, RET도 4 byte이며, 이 영역도 덮어 쓰이게 되어 RET 값이 변경된 것이다.The code above is an example of a function that exhibits a buffer overflow coding error in extreme cases. This program uses strcpy () instead of strncpy () to copy the supplied string without boundary checking. More specifically, first put 255 'A's in str. Then copy str into buffer. The buffer is allocated 16 bytes. Therefore, only 16 of the 255 'A's are copied into the buffer. The rest cannot enter the buffer, so it enters the SFP area. Since SFP is 4 bytes, 235 remain in the SFP area. Then enter the RET area. That is, the RET is 4 bytes, and this area is also overwritten and the RET value is changed.

이 프로그램을 컴파일해서 실행하면 세그먼트 오류가 발생한다. 다음의 그림은 함수를 호출했을 때의 스택 모양이다.Compiling and running this program will result in segment errors. The following figure shows the stack when a function is called.

Figure 112005046958955-PAT00001
Figure 112005046958955-PAT00001

(그림 1) 예제 코드에서 함수 호출 시 스택 모양(Figure 1) Stack of function calls in example code

이 프로그램에서 세그먼트 오류가 발생한 것은 strcpy()가 *str(large_string[])를 buffer[]에 널 문자가 나올 때까지 복사를 하기 때문이다. buffer[]는 *str보다 훨씬 작다. buffer[]는 16 byte 길이이고, 그것에 256 byte를 넣으려고 한다. 이것은 스택에 있는 버퍼 다음에 250 byte 전체가 덮어 쓰인다는 것을 의미한다. 여기에는 SFP, RET, 그리고 심지어 *str도 포함하고 있다. 그리고 large_string을 ‘A’로 채웠다. ‘A’의 hex 문자 값은 0x41이다. 이것은 리턴 어드레스가 이제 0x41414141이라는 것을 위미한다. 이것은 프로세스 어드레스 공간의 밖이다. 이것이 함수가 리턴하고, 그 주소로부터 다음 명령을 읽으려고 할 때 세그먼트 에러가 나는 dlb이다. 그래서 버퍼 오버플로우는 어떤 함수의 리턴 어드레스를 바꾸도록 하는 것을 허용한다. 이렇게 하여 프로그램의 실행 흐름을 변경할 수 있다. 다음의 그림은 버퍼 오버플로우 공격을 나타내는 그림이다.Segment errors in this program occur because strcpy () copies * str (large_string []) until a null character appears in buffer []. buffer [] is much smaller than * str. buffer [] is 16 bytes long and you want to put 256 bytes in it. This means that an entire 250 byte is overwritten after a buffer on the stack. This includes SFP, RET, and even * str. And I filled the large_string with 'A'. The hex value of 'A' is 0x41. This means that the return address is now 0x41414141. This is outside the process address space. This is dlb when the function returns and attempts to read the next command from that address. So buffer overflows allow you to change the return address of a function. This allows you to change the execution flow of your program. The following figure illustrates a buffer overflow attack.

Figure 112005046958955-PAT00002
Figure 112005046958955-PAT00002

(그림 2) 버퍼 오버플로우 공격(Figure 2) Buffer Overflow Attack

본 발명은 상기 종래 안전하지 못한 프로그램을 개발하여 보안사고가 발생하던 문제점을 해결하고, 소스코드 레벨에서 안전한 소프트웨어를 개발하기 위해 안출된 것으로, 이 시스템에 있어서 취약성에 관련된 함수를 탐색하기 이전에 좀 더 정확한 취약성 함수에 관한 내용을 획득하기 위해 소프트웨어의 구조를 분석하는 소프트웨어 구조 분석 모듈; 생성된 소프트웨어 구조와 취약성 Rule을 이용하여 소프트웨어의 취약성을 검색하는 취약성 탐지 모듈; 취약성 탐지 모듈에서 판별된 취약성에 관한 내용을 화면상에 보여주는 역할을 담당하는 Alert 모듈; 소프트웨어의 취약성을 탐지하기 위해 단순한 취약 함수의 패턴 매칭이 아닌 좀더 정확한 취약성 판별을 위해 취약성 rule을 생성하고 저장하는 역할을 담당하는 rule 생성 모듈; 를 포함하며, 소프트웨어의 취약성을 rule로 생성한 뒤 rule을 이용하여 소프트웨 어의 취약성을 탐지하는데 그 목적이 있다.The present invention has been made to solve the problem that a security accident occurred by developing the conventional insecure program, and to develop a secure software at the source code level, before searching for a function related to a vulnerability in this system. A software structure analysis module for analyzing the structure of the software to obtain a content about a more accurate vulnerability function; A vulnerability detection module for searching for a vulnerability of software using the generated software structure and vulnerability rule; An Alert module, which plays a role of showing contents of a vulnerability determined in the vulnerability detection module on a screen; A rule generation module that is responsible for generating and storing vulnerability rules for more accurate vulnerability determination instead of simply pattern matching of a weak function to detect a vulnerability of software; It includes the purpose of creating software vulnerabilities into rules, and then uses the rules to detect software vulnerabilities.

본 발명은 보안 취약성의 대부분이 소프트웨어 취약성으로 인한 것이며 소프트웨어 취약성의 대부분은 버퍼 오버플로우 취약성과 관련되어 있으므로, 버퍼 오버플로우 방지를 위한 가장 근본적인 방법인 안전한 소프트웨어를 만들기 위해 취약성 rule 기반 시스템에 관한 것이다.Since most of the security vulnerabilities are due to software vulnerabilities and most of the software vulnerabilities are related to buffer overflow vulnerabilities, the present invention relates to a vulnerability rule-based system for making secure software which is the most fundamental method for preventing buffer overflow.

이하, 첨부된 도면을 참조하여 본 발명에 의한 rule 기반의 소프트웨어 취약성 탐지 시스템에 대한 바람직한 실시 예를 상세하게 설명한다.Hereinafter, exemplary embodiments of a rule-based software vulnerability detection system according to the present invention will be described in detail with reference to the accompanying drawings.

도 1은 본 발명을 적용하기 위한 취약성 rule 기반 시스템의 전체 구성도이다. 본 시스템은 크게 소프트웨어 분석 모듈, 취약성 탐지 모듈, Alert 모듈, rule 생성 모듈 등의 4개의 모듈과 취약성rule 데이터베이스, 그리고 소프트웨어 구조 데이터베이스로 구성되어져 있다. 취약성 rule 데이터베이스는 소프트웨어의 취약성을 rule로 생성하여 저장한 장소이고, 소프트웨어 구조 데이터베이스는 검사하려는 소프트웨어의 구조를 변수와 함수로 나누어 분석한 뒤 저장한 것이다. 도 1은 본 발명에서 제안한 시스템 구조이다. 각 모듈에 관한 상세한 설명은 다음과 같다.1 is an overall configuration diagram of a vulnerability rule-based system for applying the present invention. The system consists of four modules: software analysis module, vulnerability detection module, alert module, rule generation module, vulnerability rule database, and software structure database. Vulnerability rule database is a place that creates and stores software vulnerabilities as rules, and software structure database is a structure that analyzes and stores the structure of software to be inspected into variables and functions. 1 is a system structure proposed in the present invention. Detailed description of each module is as follows.

소프트웨어 구조 분석 모듈은 취약성에 관련된 함수를 탐색하기 이전에 좀 더 정확한 취약성 함수에 관한 내용을 획득하기 위해 소프트웨어의 구조를 분석한 다. 소프트웨어 구조 분석 순서는 다음과 같다.The software structure analysis module analyzes the structure of the software to obtain more accurate information about the vulnerability function before searching for the function related to the vulnerability. The software structure analysis sequence is as follows.

가. 단계 1. 프로그램 소스가 입력되면 parser를 통해 함수와 변수를 분리시킨다.end. Step 1. After entering the program source, separate the function and the variable through the parser.

나. 단계 2. 함수 처리에서는 함수에 대한 정보를 추출한 뒤 저장한다.I. Step 2. Function processing extracts information about the function and stores it.

- 함수 처리 부분에서는 함수에 관한 정보를 다음과 같은 구성으로 데이터베이스에 저장한다.   -In the function processing section, information about a function is stored in the database in the following configuration.

1) 모듈 명 : 현재 함수가 소속되어져 있는 모듈 이름   1) Module name: Module name to which current function belongs

2) 함수 명 : 함수 이름   2) Function Name: Function Name

3) 단계 : 함수 내 함수가 사용될 수 있으므로 함수의 포함관계를 표시   3) Step: Shows the inclusion of functions as functions within them can be used

4) 취약여부 : 취약성 있는 함수인지 아닌지를 취약성 Rule 데이터베이스를 통해 확인한다. 이때까지는 취약성 여부가 확정되지 않는다.   4) Vulnerability: Check whether it is a vulnerable function through the vulnerability rule database. Until this point, no vulnerability is confirmed.

5) 파라미터 : 함수에서 사용되는 파라미터의 변수들을 저장한다.   5) Parameter: It stores the variables of the parameter used in the function.

다. 단계 3. 변수 처리에서는 변수에 대한 정보를 추출한 뒤 저장한다.All. Step 3. Variable processing extracts and stores information about variables.

- 변수 처리 부분에서는 변수에 관한 정보를 다음과 같은 구성으로 데이터베이스에 저장한다.   -In the variable processing section, information about variables is stored in the database with the following configuration.

1) 변수 명 : 변수의 이름   1) Variable Name: Name of Variable

2) 변수타입 : 해당변수의 데이터타입을 저장   2) Variable type: save the data type of the variable

3) 지역성 : 전역변수인지 지역 변수인지를 확인    3) Locality: Check whether it is global or local

4) 지역이름 : 함수가 속해져 있는 지역의 이름을 저장   4) Local name: save the name of the area to which the function belongs

5) 단계 : 같은 지역의 이름을 갖는 경우가 있으므로 이것을 구분하기 위한 요소   5) Step: Elements to distinguish this name because they may have the same local name

6) 변수 값 : 변수에 저장되는 값을 입력   6) Variable value: input the value saved in the variable

라. 단계 4. 프로그램 마지막까지 1,2,3 과정을 반복한다.la. Step 4. Repeat steps 1, 2 and 3 until the end of the program.

도면 2는 소프트웨어의 구조를 분석하기 위한 절차를 나타낸 것으로 위의 절차를 도식화한 것이다.Figure 2 shows a procedure for analyzing the structure of the software, which illustrates the above procedure.

취약성 탐지 모듈은 취약성 탐지 모듈에서는 생성된 소프트웨어 구조와 취약성 Rule을 이용하여 소프트웨어의 취약성을 검색하는 것으로 소프트웨어 구조 분석에서 생성된 소프트웨어 구조 테이블의 함수 부분에서 취약성에 관련 함수와 해당 함수가 사용하고 있는 변수에 관한 정보를 추출하여 취약성 탐지 테이블을 다음과 같이 구성한다.The vulnerability detection module detects software vulnerabilities by using the generated software structure and vulnerability rules in the vulnerability detection module. The functions related to the vulnerabilities and the variables used by the functions in the function part of the software structure table generated by the software structure analysis. Extract the information on and configure the vulnerability detection table as follows.

- 취약성 탐지 테이블   Vulnerability Detection Table

① 함수명 : 취약 함수 이름   ① Function Name: Vulnerable Function Name

② 변수명 : 취약 함수에서 사용된 변수   ② Variable name: Variable used in vulnerable function

③ 변수값 : 변수에 저장된 값   ③ Variable value: the value stored in the variable

④ 취약성 여부 : 취약성 여부를 판별한 후 저장   ④ Vulnerability: After determining whether the vulnerability is stored

⑤ 취약성 원인 : 취약성의 원인을 저장(변수의 크기, Rule 규칙에 따른 취약성 판단)   ⑤ Vulnerability cause: Store the cause of vulnerability (determination of vulnerability according to variable size, rule rule)

그리고 난후 취약성 탐지 테이블의 내용과 취약성 Rule을 기반으로 함수의 실제 취약성을 판별한 뒤 이를 Alert 모듈에게 전송한다. Then, based on the contents of the vulnerability detection table and the vulnerability rule, the actual vulnerability of the function is determined and transmitted to the Alert module.

Alert 모듈은 취약성 탐지 모듈에서 판별된 취약성에 관한 내용을 화면상에 보여주는 역할을 담당한다. 화면에 출력할 내용은 다음과 같다.The Alert module plays the role of showing on the screen the vulnerability identified in the vulnerability detection module. The output to the screen is as follows.

1) 취약함수명 : 취약 함수의 이름   1) Vulnerable Function Name: Name of the vulnerable function

2) 사용변수명 : 사용된 변수의 이름   2) Name of variable used: Name of the variable used

3) 취약한 이유: 취약성의 원인을 설명   3) Reason for vulnerability: Describe the cause of the vulnerability

4) 취약성 해결: 취약성 해결하기 위한 방안 제공   4) Vulnerability Resolution: Providing a way to solve the vulnerability

Rule 생성 모듈은 소프트웨어의 취약성을 탐지하기 위해 단순한 취약 함수의 패턴 매칭이 아닌 좀더 정확한 취약성 판별을 위해 취약성 rule을 생성하고 저장하는 역할을 담당한다. 일반적으로 취약 함수를 이용한 보안 문제를 해결하기 위해서는 적절한 대체함수로 프로그램을 작성하는 것이 바람직하다. 하지만 이러한 대체 함수로의 전환은 프로그래머의 개인적 성향과 보안의식 부재로 잘 이루어지지 않고 있다. 따라서 이를 해결하기 위해 단순히 취약함수를 패턴 매칭하여 찾은 후 이를 대체 함수로 바꾸어 주는 연구가 이루어졌지만, 좀더 정확한 판단으로 취약성 함수를 판별하는 연구는 이루어지지 않고 있다. 즉, 취약성 함수인 strcpy 일 경우 사용되는 변수의 값에 따라 취약성 여부가 결정이 된다. strcpy(A, B) 에서 A 변수의 크기가 B의 변수 보다 큰 경우 버퍼 오버플로우가 발생할 수 있지만 A의 크기 B 보다 작을 경우는 버퍼 오버플로우가 발생하지 않는다. 따라서 본 논문에서는 각 변수의 값에 따라 취약성의 여부를 판별하기 위한 rule을 작성하고 이를 기반으로 좀더 정확한 취약성 여부를 검사할 수 있도록 한다.The rule generation module is responsible for creating and storing vulnerability rules for more accurate vulnerability determination, not just pattern matching of vulnerable functions to detect software vulnerabilities. In general, in order to solve a security problem using a weak function, it is desirable to write a program with an appropriate substitution function. However, this transition to alternative functions is not well done due to the programmer's personality and lack of security awareness. Therefore, in order to solve this problem, a research has been conducted to find a weak function by pattern matching and replace it with an alternative function. In other words, in the case of strcpy, the vulnerability function, whether the vulnerability is determined depends on the value of the variable used. In strcpy (A, B), buffer overflow may occur if the size of variable A is larger than variable B, but if the size of variable A is smaller than B, buffer overflow does not occur. Therefore, in this paper, we make a rule to determine the vulnerability according to the value of each variable, and based on this, we can check whether the vulnerability is more accurate.

마지막으로 취약성 rule 모듈에서 사용한 취약성은 버퍼 오버플로우를 일으키는 함수를 대상으로 하였으며, 각 함수에 따른 취약성을 rule R의 집합을 다음과 같이 정의한다. Finally, the vulnerability used in the vulnerability rule module targets a function that causes a buffer overflow. The vulnerability for each function is defined as a set of rule R as follows.

R = {A, N, F, E}R = {A, N, F, E}

- A : 취약성 상태의 집합A: set of vulnerability states

- F : 취약성 함수F: vulnerability function

- N : 다음 상태로의 전이함수N: transition function to the next state

- E : 취약성 마지막 상태-E: last state of vulnerability

또한 프로그램 내부에 존재하는 함수들의 집합을 SF라고 정의 하고, SF ∋ a 일 때, F ∋ a 이면 취약성의 여부를 판별하게 되며, A ={ N0, N1, N2, … , Nn}이고 E = {N2, … , Nn}이면, 전이함수N(N0, a) = N1 에 의해 N1 상태가 된다. 이것은 초기 상태 N0에서 취약성 함수 a가 입력이 되면 다음 상태인 N1로 전이되는 것을 의미하며, 취약성 함수의 상태 변화를 규칙으로 정의하고, 그 규칙에 따라 상태를 전이 시켜 최종 상태가 취약 함수의 마지막 상태(E)와 같은지를 확인한다. 만일 같다면 이 함수는 취약한 함수로 판명된다. 즉, 소프트웨어에서 사용되는 변수들 중에 값과 크기가 결정되지 않은 변수들의 집합을 V라고 했을 때 In addition, the set of functions existing in the program is defined as SF, and when SF ∋ a, F ∋ a determines whether there is a vulnerability, and A = {N0, N1, N2,... , Nn} and E = {N2,... , Nn}, the state becomes N1 by the transition function N (N0, a) = N1. This means that when the vulnerability function a is input from the initial state N0, it transitions to the next state, N1.The state change of the vulnerability function is defined as a rule, and the state is transferred according to the rule so that the final state is the last state of the vulnerable function. Check if it is the same as (E). If so, this function turns out to be a weak function. In other words, if V is a set of variables whose value and size are not determined among the variables used in software,

1) F ∋ v1 1) F ∋ v1

2) V ∋ v1이면 2) If V ∋ v1

N(N1, v1) = N2 가 성립된다. 만일 E = N2 이면 이 함수는 취약성 함수라고 판별되며, 이러한 각 상태의 변화를 규칙으로 정의함으로써 향후 발생할 수 있는 다양한 취약성들을 규칙으로 추가시킬 수 있다. 또 다른 상태 변화로는 전체 변수들의 집합을 VA라고 했을 때, N (N1, v1) = N2 is established. If E = N2, this function is determined to be a vulnerability function, and by defining each of these state changes as a rule, various future vulnerabilities can be added to the rule. Another state change is that when the entire set of variables is called VA,

1) VA ∋ v1, v2 1) VA ∋ v1, v2

2) F ∋ v1, v22) F ∋ v1, v2

3) strcpy(v1,v2) and size(v1) > size(v2) 이면3) If strcpy (v1, v2) and size (v1)> size (v2)

N(N1, v1, v2) = N2가 성립되어 E = N2가 되므로strcpy 함수는 취약성 함수이다. 따라서 위의 상태 변화를 그림으로 표현하면 도면 3과 같다. The strcpy function is a vulnerability function because N (N1, v1, v2) = N2 is established and E = N2. Therefore, the above state change is represented as a figure 3.

본 발명에 의하면, 소프트웨어를 소스레벨에서 안전한 형태로 개발할 수 있기 때문에, 추후에 발생하는 보안 사고를 사전에 방지함으로써 비용을 절감할 수 있으며, 안전한 프로그램을 개발하여 신뢰도를 증가시킬 수 있다. According to the present invention, since the software can be developed in a secure form at the source level, cost can be reduced by preventing future security incidents in advance, and a secure program can be developed to increase reliability.

즉, 프로그램 개발자가 소프트웨어의 취약성을 일일이 고려하여 소프트웨어를 개발 할 필요가 없이 시스템을 통해 취약성을 탐지할 수 있어, 소프트웨어 개발 시간의 단축과 안전한 소프트웨어의 개발로 보안 문제점을 해결하여 추후에 발생하는 보안 문제에 따른 비용을 절감할 수 있다. In other words, program developers can detect vulnerabilities through the system without having to consider software vulnerabilities in order to develop them. The cost of the problem can be reduced.

상기한 바와 같은 구성 및 작용은 실시예로서 본 발명의 청구범위를 제한하는 것은 아니며, 본 발명의 기술적 사상을 변경하지 아니하는 범위 내에서 다양한 변경과 수정이 가능함은 본 발명이 속하는 분야에 종사하는 자에게는 자명한 것이다.The configuration and operation as described above are not limited to the claims of the present invention as an embodiment, and various changes and modifications are possible within the scope of not changing the technical spirit of the present invention. It is obvious to one.

이상의 구성 및 작용을 지니는 본 발명에 따른 취약성 rule 기반 시스템은, 소프트웨어를 소스 레벨에서 안전한 형태로 개발할 수 있기 때문에, 추후에 발생하는 보안 사고를 사전에 방지함으로써 비용을 절감할 수 있으며, 안전한 프로그램을 개발하여 신뢰도를 증가시킬 수 있고, 프로그램 개발자가 소프트웨어의 취약성을 일일이 고려하여 소프트웨어를 개발할 필요가 없이 시스템을 통해 취약성을 탐지할 수 있어, 소프트웨어 개발 시간의 단축을 가져올 수 있다.Vulnerability rule-based system according to the present invention having the above configuration and action, since the software can be developed in a secure form at the source level, it is possible to reduce costs by preventing future security incidents in advance, and secure programs Development can increase reliability, and program developers can detect vulnerabilities through the system without having to consider software vulnerabilities in order to reduce the software development time.

Claims (2)

취약성 rule 기반 시스템에 있어서,In a vulnerability rule based system, 취약성에 관련된 함수를 탐색하기 이전에 좀 더 정확한 취약성 함수에 관한 내용을 획득하기 위해 소프트웨어의 구조를 분석하는 소프트웨어 구조 분석 모듈; A software structure analysis module that analyzes the structure of the software to obtain more accurate information about the vulnerability function before searching for the function related to the vulnerability; 생성된 소프트웨어 구조와 취약성 Rule을 이용하여 소프트웨어의 취약성을 검색하는 취약성 탐지 모듈; A vulnerability detection module for searching for a vulnerability of software using the generated software structure and vulnerability rule; 취약성 탐지 모듈에서 판별된 취약성에 관한 내용을 화면상에 보여주는 역할을 담당하는 Alert 모듈; An Alert module, which plays a role of showing contents of a vulnerability determined in the vulnerability detection module on a screen; 소프트웨어의 취약성을 탐지하기 위해 단순한 취약 함수의 패턴 매칭이 아닌 좀더 정확한 취약성 판별을 위해 취약성 rule을 생성하고 저장하는 역할을 담당하는 rule 생성 모듈;A rule generation module that is responsible for generating and storing vulnerability rules for more accurate vulnerability determination instead of simply pattern matching of a weak function to detect a vulnerability of software; 제 1 항에 있어서, The method of claim 1, rule 생성 모듈은 rule을 상태변화에 따라 작성한 것으로 다양한 취약성에 따라 rule의 생성 알고리즘 적용하는 취약성 rule 기반 시스템.Rule generation module is a rule-based system that creates rules according to state changes and applies rule generation algorithms according to various vulnerabilities.
KR1020050078172A 2005-08-25 2005-08-25 Vulnerability rule based system for software development KR20070023873A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020050078172A KR20070023873A (en) 2005-08-25 2005-08-25 Vulnerability rule based system for software development

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020050078172A KR20070023873A (en) 2005-08-25 2005-08-25 Vulnerability rule based system for software development

Publications (1)

Publication Number Publication Date
KR20070023873A true KR20070023873A (en) 2007-03-02

Family

ID=38098681

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020050078172A KR20070023873A (en) 2005-08-25 2005-08-25 Vulnerability rule based system for software development

Country Status (1)

Country Link
KR (1) KR20070023873A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20200003322A (en) 2018-06-21 2020-01-09 한전케이디엔주식회사 Cloud based power system software ecosystem
CN112783755A (en) * 2019-11-07 2021-05-11 上海蜚语信息科技有限公司 Method for discovering memory corruption vulnerability based on natural language understanding function prototype
KR20230097640A (en) 2021-12-24 2023-07-03 (주)에스엠소프트 SaaS-based power system operation service platform

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20200003322A (en) 2018-06-21 2020-01-09 한전케이디엔주식회사 Cloud based power system software ecosystem
CN112783755A (en) * 2019-11-07 2021-05-11 上海蜚语信息科技有限公司 Method for discovering memory corruption vulnerability based on natural language understanding function prototype
CN112783755B (en) * 2019-11-07 2024-03-22 上海蜚语信息科技有限公司 Method for finding memory damage loopholes based on natural language understanding function prototype
KR20230097640A (en) 2021-12-24 2023-07-03 (주)에스엠소프트 SaaS-based power system operation service platform

Similar Documents

Publication Publication Date Title
KR101780233B1 (en) Apparatus and method for deteting code cloning of software
Johnson et al. Finding user/kernel pointer bugs with type inference.
US7788640B2 (en) Using code analysis to generate documentation
CN103778061B (en) Automatically detection and the bearing calibration of Array Bound mistake
CN101661543B (en) Method and device for detecting security flaws of software source codes
CN105550594A (en) Security detection method for android application file
CN113110988A (en) Testing applications with defined input formats
CN103853650A (en) Test case generating method and device for fuzz testing
AU2004232058A1 (en) Method and system for detecting vulnerabilities in source code
US8572747B2 (en) Policy-driven detection and verification of methods such as sanitizers and validators
Endignoux et al. Caradoc: A pragmatic approach to pdf parsing and validation
CN102622556A (en) Web service security analysis method based on program slicing technique
Ren et al. Making smart contract development more secure and easier
CN113497809A (en) MIPS framework vulnerability mining method based on control flow and data flow analysis
US10823782B2 (en) Ensuring completeness of interface signal checking in functional verification
Kratkiewicz et al. Using a diagnostic corpus of C programs to evaluate buffer overflow detection by static analysis tools
KR101696694B1 (en) Method And Apparatus For Analysing Source Code Vulnerability By Using TraceBack
CN111919214A (en) Automatic generation of patches for security violations
CN115066674A (en) Method for evaluating source code using numeric array representation of source code elements
CN113778852B (en) Code analysis method based on regular expression
KR100653122B1 (en) Real-time detection system and method based rule for safety software development
KR20070023873A (en) Vulnerability rule based system for software development
US7617492B2 (en) Extensible command line parsing
CN114282227B (en) Safety analysis and detection method for intelligent contract of Fabric block chain system
CN105988811B (en) The method and apparatus for obtaining the kernel control flow chart of operating system

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E601 Decision to refuse application