WO2017094990A1 - Device and method for monitoring malicious code encrypting user files - Google Patents

Device and method for monitoring malicious code encrypting user files Download PDF

Info

Publication number
WO2017094990A1
WO2017094990A1 PCT/KR2016/006650 KR2016006650W WO2017094990A1 WO 2017094990 A1 WO2017094990 A1 WO 2017094990A1 KR 2016006650 W KR2016006650 W KR 2016006650W WO 2017094990 A1 WO2017094990 A1 WO 2017094990A1
Authority
WO
WIPO (PCT)
Prior art keywords
target file
monitoring
malicious code
request
folder
Prior art date
Application number
PCT/KR2016/006650
Other languages
French (fr)
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 (주)이스트소프트
Publication of WO2017094990A1 publication Critical patent/WO2017094990A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • G06F21/52Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems during program execution, e.g. stack integrity ; Preventing unwanted data erasure; Buffer overflow
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • G06F21/55Detecting local intrusion or implementing counter-measures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • G06F21/55Detecting local intrusion or implementing counter-measures
    • G06F21/552Detecting local intrusion or implementing counter-measures involving long-term monitoring or reporting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • G06F21/55Detecting local intrusion or implementing counter-measures
    • G06F21/56Computer malware detection or handling, e.g. anti-virus arrangements

Definitions

  • the present invention relates to a technique for detecting a computer virus or malware.
  • malware Malware (or viruses) that hack information of other Internet users without permission and use it illegally or infiltrate computer terminals and servers of other Internet users are emerging as serious social problems.
  • malicious code causes problems in various forms, such as when a user who uses the Internet sends data to another person's computer, or by changing an internal system registry of the user's computer so that the wrong site that the user does not intend is set as an Internet site.
  • Such malware is usually installed on a user's computer through file programs that are easily available on the Internet, or simply by accessing the Internet to arbitrary sites.
  • malware infected with the user system to encrypt the user file, such as a document file, and warns the user, and to recover the encrypted document, such as malware to request the user money with Bitcoin is on the rise.
  • This kind of malware can be detected by an antivirus program or the like, and the malicious code file can be deleted, but it is difficult to recover the document file of an already encrypted user. That is, the antivirus program used to date can delete the file after detecting the malicious code.
  • the decryption key is not known due to the nature of the vaccine, it is impossible to recover the document file of an already encrypted user.
  • an object of the present invention is to provide a malicious code monitoring apparatus and method that can detect the execution of the malicious code encrypting the user file for the first time to prevent the important file stored in the user computer is encrypted.
  • the malicious code monitoring apparatus includes a target file generation module for monitoring a malicious code encrypting a user file and generating a target file for monitoring the malicious code in a storage device in which the user file is stored; A monitoring module for checking a thread which sends the request when a write access right request is made to the target file; And an execution program interrupting module forcibly terminating the thread identified by the monitoring module.
  • the target file generation module preferably generates a trap folder in the highest path of the storage device, and generates the target file in the trap folder. At this time, it is more preferable that the trap folder has a folder name searched first by the malicious code. In addition, the trap folder is preferably created with a hidden attribute.
  • the apparatus according to the present invention may further include an alarm module for outputting a malicious code infection message when a request for write access permission is made to the target file.
  • the monitoring module preferably blocks the request when there is a request for write access permission to the target file.
  • the method for monitoring malicious code encrypting a user file includes: a first step of generating, by a target file generation module, a target file for monitoring the malicious code in a storage device in which a user file is stored; A second step of checking, by the monitoring module, a thread which has sent the request, when there is a request for write access right to the target file; And a third step of executing, by the execution program interruption module, the thread forcibly terminating the thread identified by the monitoring module.
  • the target file generation module In the first step, it is preferable that the target file generation module generates a trap folder in the highest path of the storage device and generates the target file in the trap folder.
  • the target file generation module preferably generates the trap folder having a folder name searched first by the malicious code.
  • the target file generation module may more preferably generate the trap folder as a hidden attribute.
  • the method may further include outputting a malware infection message by the alarm module.
  • the monitoring module preferably blocks the request if there is a request for write access to the target file.
  • an important file of a user can be effectively prevented from being encrypted by malware.
  • Conventional antivirus programs can detect malware and delete it, but it is not possible to recover user files that have already been encrypted.
  • the execution of the application executed by the malicious code or by the accompanying malicious code is executed. By stopping, the user's important files can be prevented from being encrypted in advance.
  • FIG. 1 is a schematic block diagram of a malicious code monitoring apparatus according to the present invention.
  • FIG. 2 is a flowchart illustrating a process of performing a malicious code monitoring method according to the present invention.
  • FIG. 3 illustrates an example in which a trap folder is generated in a user system according to an apparatus and a method for monitoring malware according to the present invention.
  • FIG. 4 illustrates an example in which a target file is generated in a trap folder created in a user system according to a malicious code monitoring apparatus and method according to the present invention.
  • the malicious code monitoring apparatus includes a target file generation module for monitoring a malicious code encrypting a user file and generating a target file for monitoring the malicious code in a storage device in which the user file is stored; A monitoring module for checking a thread which sends the request when a write access right request is made to the target file; And an execution program interrupting module forcibly terminating the thread identified by the monitoring module.
  • the target file generation module preferably generates a trap folder in the highest path of the storage device, and generates the target file in the trap folder. At this time, it is more preferable that the trap folder has a folder name searched first by the malicious code. In addition, the trap folder is preferably created with a hidden attribute.
  • the apparatus according to the present invention may further include an alarm module for outputting a malicious code infection message when a request for write access permission is made to the target file.
  • the monitoring module preferably blocks the request when there is a request for write access permission to the target file.
  • the method for monitoring malicious code encrypting a user file includes: a first step of generating, by a target file generation module, a target file for monitoring the malicious code in a storage device in which a user file is stored; A second step of checking, by the monitoring module, a thread which has sent the request, when there is a request for write access right to the target file; And a third step of executing, by the execution program interruption module, the thread forcibly terminating the thread identified by the monitoring module.
  • the target file generation module In the first step, it is preferable that the target file generation module generates a trap folder in the highest path of the storage device and generates the target file in the trap folder.
  • the target file generation module preferably generates the trap folder having a folder name searched first by the malicious code.
  • the target file generation module may more preferably generate the trap folder as a hidden attribute.
  • the method may further include outputting a malware infection message by the alarm module.
  • the monitoring module preferably blocks the request if there is a request for write access to the target file.
  • each block in the accompanying block diagram and each step in the flowchart may be performed by computer program instructions.
  • These computer program instructions may be mounted on a processor of a general purpose computer, special purpose computer, or other programmable data processing equipment such that instructions executed through the processor of the computer or other programmable data processing equipment may not be included in each block or flowchart of the block diagram. It will create means for performing the functions described in each step.
  • These computer program instructions may be stored in a computer usable or computer readable memory that can be directed to a computer or other programmable data processing equipment to implement functionality in a particular manner, and thus the computer usable or computer readable memory.
  • instructions stored in may produce an article of manufacture containing instruction means for performing the functions described in each block or flowchart of each step of the block diagram.
  • Computer program instructions may also be mounted on a computer or other programmable data processing equipment, such that a series of operating steps may be performed on the computer or other programmable data processing equipment to create a computer-implemented process to create a computer or other programmable data. Instructions that perform processing equipment may also provide steps for performing the functions described in each block of the block diagram and in each step of the flowchart.
  • each block or step may represent a portion of a module, segment or code that includes one or more executable instructions for executing a specified logical function (s).
  • a specified logical function s.
  • the functions noted in the blocks or steps may occur out of order.
  • the two blocks or steps shown in succession may in fact be executed substantially concurrently or the blocks or steps may sometimes be performed in the reverse order, depending on the functionality involved.
  • Figure 1 is a schematic block diagram of a malicious code monitoring apparatus 100 according to an embodiment of the present invention, the target file generation module 110, monitoring module 120, execution program interruption module 130 It may include an alarm module 140.
  • the malicious code infected with the user's system and encrypting arbitrary files of the user selectively encrypts only files expected to be user files without encrypting general computer system files.
  • the malware detects (1) a plurality of files in the user storage device, (2) detects an encryption target that is expected to be a user file, and (3) encrypts the target user file (4). This is done by changing the extension of the user file.
  • the malicious code may be an executable file that encrypts any user document file of the user system.
  • the user file encrypted by the malicious code may be various types of files that the user stores and manages in his / her system, such as document files, image files such as pictures, and video files.
  • Such malware may be executed as an independent executable file, but may be executed by parasitic execution of any executable program capable of processing a user file to be encrypted.
  • the present invention first generates any target object to be encrypted by the malicious code, and monitors whether the target object is processed, if it is detected that the target object is processed. Through the process of terminating the execution program processing the target object, the user file is prevented from being encrypted by the malicious code.
  • malware malicious code monitoring apparatus and method according to the present invention may be executed together with a security program (vaccine) installed and executed in a user system or as a separate execution program.
  • vaccine security program
  • the target file generation module 110 When the malicious code monitoring apparatus 100 for executing the malicious code monitoring method according to the present invention is installed and executed in a user system, first, the target file generation module 110 generates a target object in the user system (S110).
  • the target object is generated as a file that can be encrypted by malicious code, and a file extension of a type generally generated by a user (eg, "hwp", "doc”, so that the malicious code can be recognized as a user file). "jpg”, "txt”, etc.).
  • This target file functions as a trap file recognized as a user file by malicious code.
  • malware codes executed in the Windows operating system environment are searched from the root of the drive by using an application program interface (API) such as FindFirstFile and FindNextFile.
  • API application program interface
  • Malware that encrypts user files retrieves user files from the user's main drive (usually a "C" drive) to a removable disk.
  • the malicious code searches the root of the main drive to find the target to encrypt, and if there is no target file to encrypt in the root, it searches the subfolders in order.
  • the target file is formed in the highest path in the storage device (fixed drive, removable drive, etc.) in which the user file is stored in the user system. That is, the target file is preferably created to have a file name that can be searched before a user file in a file search by malicious code, or is created in a folder that can be searched first by malicious code. At this time, since the target file is generated for the monitoring of malicious code, the user should not access it randomly.
  • the target file may be set as a "hidden property", but in this case, the malicious code may not recognize the target file as a user file. Therefore, it is preferable that the target file is generated in the trap folder created in the top path, rather than directly in the top path (root) of the user storage device.
  • the trap folder 210 is generated to have a folder name that can be searched first by malicious code.
  • the WINDOW OS is created to have a folder name starting with a lower-order letter of ASCII code among the allowable characters in the path name (ie, folder name).
  • files or folders are searched in the following order: "!, "@", "#", "$", And so on. ! " For example, a target to be encrypted is detected for a file in a folder whose name starts with a lower ASCII code character.
  • FIG. 3 and 4 show an example in which a target file 211 having various types of extensions is created in a trap folder 210 having a folder name "@ $ HbgVF" first searched for by malicious code. It was.
  • the malicious code first attempts to encrypt the target file 211 generated in the trap folder 210.
  • the folder attribute of the trap folder 210 is set as a "hidden attribute", whereby it is desirable to prevent the user from accessing the trap folder 210 and the target file 210 therein arbitrarily.
  • the monitoring module 120 constantly monitors whether the generated target file is processed (S120). For example, malicious code running in the Windows operating system environment can access a file (CreateFile or ZwCreateFile) or modify a file (WriteFile or ZwWriteFile) to secure write access rights to a target when performing encryption. ), The API execution sequence of handle termination (CloseHandle or ZwClose) is performed. As a result, malicious code inevitably requires write access to the file in order to encrypt the file. Therefore, the monitoring module 120 continuously monitors whether a request for obtaining write access permission is received for the generated target files (S121).
  • a request for obtaining write access permission is received for the generated target files (S121).
  • a “thread” is a unit of flow executed in a process when executing a computer program, that is, a series of executable code, and generally has its own unique ID. Therefore, the monitoring module 120 checks a thread that requests write access to the target files, and stores a unique ID of the thread.
  • the thread ID of the thread is provided to the execution program stopping module 130. Then, the execution program interruption module 130 forcibly terminates the thread corresponding to the unique ID (S130).
  • the malicious code may continuously try to encrypt other user files. Therefore, after checking the thread requesting the write access permission by the monitoring module 120, the thread making the request must be forcibly terminated to prevent the encryption of the user file due to the execution of the malicious code.
  • the malware first encrypts the target file among the files of the user system.
  • the malicious code may be driven in various ways to encrypt the target file.
  • the malicious code may process and encrypt the target file by itself, or may be parasitic to any executable program and be executed by the target program. You can also encrypt files while processing them.
  • execution of the malicious code may be forcibly terminated by the execution program interruption module 130.
  • the malicious code is injected and run on an unspecified normal system process, it is preferable to selectively terminate only the corresponding thread rather than terminating the normal system process.
  • the alarm module 140 notifies the user that the system is infected with malware. It may be displayed (S140). Through this, the user can back up his important document file to another storage device, thereby effectively preventing his important user file from being encrypted by malware.
  • the present invention may be embodied as computer readable codes on a computer readable recording medium.
  • the computer-readable recording medium includes all kinds of recording devices in which data that can be read by a computer system is stored. Examples of computer-readable recording media include ROM, RAM, CD-ROM, magnetic tape, floppy disk, optical data storage, and the like, and are also implemented in the form of carrier wave (for example, transmission over the Internet). It also includes.
  • the computer readable recording medium can also be distributed over network coupled computer systems so that the computer readable code is stored and executed in a distributed fashion.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Virology (AREA)
  • Storage Device Security (AREA)

Abstract

A device for monitoring a malicious code according to the present invention comprises: a target file generation module for generating a target file for monitoring a malicious code on a storage device in which a user file is stored; a monitoring module for, if a request for write access is issued to the target file, confirming a thread which issued the request for write access; and a running program abort module for forcibly stopping the thread identified by the monitoring module.

Description

사용자파일을 암호화하는 악성코드의 모니터링 장치 및 방법Apparatus and method for monitoring malicious code encrypting user files
본 발명은 컴퓨터 바이러스 또는 악성코드를 탐지하는 기술에 관한 것이다.The present invention relates to a technique for detecting a computer virus or malware.
잘 알려진 바와 같이, 메모리 및 통신 기술이 발달함에 따라 컴퓨터의 성능이 과거에 비해 대폭 향상되었으며, 특히 네트워크 기반 시설의 발달에 의해 인터넷의 보급이 확장되고 있는 실정이다. 이러한 인터넷 등의 통신기술의 발달에 의해, 수많은 컴퓨터들이 서로 연결되어 정보를 공유하고 있으며, 그 사용자 수는 날로 늘어나고 있다.As is well known, with the development of memory and communication technology, the performance of computers has been greatly improved compared to the past, and in particular, the spread of the Internet is being expanded by the development of network infrastructure. With the development of communication technologies such as the Internet, numerous computers are connected to each other to share information, and the number of users is increasing day by day.
이렇게 수많은 컴퓨터들이 네트워킹에 의해 서로 연결된 환경은 악성코드, 혹은 컴퓨터 바이러스 등에 의한 피해를 더욱 가속시킨다. 다른 인터넷 사용자의 정보를 허가 없이 해킹하여 불법으로 유용하거나, 다른 인터넷 사용자의 컴퓨터 단말기, 서버 등을 잠식하는 악성코드(또는 바이러스)는 심각한 사회문제로 대두되고 있다. 특히, 악성코드는 인터넷을 사용하는 사용자가 다른 사람의 컴퓨터에 데이터를 전송하거나, 사용자가 의도하지 않은 엉뚱한 사이트가 인터넷 사이트로 설정되도록 사용자 컴퓨터의 내부 시스템 레지스트리를 변경하는 등 다양한 형태로 문제를 일으킨다. 이러한 악성코드는 대체로 인터넷에서 쉽게 구하는 파일 프로그램을 통해서, 혹은 임의의 사이트에 인터넷 접속하는 것만으로도 사용자 컴퓨터에 설치된다.The environment in which many computers are connected to each other by networking further accelerates the damage caused by malware or computer viruses. Malware (or viruses) that hack information of other Internet users without permission and use it illegally or infiltrate computer terminals and servers of other Internet users are emerging as serious social problems. In particular, malicious code causes problems in various forms, such as when a user who uses the Internet sends data to another person's computer, or by changing an internal system registry of the user's computer so that the wrong site that the user does not intend is set as an Internet site. . Such malware is usually installed on a user's computer through file programs that are easily available on the Internet, or simply by accessing the Internet to arbitrary sites.
한편, 최근에는 사용자 시스템에 감염되어 문서파일 등의 사용자파일을 암호화한 후, 이를 사용자에게 경고함과 아울러 암호화된 문서 복구를 위해 비트코인 등으로 사용자에게 금전을 요구하는 악성코드가 기승이다. 이러한 종류의 악성코드는 백신 프로그램 등으로 탐지하여 해당 악성코드 파일을 삭제할 수는 있으나, 이미 암호화된 사용자의 문서파일을 다시 복구하는 것이 곤란하다. 즉, 현재까지 사용되고 있는 백신 프로그램에 의해서는 악성코드를 감지한 후 해당 파일을 삭제할 수는 있으나, 백신의 특성상 복호화 키를 알 수 없으므로, 이미 암호화된 사용자의 문서파일의 복구는 불가능하다.On the other hand, recently, after the malware infected with the user system to encrypt the user file, such as a document file, and warns the user, and to recover the encrypted document, such as malware to request the user money with Bitcoin is on the rise. This kind of malware can be detected by an antivirus program or the like, and the malicious code file can be deleted, but it is difficult to recover the document file of an already encrypted user. That is, the antivirus program used to date can delete the file after detecting the malicious code. However, since the decryption key is not known due to the nature of the vaccine, it is impossible to recover the document file of an already encrypted user.
사용자파일을 암호화하는 악성코드에 따른 피해를 방지하기 위해서는 해당 악성코드가 사용자파일을 암호화하기 전에 미리 탐지하여 차단할 필요가 있다. 이를 위해, 본 발명은 사용자파일을 암호화하는 악성코드가 최초로 실행되는 것을 탐지하여 사용자 컴퓨터에 저장된 중요한 파일이 암호화되는 것을 미리 방지할 수 있는, 악성코드 모니터링 장치 및 방법을 제공하는 것을 목적으로 한다.In order to prevent damage caused by malware that encrypts a user file, it is necessary to detect and block the malicious code before encrypting the user file. To this end, an object of the present invention is to provide a malicious code monitoring apparatus and method that can detect the execution of the malicious code encrypting the user file for the first time to prevent the important file stored in the user computer is encrypted.
본 발명에 따른 악성코드 모니터링 장치는, 사용자파일을 암호화하는 악성코드를 모니터링하기 위한 것으로서, 사용자파일이 저장된 저장장치에 악성코드의 감시를 위한 대상파일을 생성하는 대상파일 생성모듈; 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 보낸 스레드를 확인하는 모니터링모듈; 및 상기 모니터링모듈에 의해 확인된 상기 스레드를 강제 종료하는 실행프로그램 중단모듈;을 포함하여 달성될 수 있다.The malicious code monitoring apparatus according to the present invention includes a target file generation module for monitoring a malicious code encrypting a user file and generating a target file for monitoring the malicious code in a storage device in which the user file is stored; A monitoring module for checking a thread which sends the request when a write access right request is made to the target file; And an execution program interrupting module forcibly terminating the thread identified by the monitoring module.
여기서, 상기 대상파일 생성모듈은, 상기 저장장치의 최상위 경로에 트랩폴더를 생성하고, 상기 트랩폴더 내에 상기 대상파일을 생성하는 것이 바람직하다. 이때, 상기 트랩폴더는 상기 악성코드에 의해 최초로 검색되는 폴더명을 갖는 것이 더욱 바람직하다. 그리고, 상기 트랩폴더는 숨김속성으로 생성되는 것이 바람직하다.Here, the target file generation module preferably generates a trap folder in the highest path of the storage device, and generates the target file in the trap folder. At this time, it is more preferable that the trap folder has a folder name searched first by the malicious code. In addition, the trap folder is preferably created with a hidden attribute.
아울러, 본 발명에 따른 장치는, 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 악성코드 감염 메세지를 출력하는 알람모듈을 더 포함할 수 있다. 나아가, 상기 모니터링모듈은 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 차단하는 것이 바람직하다.In addition, the apparatus according to the present invention may further include an alarm module for outputting a malicious code infection message when a request for write access permission is made to the target file. Further, the monitoring module preferably blocks the request when there is a request for write access permission to the target file.
본 발명에 따른 사용자파일을 암호화하는 악성코드의 모니터링 방법은, 대상파일 생성모듈이 사용자파일이 저장된 저장장치에 상기 악성코드의 감시를 위한 대상파일을 생성하는 제1 단계; 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 모니터링모듈이 해당 요청을 보낸 스레드를 확인하는 제2 단계; 및 실행프로그램 중단모듈이 상기 모니터링모듈에 의해 확인된 상기 스레드를 강제 종료하는 제3 단계;를 포함하여 수행될 수 있다.The method for monitoring malicious code encrypting a user file according to the present invention includes: a first step of generating, by a target file generation module, a target file for monitoring the malicious code in a storage device in which a user file is stored; A second step of checking, by the monitoring module, a thread which has sent the request, when there is a request for write access right to the target file; And a third step of executing, by the execution program interruption module, the thread forcibly terminating the thread identified by the monitoring module.
상기 제1 단계에서, 상기 대상파일 생성모듈이, 상기 저장장치의 최상위 경로에 트랩폴더를 생성하고, 상기 트랩폴더 내에 상기 대상파일을 생성하는 것이 바람직하다. 그리고, 상기 대상파일 생성모듈은 상기 악성코드에 의해 최초로 검색되는 폴더명을 갖는 상기 트랩폴더를 생성하는 것이 바람직하다. 특히, 상기 대상파일 생성모듈은 상기 트랩폴더를 숨김속성으로 생성하는 것이 더욱 바람직하다.In the first step, it is preferable that the target file generation module generates a trap folder in the highest path of the storage device and generates the target file in the trap folder. In addition, the target file generation module preferably generates the trap folder having a folder name searched first by the malicious code. In particular, the target file generation module may more preferably generate the trap folder as a hidden attribute.
아울러, 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우, 알람모듈에 의해 악성코드 감염 메세지를 출력하는 단계를 더 포함할 수 있다.In addition, when there is a request for write access permission to the target file, the method may further include outputting a malware infection message by the alarm module.
그리고, 제 2 단계에서, 상기 모니터링모듈은 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 차단하는 것이 바람직하다.In the second step, the monitoring module preferably blocks the request if there is a request for write access to the target file.
본 발명의 과제를 해결하기 위하여, 상기 악성코드 모니터링 방법을 컴퓨터에서 실행시키기 위한 프로그램이 기록된 컴퓨터로 읽을 수 있는 기록매체를 제공할 수 있다.In order to solve the problem of the present invention, it is possible to provide a computer-readable recording medium in which a program for executing the malicious code monitoring method on a computer is recorded.
본 발명에 따른 악성코드 모니터링 장치 및 방법에 의하면, 사용자의 중요한 파일이 악성코드에 의해 암호화되는 것을 효과적으로 방지할 수 있다. 종래의 백신프로그램에 의해서는 악성코드를 감지한 후 이를 삭제할 수는 있으나, 이미 암호화된 사용자파일을 복구하는 것이 불가능하였다. 그러나, 본 발명에 따르면, 악성코드에 의해 최초로 암호화될 가상의 대상개체를 생성하고, 이 대상개체가 프로세싱되는 것을 모니터링하면서, 악성코드가 실행되거나 혹은 악성코드가 부수하여 실행되는 응용프로그램의 실행을 중단시킴으로써, 사용자의 중요한 파일이 암호화되는 것을 미리 예방할 수 있다.According to the malware monitoring apparatus and method according to the present invention, an important file of a user can be effectively prevented from being encrypted by malware. Conventional antivirus programs can detect malware and delete it, but it is not possible to recover user files that have already been encrypted. However, according to the present invention, while creating a virtual target object to be first encrypted by the malicious code and monitoring the processing of the target object, the execution of the application executed by the malicious code or by the accompanying malicious code is executed. By stopping, the user's important files can be prevented from being encrypted in advance.
도 1은 본 발명에 따른 악성코드 모니터링 장치에 대한 개략적인 블록 구성도이다.1 is a schematic block diagram of a malicious code monitoring apparatus according to the present invention.
도 2는 본 발명에 따른 악성코드 모니터링 방법을 수행하는 과정을 예시한 흐름도이다.2 is a flowchart illustrating a process of performing a malicious code monitoring method according to the present invention.
도 3은 본 발명에 따른 악성코드 모니터링 장치 및 방법에 따라 사용자 시스템 내에 트랩폴더가 생성된 예를 도시한다.3 illustrates an example in which a trap folder is generated in a user system according to an apparatus and a method for monitoring malware according to the present invention.
도 4는 본 발명에 따른 악성코드 모니터링 장치 및 방법에 따라 사용자 시스템에 생성된 트랩폴더 내에 대상파일이 생성된 예를 도시한다.4 illustrates an example in which a target file is generated in a trap folder created in a user system according to a malicious code monitoring apparatus and method according to the present invention.
본 발명에 따른 악성코드 모니터링 장치는, 사용자파일을 암호화하는 악성코드를 모니터링하기 위한 것으로서, 사용자파일이 저장된 저장장치에 악성코드의 감시를 위한 대상파일을 생성하는 대상파일 생성모듈; 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 보낸 스레드를 확인하는 모니터링모듈; 및 상기 모니터링모듈에 의해 확인된 상기 스레드를 강제 종료하는 실행프로그램 중단모듈;을 포함하여 달성될 수 있다.The malicious code monitoring apparatus according to the present invention includes a target file generation module for monitoring a malicious code encrypting a user file and generating a target file for monitoring the malicious code in a storage device in which the user file is stored; A monitoring module for checking a thread which sends the request when a write access right request is made to the target file; And an execution program interrupting module forcibly terminating the thread identified by the monitoring module.
여기서, 상기 대상파일 생성모듈은, 상기 저장장치의 최상위 경로에 트랩폴더를 생성하고, 상기 트랩폴더 내에 상기 대상파일을 생성하는 것이 바람직하다. 이때, 상기 트랩폴더는 상기 악성코드에 의해 최초로 검색되는 폴더명을 갖는 것이 더욱 바람직하다. 그리고, 상기 트랩폴더는 숨김속성으로 생성되는 것이 바람직하다.Here, the target file generation module preferably generates a trap folder in the highest path of the storage device, and generates the target file in the trap folder. At this time, it is more preferable that the trap folder has a folder name searched first by the malicious code. In addition, the trap folder is preferably created with a hidden attribute.
아울러, 본 발명에 따른 장치는, 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 악성코드 감염 메세지를 출력하는 알람모듈을 더 포함할 수 있다. 나아가, 상기 모니터링모듈은 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 차단하는 것이 바람직하다.In addition, the apparatus according to the present invention may further include an alarm module for outputting a malicious code infection message when a request for write access permission is made to the target file. Further, the monitoring module preferably blocks the request when there is a request for write access permission to the target file.
본 발명에 따른 사용자파일을 암호화하는 악성코드의 모니터링 방법은, 대상파일 생성모듈이 사용자파일이 저장된 저장장치에 상기 악성코드의 감시를 위한 대상파일을 생성하는 제1 단계; 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 모니터링모듈이 해당 요청을 보낸 스레드를 확인하는 제2 단계; 및 실행프로그램 중단모듈이 상기 모니터링모듈에 의해 확인된 상기 스레드를 강제 종료하는 제3 단계;를 포함하여 수행될 수 있다.The method for monitoring malicious code encrypting a user file according to the present invention includes: a first step of generating, by a target file generation module, a target file for monitoring the malicious code in a storage device in which a user file is stored; A second step of checking, by the monitoring module, a thread which has sent the request, when there is a request for write access right to the target file; And a third step of executing, by the execution program interruption module, the thread forcibly terminating the thread identified by the monitoring module.
상기 제1 단계에서, 상기 대상파일 생성모듈이, 상기 저장장치의 최상위 경로에 트랩폴더를 생성하고, 상기 트랩폴더 내에 상기 대상파일을 생성하는 것이 바람직하다. 그리고, 상기 대상파일 생성모듈은 상기 악성코드에 의해 최초로 검색되는 폴더명을 갖는 상기 트랩폴더를 생성하는 것이 바람직하다. 특히, 상기 대상파일 생성모듈은 상기 트랩폴더를 숨김속성으로 생성하는 것이 더욱 바람직하다.In the first step, it is preferable that the target file generation module generates a trap folder in the highest path of the storage device and generates the target file in the trap folder. In addition, the target file generation module preferably generates the trap folder having a folder name searched first by the malicious code. In particular, the target file generation module may more preferably generate the trap folder as a hidden attribute.
아울러, 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우, 알람모듈에 의해 악성코드 감염 메세지를 출력하는 단계를 더 포함할 수 있다.In addition, when there is a request for write access permission to the target file, the method may further include outputting a malware infection message by the alarm module.
그리고, 제 2 단계에서, 상기 모니터링모듈은 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 차단하는 것이 바람직하다.In the second step, the monitoring module preferably blocks the request if there is a request for write access to the target file.
본 발명의 과제를 해결하기 위하여, 상기 악성코드 모니터링 방법을 컴퓨터에서 실행시키기 위한 프로그램이 기록된 컴퓨터로 읽을 수 있는 기록매체를 제공할 수 있다.In order to solve the problem of the present invention, it is possible to provide a computer-readable recording medium in which a program for executing the malicious code monitoring method on a computer is recorded.
본 발명의 상세한 설명에 앞서, 이하에서 설명되는 본 명세서 및 청구범위에 사용된 용어나 단어는 통상적이거나 사전적인 의미로 한정해서 해석되어서는 아니 되며, 발명자는 그 자신의 발명을 가장 최선의 방법으로 설명하기 위해 용어의 개념으로 적절하게 정의할 수 있다는 원칙에 입각하여 본 발명의 기술적 사상에 부합하는 의미와 개념으로 해석되어야만 한다. 따라서 본 명세서에 기재된 실시예와 도면에 도시된 구성은 본 발명의 가장 바람직한 실시예에 불과할 뿐, 본 발명의 기술적 사상을 모두 대변하는 것은 아니므로, 본 출원시점에 있어서 이들을 대체할 수 있는 다양한 균등물과 변형 예들이 있을 수 있음을 이해하여야 한다.Prior to the description of the present invention, the terms or words used in the specification and claims described below should not be construed as being limited to the ordinary or dictionary meanings, and the inventors should consider their own invention in the best way. For the purpose of explanation, it should be interpreted as meaning and concept corresponding to the technical idea of the present invention on the basis of the principle that it can be appropriately defined as the concept of term. Therefore, the embodiments described in the present specification and the configuration shown in the drawings are only the most preferred embodiments of the present invention, and do not represent all of the technical idea of the present invention, and various equivalents may be substituted for them at the time of the present application. It should be understood that there may be water and variations.
아울러, 첨부된 블록도의 각 블록과 흐름도의 각 단계의 조합들은 컴퓨터 프로그램 인스트럭션들에 의해 수행될 수도 있다. 이들 컴퓨터 프로그램 인스트럭션들은 범용 컴퓨터, 특수용 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비의 프로세서에 탑재될 수 있으므로, 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비의 프로세서를 통해 수행되는 그 인스트럭션들이 블록도의 각 블록 또는 흐름도의 각 단계에서 설명된 기능들을 수행하는 수단을 생성하게 된다. 이들 컴퓨터 프로그램 인스트럭션들은 특정 방식으로 기능을 구현하기 위해 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비를 지향할 수 있는 컴퓨터 이용 가능 또는 컴퓨터 판독 가능 메모리에 저장되는 것도 가능하므로, 그 컴퓨터 이용가능 또는 컴퓨터 판독 가능 메모리에 저장된 인스트럭션들은 블록도의 각 블록 또는 흐름도 각 단계에서 설명된 기능을 수행하는 인스트럭션 수단을 내포하는 제조 품목을 생산하는 것도 가능하다. 컴퓨터 프로그램 인스트럭션들은 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비 상에 탑재되는 것도 가능하므로, 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비 상에서 일련의 동작 단계들이 수행되어 컴퓨터로 실행되는 프로세스를 생성해서 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비를 수행하는 인스트럭션들은 블록도의 각 블록 및 흐름도의 각 단계에서 설명된 기능들을 실행하기 위한 단계들을 제공하는 것도 가능하다.In addition, the combination of each block in the accompanying block diagram and each step in the flowchart may be performed by computer program instructions. These computer program instructions may be mounted on a processor of a general purpose computer, special purpose computer, or other programmable data processing equipment such that instructions executed through the processor of the computer or other programmable data processing equipment may not be included in each block or flowchart of the block diagram. It will create means for performing the functions described in each step. These computer program instructions may be stored in a computer usable or computer readable memory that can be directed to a computer or other programmable data processing equipment to implement functionality in a particular manner, and thus the computer usable or computer readable memory. It is also possible for the instructions stored in to produce an article of manufacture containing instruction means for performing the functions described in each block or flowchart of each step of the block diagram. Computer program instructions may also be mounted on a computer or other programmable data processing equipment, such that a series of operating steps may be performed on the computer or other programmable data processing equipment to create a computer-implemented process to create a computer or other programmable data. Instructions that perform processing equipment may also provide steps for performing the functions described in each block of the block diagram and in each step of the flowchart.
또한, 각 블록 또는 각 단계는 특정된 논리적 기능(들)을 실행하기 위한 하나 이상의 실행 가능한 인스트럭션들을 포함하는 모듈, 세그먼트 또는 코드의 일부를 나타낼 수 있다. 또, 몇가지 대체 실시예들에서는 블록들 또는 단계들에서 언급된 기능들이 순서를 벗어나서 발생하는 것도 가능함을 주목해야 한다. 예컨대, 잇달아 도시되어 있는 두 개의 블록들 또는 단계들은 사실 실질적으로 동시에 수행되는 것도 가능하고 또는 그 블록들 또는 단계들이 때때로 해당하는 기능에 따라 역순으로 수행되는 것도 가능하다.In addition, each block or step may represent a portion of a module, segment or code that includes one or more executable instructions for executing a specified logical function (s). It should also be noted that in some alternative embodiments, the functions noted in the blocks or steps may occur out of order. For example, the two blocks or steps shown in succession may in fact be executed substantially concurrently or the blocks or steps may sometimes be performed in the reverse order, depending on the functionality involved.
이하에서는, 본 발명에 따른 악성코드 모니터링 방법에 대한 바람직한 실시예를 상세히 설명할 것이다. 다만, 본 발명의 요지를 흐리게 할 수 있는 공지 기능 및 구성에 대한 상세한 설명은 생략할 것이다.Hereinafter, a preferred embodiment of the malicious code monitoring method according to the present invention will be described in detail. However, detailed descriptions of well-known functions and configurations that may blur the gist of the present invention will be omitted.
먼저, 도 1은 본 발명의 일 실시예에 따른 악성코드 모니터링 장치(100)에 대한 개략적인 블록 구성도로서, 대상파일 생성모듈(110), 모니터링모듈(120), 실행프로그램 중단모듈(130), 알람모듈(140)을 포함할 수 있다.First, Figure 1 is a schematic block diagram of a malicious code monitoring apparatus 100 according to an embodiment of the present invention, the target file generation module 110, monitoring module 120, execution program interruption module 130 It may include an alarm module 140.
여기서, 사용자 시스템에 감염되어 사용자의 임의의 파일(이하, '사용자파일'이라고 함)을 암호화하는 악성코드는, 일반적인 컴퓨터 시스템 파일은 암호화하지 않고 사용자파일로 예상되는 파일만을 선택적으로 암호화한다. 이를 위해, 악성코드는, (1) 사용자 저장장치 내의 복수의 파일들을 검색하여, (2) 사용자파일로 예상되는 암호화 대상을 검출한 후에, (3) 대상이 되는 사용자파일을 암호화하고, (4) 해당 사용자파일의 확장자를 변경하는 방식으로 실행된다.Here, the malicious code infected with the user's system and encrypting arbitrary files of the user (hereinafter, referred to as 'user file') selectively encrypts only files expected to be user files without encrypting general computer system files. To this end, the malware detects (1) a plurality of files in the user storage device, (2) detects an encryption target that is expected to be a user file, and (3) encrypts the target user file (4). This is done by changing the extension of the user file.
여기서, 상기 악성코드는 사용자 시스템의 임의의 사용자 문서파일을 암호화하는 실행파일일 수 있다. 아울러, 상기 악성코드가 암호화하는 사용자파일은 사용자가 작성한 문서파일, 사진 등의 이미지 파일, 동영상 파일 등 사용자가 자신의 시스템에 저장 및 관리하는 다양한 종류의 파일일 수 있다.Here, the malicious code may be an executable file that encrypts any user document file of the user system. In addition, the user file encrypted by the malicious code may be various types of files that the user stores and manages in his / her system, such as document files, image files such as pictures, and video files.
이러한 악성코드는 독립적인 실행파일로서 실행될 수도 있으나, 암호화하고자 하는 사용자 파일을 프로세싱할 수 있는 임의의 실행프로그램에 기생하여 실행될 수도 있다.Such malware may be executed as an independent executable file, but may be executed by parasitic execution of any executable program capable of processing a user file to be encrypted.
이러한 악성코드의 실행 방식을 감안하여, 본 발명에서는, 먼저 악성코드에 의해 암호화될 임의의 대상개체를 생성하고, 상기 대상개체가 프로세싱되는지 여부를 모니터링하면서, 만약 상기 대상개체가 프로세싱되는 것이 감지되면 상기 대상개체를 프로세싱하는 실행프로그램을 종료하는 과정을 통해, 악성코드에 의해 사용자파일이 암호화되는 것을 방지하게 된다.In view of the manner in which the malicious code is executed, the present invention first generates any target object to be encrypted by the malicious code, and monitors whether the target object is processed, if it is detected that the target object is processed. Through the process of terminating the execution program processing the target object, the user file is prevented from being encrypted by the malicious code.
아울러, 본 발명에 따른 악성코드 모니터링 장치 및 방법은, 사용자 시스템에 설치되어 실행되는 보안프로그램(백신)과 함께 혹은 별도의 실행프로그램으로서 실행될 수 있다.In addition, the malicious code monitoring apparatus and method according to the present invention may be executed together with a security program (vaccine) installed and executed in a user system or as a separate execution program.
도 1 및 도 2를 참조하여, 본 발명에 따른 악성코드 모니터링 장치 및 방법의 구체적인 수행과정을 설명하면 다음과 같다.Referring to Figures 1 and 2, it will be described the specific implementation of the malicious code monitoring apparatus and method according to the present invention.
[대상개체의 생성][Creation of target object]
본 발명에 따른 악성코드 모니터링 방법을 실행하는 악성코드 모니터링 장치(100)가 사용자 시스템에 설치되어 실행되면, 먼저 대상파일 생성모듈(110)이 사용자 시스템에 대상개체를 생성한다(S110). 이때, 상기 대상개체는 악성코드에 의해 암호화될 수 있는 파일로서 생성되는데, 악성코드가 사용자파일로 인식할 수 있도록 사용자가 일반적으로 생성하는 유형의 파일 확장자(예컨대, "hwp", "doc", "jpg", "txt" 등)를 갖는다. 이러한 대상파일은 악성코드에 의해 사용자파일로 인식되는 트랩파일로서 기능한다.When the malicious code monitoring apparatus 100 for executing the malicious code monitoring method according to the present invention is installed and executed in a user system, first, the target file generation module 110 generates a target object in the user system (S110). In this case, the target object is generated as a file that can be encrypted by malicious code, and a file extension of a type generally generated by a user (eg, "hwp", "doc", so that the malicious code can be recognized as a user file). "jpg", "txt", etc.). This target file functions as a trap file recognized as a user file by malicious code.
한편, 일반적으로 윈도우 운영체제 환경에서 실행되는 악성코드는 FindFirstFile, FindNextFile 등과 같은 API(Application Program Interface)를 이용하여 드라이브의 루트부터 검색한다. 사용자파일을 암호화하는 악성코드는, 사용자 시스템의 메인 드라이브(통상 "C" 드라이브)부터 이동식 디스크에 걸쳐 사용자파일을 검색하게 된다. 즉, 악성코드는 메인드라이브의 "루트"(root)부터 검색하여 암호화할 대상을 찾고, 만약 루트에 암호화할 대상 파일이 없으면 하위 폴더를 차례대로 검색하게 된다.On the other hand, in general, malicious codes executed in the Windows operating system environment are searched from the root of the drive by using an application program interface (API) such as FindFirstFile and FindNextFile. Malware that encrypts user files retrieves user files from the user's main drive (usually a "C" drive) to a removable disk. In other words, the malicious code searches the root of the main drive to find the target to encrypt, and if there is no target file to encrypt in the root, it searches the subfolders in order.
이러한 점에 착안하여, 사용자 시스템 내에서 사용자파일이 저장된 저장장치(고정형 드라이브, 이동식 드라이브 등)에서 최상위 경로에 대상파일을 형성한다. 즉, 상기 대상파일은 악성코드에 의한 파일 검색에서 사용자파일보다 먼저 검색될 수 있는 파일명을 갖도록 생성되거나, 혹은 악성코드에 의해 먼저 검색될 수 있는 폴더 내에 생성되는 것이 바람직하다. 이때, 대상파일은 악성코드의 감시를 위하여 생성하는 것이기 때문에, 사용자가 임의로 접근하여 억세스하지 못하도록 해야 한다. 이를 위해, 대상파일을 "숨김속성"으로 설정할 수 있으나, 이 경우 악성코드가 대상파일을 사용자파일로 인식하지 않을 수 있다. 따라서, 대상파일이 사용자 저장장치의 최상위 경로(루트)에 직접 생성되는 것보다, 최상위 경로에 생성된 트랩폴더 내에 생성되는 것이 바람직하다.With this in mind, the target file is formed in the highest path in the storage device (fixed drive, removable drive, etc.) in which the user file is stored in the user system. That is, the target file is preferably created to have a file name that can be searched before a user file in a file search by malicious code, or is created in a folder that can be searched first by malicious code. At this time, since the target file is generated for the monitoring of malicious code, the user should not access it randomly. For this purpose, the target file may be set as a "hidden property", but in this case, the malicious code may not recognize the target file as a user file. Therefore, it is preferable that the target file is generated in the trap folder created in the top path, rather than directly in the top path (root) of the user storage device.
도 3에는 사용자 저장장치의 최상위 경로(C 드라이브의 루트)에 트랩폴더가 생성된 상태를 예시하였다. 여기서, 트랩폴더(210)는 악성코드에 의해 최초로 검색될 수 있는 폴더명을 갖도록 생성된다. 예컨대, 사용자 시스템이 WINDOW OS에 의해 운영되는 경우, WINDOW OS에서 경로명(즉, 폴더명)으로 허용가능한 문자 중 아스키코드(ASCII Code)의 순위가 낮은 문자로 시작하는 폴더명을 갖도록 생성된다. 즉, 경로명(혹은 파일명)으로 사용하지 못하는 문자를 제외하면, "!", "@", "#", "$" 등의 순서로 파일 또는 폴더가 검색되므로, 악성코드는 사용자 시스템 내에서 "!" 등과 같이 아스키코드의 순위가 낮은 문자로 시작하는 명칭을 가진 폴더 내의 파일에 대해 암호화할 대상을 검출하게 된다.3 illustrates a state in which a trap folder is generated in a top path of a user storage device (root of a C drive). Here, the trap folder 210 is generated to have a folder name that can be searched first by malicious code. For example, when the user system is operated by the WINDOW OS, the WINDOW OS is created to have a folder name starting with a lower-order letter of ASCII code among the allowable characters in the path name (ie, folder name). In other words, except for characters that cannot be used as path names (or file names), files or folders are searched in the following order: "!", "@", "#", "$", And so on. ! " For example, a target to be encrypted is detected for a file in a folder whose name starts with a lower ASCII code character.
일례로, 도 3 및 도 4에는, 악성코드에 의해 최초로 검색되는 "@$HbgVF"라는 폴더명을 갖는 트랩폴더(210) 내에 다양한 종류의 확장자를 갖는 대상파일(211)이 생성된 예를 도시하였다. 이러한 방식으로 대상파일을 생성하면, 악성코드는 트랩폴더(210) 내에 생성된 대상파일(211)에 대해 최초로 암호화를 시도하게 된다. 이때, 트랩폴더(210)의 폴더 속성은 "숨김 속성"으로 설정되며, 그에 의해 사용자가 임의로 트랩폴더(210) 및 그 내부의 대상파일(210)을 억세스하지 못하도록 하는 것이 바람직하다.3 and 4 show an example in which a target file 211 having various types of extensions is created in a trap folder 210 having a folder name "@ $ HbgVF" first searched for by malicious code. It was. When the target file is generated in this manner, the malicious code first attempts to encrypt the target file 211 generated in the trap folder 210. At this time, the folder attribute of the trap folder 210 is set as a "hidden attribute", whereby it is desirable to prevent the user from accessing the trap folder 210 and the target file 210 therein arbitrarily.
[대상파일의 프로세싱 모니터링][Monitoring processing of target file]
다음으로, 모니터링모듈(120)은 생성된 대상파일이 프로세싱되는지 여부를 상시적으로 감시한다(S120). 예컨대, 윈도우 운영체제 환경에서 실행되는 악성코드는 암호화 작업을 수행할 때, 대상에 대한 쓰기 접근 권한(Write Access Right)의 확보를 위하여, 파일의 접근(CreateFile 또는 ZwCreateFile), 파일의 수정(WriteFile 또는 ZwWriteFile), 핸들의 종료(CloseHandle 또는 ZwClose)의 API 실행 순서를 거치게 된다. 결과적으로, 악성코드가 파일을 암호화하기 위해서는 파일에 대한 쓰기 접근 권한을 필연적으로 요청하게 된다. 따라서, 모니터링모듈(120)은 생성된 대상파일들에 대하여 쓰기 접근 권한의 획득 요청이 들어오는지 여부를 계속하여 감시한다(S121).Next, the monitoring module 120 constantly monitors whether the generated target file is processed (S120). For example, malicious code running in the Windows operating system environment can access a file (CreateFile or ZwCreateFile) or modify a file (WriteFile or ZwWriteFile) to secure write access rights to a target when performing encryption. ), The API execution sequence of handle termination (CloseHandle or ZwClose) is performed. As a result, malicious code inevitably requires write access to the file in order to encrypt the file. Therefore, the monitoring module 120 continuously monitors whether a request for obtaining write access permission is received for the generated target files (S121).
한편, 사용자가 자신의 시스템을 사용하는 중에, 임의의 실행프로그램에 의해 대상파일에 대한 쓰기 접근 권한 요청이 감지되면, 해당 요청을 차단함과 동시에 대상파일에 대한 쓰기 접근 권한을 요청한 스레드(Thread)를 확인한다(S122). 여기서, "스레드"는 컴퓨터 프로그램을 수행할 때 프로세스 내에서 실행되는 흐름의 단위로, 즉 일련의 실행 코드를 말하며, 일반적으로 자신만의 고유 ID(Identificatio)를 가진다. 따라서, 모니터링모듈(120)은 대상파일들에 대해 쓰기 접근 권한을 요청한 스레드를 확인하고, 해당 스레드의 고유 ID를 저장한다.On the other hand, if a user writes a request for write access to the target file by any executable program while using his system, the thread will block the request and request write access to the target file. Check (S122). Here, a "thread" is a unit of flow executed in a process when executing a computer program, that is, a series of executable code, and generally has its own unique ID. Therefore, the monitoring module 120 checks a thread that requests write access to the target files, and stores a unique ID of the thread.
[실행프로그램의 중단][Interruption of Execution Program]
모니터링모듈(120)에 의해 대상파일에 대하 억세스하려고 시도하는 스레드가 확인되면, 해당 스레드의 고유 ID를 실행프로그램 중단모듈(130)에 제공한다. 그리고, 실행프로그램 중단모듈(130)은 고유 ID에 대응하는 스레드를 강제로 종료한다(S130).When the thread that attempts to access the target file is checked by the monitoring module 120, the thread ID of the thread is provided to the execution program stopping module 130. Then, the execution program interruption module 130 forcibly terminates the thread corresponding to the unique ID (S130).
모니터링모듈(120)이 대상파일에 대한 쓰기 접근 권한 요청을 차단하더라도, 악성코드는 다른 사용자파일들에 대해 지속적으로 암호화를 시도할 수 있다. 따라서, 모니터링모듈(120)에 의해 쓰기 접근 권한을 요청한 스레드를 확인한 후에, 해당 요청을 한 스레드를 강제로 종료시켜야 악성코드의 실행에 따른 사용자파일의 암화화를 막을 수 있다. Even if the monitoring module 120 blocks the write access permission request for the target file, the malicious code may continuously try to encrypt other user files. Therefore, after checking the thread requesting the write access permission by the monitoring module 120, the thread making the request must be forcibly terminated to prevent the encryption of the user file due to the execution of the malicious code.
한편, 사용자 시스템이 악성코드에 감염된 경우, 상기 악성코드는 사용자 시스템의 파일들 중에서 대상파일에 대해 최초로 암호화한다. 이때, 상기 악성코드는 상기 대상파일을 암화화하기 위해 다양한 방법으로 구동될 수 있는데, 악성코드 스스로 직접 대상파일을 프로세싱하여 암호화할 수도 있고, 임의의 실행프로그램에 기생하여 해당 실행프로그램에 의해 상기 대상파일을 프로세싱하면서 암호화할 수도 있다. 악성코드 스스로 직접 대상파일을 프로세싱하여 암호화하는 경우, 실행프로그램 중단모듈(130)에 의해 악성코드의 실행이 강제 종료될 수 있다. 그러나, 만약 악성코드가 불특정한 정상 시스템 프로세스에 인젝션되어 구동되는 경우에는, 정상적인 시스템 프로세스를 종료시키기 보다는 해당 스레드만 선택적으로 종료시키는 것이 바람직하다. 악성코드가 인젝션된 정상 프로세스 내부에는 스레드가 1개만 존재할 수 있도 있으나, 2 이상의 스레드가 생성될 수 있다. 그러므로, 대상파일에 대한 쓰기 접근 권한을 요청한 스레드만을 종료시키는 방법을 통해 정상 프로세스 내부에서 악성코드가 인젝션된 스레드만을 선택적으로 찾아서 강제 종료시키는 것이 바람직하다.On the other hand, if the user system is infected with malware, the malware first encrypts the target file among the files of the user system. In this case, the malicious code may be driven in various ways to encrypt the target file. The malicious code may process and encrypt the target file by itself, or may be parasitic to any executable program and be executed by the target program. You can also encrypt files while processing them. When the malicious code itself processes and encrypts the target file, execution of the malicious code may be forcibly terminated by the execution program interruption module 130. However, if the malicious code is injected and run on an unspecified normal system process, it is preferable to selectively terminate only the corresponding thread rather than terminating the normal system process. Only one thread may exist inside a normal process in which malicious code is injected, but two or more threads may be created. Therefore, it is preferable to selectively find only the thread injected with malicious code in the normal process and forcefully terminate the thread through the method of terminating only the thread that has requested write access to the target file.
[악성코드 감염 사실에 대한 경고][Warning about malware infection]
사용자 시스템에 악성코드가 감염되었음이 확인되면, 즉 모니터링모듈(120)에 의해 대상파일에 대한 쓰기 접근 권한의 요청이 있으면, 알람모듈(140)이 사용자에게 시스템이 악성코드에 감염되었음을 알리는 메세지를 표시할 수 있다(S140). 이를 통해, 사용자는 자신이 보유한 중요한 문서파일을 다른 저장장치에 백업할 수 있으므로, 악성코드에 의해 자신의 중요한 사용자파일이 암호화되는 것을 효과적으로 방지할 수 있다.If the user system is confirmed that the malicious code is infected, that is, if the request for the write access rights to the target file by the monitoring module 120, the alarm module 140 notifies the user that the system is infected with malware. It may be displayed (S140). Through this, the user can back up his important document file to another storage device, thereby effectively preventing his important user file from being encrypted by malware.
종래의 백신프로그램에 의해서는 악성코드를 감지한 후 이를 삭제할 수는 있으나, 이미 암호화된 사용자파일을 복구하는 것이 불가능하였다. 그러나, 이상에서 설명한 바와 같이, 본 발명에 따른 악성코드 모니터링 장치 및 방법에 의하면, 사용자의 중요한 파일이 악성코드에 의해 암호화되는 것을 효과적으로 방지할 수 있다.Conventional antivirus programs can detect malware and delete it, but it is not possible to recover user files that have already been encrypted. However, as described above, according to the malware monitoring apparatus and method according to the present invention, it is possible to effectively prevent the user's important files are encrypted by the malware.
아울러 본 발명은 컴퓨터로 읽을 수 있는 기록매체에 컴퓨터가 읽을 수 있는 코드로서 구현될 수 있다. 컴퓨터가 읽을 수 있는 기록매체는, 컴퓨터 시스템에 의하여 읽혀질 수 있는 데이터가 저장되는 모든 종류의 기록장치를 포함한다. 컴퓨터가 읽을 수 있는 기록매체의 예로는, ROM, RAM, CD-ROM, 자기테이프, 플로피디스크, 광데이터 저장장치 등이 있으며, 또한 캐리어 웨이브(예를 들어, 인터넷을 통한 전송)의 형태로 구현되는 것도 포함된다. 또한, 컴퓨터가 읽을 수 있는 기록매체는 네트워크로 연결된 컴퓨터 시스템에 분산되어 분산방식으로 컴퓨터가 읽을 수 있는 코드가 저장되고 실행될 수 있다.In addition, the present invention may be embodied as computer readable codes on a computer readable recording medium. The computer-readable recording medium includes all kinds of recording devices in which data that can be read by a computer system is stored. Examples of computer-readable recording media include ROM, RAM, CD-ROM, magnetic tape, floppy disk, optical data storage, and the like, and are also implemented in the form of carrier wave (for example, transmission over the Internet). It also includes. The computer readable recording medium can also be distributed over network coupled computer systems so that the computer readable code is stored and executed in a distributed fashion.
지금까지 본 발명의 바람직한 실시예에 대해 설명하였으나, 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자는 본 발명의 본질적인 특성을 벗어나지 않는 범위 내에서 변형된 형태로 구현할 수 있을 것이다. 그러므로 여기서 설명한 본 발명의 실시예는 한정적인 관점이 아니라 설명적인 관점에서 고려되어야 하고, 본 발명의 범위는 상술한 설명이 아니라 특허청구범위에 나타나 있으며, 그와 동등한 범위 내에 있는 모든 차이점은 본 발명에 포함되는 것으로 해석되어야 한다.Although a preferred embodiment of the present invention has been described so far, those skilled in the art will be able to implement in a modified form without departing from the essential characteristics of the present invention. Therefore, the embodiments of the present invention described herein are to be considered in descriptive sense only and not for purposes of limitation, and the scope of the present invention is shown in the appended claims rather than the foregoing description, and all differences within the equivalent scope are set forth in the present invention. Should be interpreted as being included in.

Claims (13)

  1. 사용자파일이 저장된 저장장치에 악성코드의 감시를 위한 대상파일을 생성하는 대상파일 생성모듈;A target file generation module for generating a target file for monitoring malicious codes in a storage device in which a user file is stored;
    상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 보낸 스레드를 확인하는 모니터링모듈; 및A monitoring module for checking a thread which sends the request when a write access right request is made to the target file; And
    상기 모니터링모듈에 의해 확인된 상기 스레드를 강제 종료하는 실행프로그램 중단모듈;을 포함하는, 악성코드 모니터링 장치.And an execution program interruption module forcibly terminating the thread identified by the monitoring module.
  2. 제 1 항에 있어서,The method of claim 1,
    상기 대상파일 생성모듈은, 상기 저장장치의 최상위 경로에 트랩폴더를 생성하고, 상기 트랩폴더 내에 상기 대상파일을 생성하는 것을 특징으로 하는, 악성코드 모니터링 장치.The target file generation module generates a trap folder in a top path of the storage device and generates the target file in the trap folder.
  3. 제 2 항에 있어서,The method of claim 2,
    상기 트랩폴더는 상기 악성코드에 의해 최초로 검색되는 폴더명을 갖는 것을 특징으로 하는, 악성코드 모니터링 장치.The trap folder is characterized in that it has a folder name first searched by the malicious code, malware monitoring device.
  4. 제 2 항에 있어서,The method of claim 2,
    상기 트랩폴더는 숨김속성으로 생성되는 것을 특징으로 하는, 악성코드 모니터링 장치.The trap folder is characterized in that the generated hidden attribute, malware monitoring device.
  5. 제 1 항에 있어서,The method of claim 1,
    상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 악성코드 감염 메세지를 출력하는 알람모듈을 더 포함하는 것을 특징으로 하는, 악성코드 모니터링 장치.And an alarm module for outputting a malicious code infection message when there is a request for write access permission to the target file.
  6. 제 1 항에 있어서,The method of claim 1,
    상기 모니터링모듈은 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 차단하는 것을 특징으로 하는, 악성코드 모니터링 장치.The monitoring module may block the request if there is a request for write access permission to the target file.
  7. 사용자파일을 암화화하는 악성코드의 모니터링 방법으로서,As a method of monitoring malicious codes that encrypt user files,
    대상파일 생성모듈이, 사용자파일이 저장된 저장장치에 상기 악성코드의 감시를 위한 대상파일을 생성하는 제1 단계;A first step of generating, by the target file generation module, a target file for monitoring the malicious code in a storage device in which a user file is stored;
    상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 모니터링모듈이 해당 요청을 보낸 스레드를 확인하는 제2 단계; 및A second step of checking, by the monitoring module, a thread which has sent the request, when there is a request for write access right to the target file; And
    실행프로그램 중단모듈이 상기 모니터링모듈에 의해 확인된 상기 스레드를 강제 종료하는 제3 단계;를 포함하는, 악성코드 모니터링 방법.And a third step in which an execution program interruption module forcibly terminates the thread identified by the monitoring module.
  8. 제 7 항에 있어서,The method of claim 7, wherein
    상기 제1 단계에서, 상기 대상파일 생성모듈이, 상기 저장장치의 최상위 경로에 트랩폴더를 생성하고, 상기 트랩폴더 내에 상기 대상파일을 생성하는 것을 특징으로 하는, 악성코드 모니터링 방법.In the first step, the target file generation module, characterized in that for generating a trap folder in the highest path of the storage device, and generates the target file in the trap folder, malicious code monitoring method.
  9. 제 8 항에 있어서,The method of claim 8,
    상기 대상파일 생성모듈은 상기 악성코드에 의해 최초로 검색되는 폴더명을 갖는 상기 트랩폴더를 생성하는 것을 특징으로 하는, 악성코드 모니터링 방법.The target file generation module generates the trap folder having a folder name first searched by the malicious code.
  10. 제 8 항에 있어서,The method of claim 8,
    상기 대상파일 생성모듈은 상기 트랩폴더를 숨김속성으로 생성하는 것을 특징으로 하는, 악성코드 모니터링 방법.The target file generation module generates the trap folder as a hidden attribute, malicious code monitoring method.
  11. 제 7 항에 있어서,The method of claim 7, wherein
    상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우, 알람모듈에 의해 악성코드 감염 메세지를 출력하는 단계를 더 포함하는 것을 특징으로 하는, 악성코드 모니터링 방법.And outputting a malicious code infection message by an alarm module when a write access right request is made for the target file.
  12. 제 7 항에 있어서,The method of claim 7, wherein
    제 2 단계에서, 상기 모니터링모듈은 상기 대상파일에 대하여 쓰기 접근 권한의 요청이 있는 경우 해당 요청을 차단하는 것을 특징으로 하는, 악성코드 모니터링 방법.In the second step, the monitoring module, if there is a request for write access permission for the target file, characterized in that to block the request, malware monitoring method.
  13. 제 7 항 내지 제 12 항 중 어느 한 항에 따른 악성코드 모니터링 방법을 컴퓨터에서 실행시키기 위한 프로그램이 기록된, 컴퓨터로 읽을 수 있는 기록매체.A computer-readable recording medium having recorded thereon a program for executing the malicious code monitoring method according to any one of claims 7 to 12.
PCT/KR2016/006650 2015-11-30 2016-06-23 Device and method for monitoring malicious code encrypting user files WO2017094990A1 (en)

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
KR20150169017 2015-11-30
KR10-2015-0169017 2015-11-30
KR1020160022397A KR101710918B1 (en) 2015-11-30 2016-02-25 Method for monitoring malwares which encrypt user files
KR10-2016-0022397 2016-02-25

Publications (1)

Publication Number Publication Date
WO2017094990A1 true WO2017094990A1 (en) 2017-06-08

Family

ID=58543080

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/KR2016/006650 WO2017094990A1 (en) 2015-11-30 2016-06-23 Device and method for monitoring malicious code encrypting user files

Country Status (2)

Country Link
KR (2) KR101710918B1 (en)
WO (1) WO2017094990A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116305291A (en) * 2023-05-16 2023-06-23 北京安天网络安全技术有限公司 Office document secure storage method, device, equipment and medium

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101828600B1 (en) * 2017-03-08 2018-03-22 주식회사 체크멀 Context-aware ransomware detection
US20230045098A1 (en) * 2019-12-31 2023-02-09 Dsrv Labs Co., Ltd. System and method for preventing suspicious transactions in distributed ledger
KR102358800B1 (en) * 2019-12-31 2022-02-07 주식회사 디에스알브이랩스 System For Preventing Fraud Transactions in Distributed Ledger

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20090034648A (en) * 2007-10-04 2009-04-08 한국전자통신연구원 The method and apparatus for analyzing exploit code in non-executable file using virtual environment
US20090133125A1 (en) * 2007-11-21 2009-05-21 Yang Seo Choi Method and apparatus for malware detection
KR20100078081A (en) * 2008-12-30 2010-07-08 (주) 세인트 시큐리티 System and method for detecting unknown malicious codes by analyzing kernel based system events
KR20130074224A (en) * 2011-12-26 2013-07-04 ㈜ 와이에이치 데이타베이스 Apparatus and method of collecting action pattern of malicious code
KR20140023459A (en) * 2012-08-13 2014-02-27 주식회사 안랩 Program protection apparatus and program protection method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20090034648A (en) * 2007-10-04 2009-04-08 한국전자통신연구원 The method and apparatus for analyzing exploit code in non-executable file using virtual environment
US20090133125A1 (en) * 2007-11-21 2009-05-21 Yang Seo Choi Method and apparatus for malware detection
KR20100078081A (en) * 2008-12-30 2010-07-08 (주) 세인트 시큐리티 System and method for detecting unknown malicious codes by analyzing kernel based system events
KR20130074224A (en) * 2011-12-26 2013-07-04 ㈜ 와이에이치 데이타베이스 Apparatus and method of collecting action pattern of malicious code
KR20140023459A (en) * 2012-08-13 2014-02-27 주식회사 안랩 Program protection apparatus and program protection method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116305291A (en) * 2023-05-16 2023-06-23 北京安天网络安全技术有限公司 Office document secure storage method, device, equipment and medium
CN116305291B (en) * 2023-05-16 2023-07-21 北京安天网络安全技术有限公司 Office document secure storage method, device, equipment and medium

Also Published As

Publication number Publication date
KR101710918B1 (en) 2017-02-28
KR101737794B1 (en) 2017-05-23

Similar Documents

Publication Publication Date Title
US11611586B2 (en) Systems and methods for detecting a suspicious process in an operating system environment using a file honeypots
US11489855B2 (en) System and method of adding tags for use in detecting computer attacks
US10032025B1 (en) Behavior-based ransomware detection
EP3365828B1 (en) Methods for data loss prevention from malicious applications and targeted persistent threats
Kharaz et al. {UNVEIL}: A {Large-Scale}, automated approach to detecting ransomware
US10193918B1 (en) Behavior-based ransomware detection using decoy files
EP3107024B1 (en) System and method of restoring modified data
US9648032B2 (en) System and method for blocking execution of scripts
US9514309B1 (en) Systems and methods for protecting files from malicious encryption attempts
US7657941B1 (en) Hardware-based anti-virus system
US10079835B1 (en) Systems and methods for data loss prevention of unidentifiable and unsupported object types
US20160099960A1 (en) System and method for scanning hosts using an autonomous, self-destructing payload
WO2013055029A1 (en) Device and method for displaying a watermark on a screen
US20120144449A1 (en) Method and system for protecting confidential information
US8955138B1 (en) Systems and methods for reevaluating apparently benign behavior on computing devices
WO2017094990A1 (en) Device and method for monitoring malicious code encrypting user files
US20100306184A1 (en) Method and device for processing webpage data
US20090328210A1 (en) Chain of events tracking with data tainting for automated security feedback
WO2013100320A1 (en) System, user terminal, method, and apparatus for protecting and recovering system file.
US9225735B1 (en) Systems and methods for blocking flanking attacks on computing systems
US10116688B1 (en) Systems and methods for detecting potentially malicious files
US20140359772A1 (en) Detecting sensitive data access by reporting presence of benign pseudo virus signatures
Aziz Ransomware in High-Risk Environments
Kakareka Detecting system intrusions
WO2014030978A1 (en) Mobile storage medium safety system and method thereof

Legal Events

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

Ref document number: 16870887

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16870887

Country of ref document: EP

Kind code of ref document: A1