KR20140072855A - Flash memory system and encryption method thereof - Google Patents
Flash memory system and encryption method thereof Download PDFInfo
- Publication number
- KR20140072855A KR20140072855A KR1020140062356A KR20140062356A KR20140072855A KR 20140072855 A KR20140072855 A KR 20140072855A KR 1020140062356 A KR1020140062356 A KR 1020140062356A KR 20140062356 A KR20140062356 A KR 20140062356A KR 20140072855 A KR20140072855 A KR 20140072855A
- Authority
- KR
- South Korea
- Prior art keywords
- error correction
- correction code
- flash memory
- encrypted
- error
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/08—Error detection or correction by redundancy in data representation, e.g. by using checking codes
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
- G06F12/16—Protection against loss of memory contents
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Techniques For Improving Reliability Of Storages (AREA)
- Quality & Reliability (AREA)
Abstract
Description
본 발명은 플래시 메모리 시스템에 관한 것으로, 좀 더 구체적으로는 멀티비트 데이터를 각각 저장하는 메모리 셀을 갖는 플래시 메모리 시스템의 암호화 방법에 관한 것이다.The present invention relates to a flash memory system, and more particularly, to a method of encrypting a flash memory system having memory cells each storing multi-bit data.
일반적인 플래시 메모리의 어레이(Array)는 데이터를 저장하는 메인 영역(Main Area)과 스페어 영역(Spare Area)을 포함한다. 스페어 영역은 데이터에 대한 에러 정정 코드(ECC;Error Correction Code), 및 플래시 변환 레이어(FTL:Flash Translation Layer) 등을 포함한다. 예를 들면, 플래시 메모리의 한 페이지(page)에 대한 메인 영역이 512 Byte인 경우 스페어 영역은 16 Byte이다. A typical array of flash memories includes a main area for storing data and a spare area. The spare area includes an error correction code (ECC) for data, and a flash translation layer (FTL). For example, if the main area for a page of the flash memory is 512 Bytes, the spare area is 16 Bytes.
플래시 변환 레이어는 쓰기 연산(Write operation) 시에 파일시스템이 생성한 논리주소를 플래시 메모리 상의 이미 삭제연산을 수행한 영역에 대한 물리주소로 변환하는 역할을 수행한다.The flash conversion layer converts a logical address generated by the file system into a physical address for an area that has already been erased on the flash memory in a write operation.
에러 검출 및 정정 기술들은 다양한 원인들로 인해 손상되는 데이터의 효율적인 복구를 제공한다. 예를 들면, 메모리에 데이터를 저장하는 과정에서 다양한 원인들로 인해서 데이터가 손상될 수 있고, 소오스에서 목적지로 데이터가 전송되는 데이터 전송 채널의 불안(perturbations)에 의해서 데이터가 손상될 수 있다.Error detection and correction techniques provide efficient recovery of damaged data due to various causes. For example, in the process of storing data in the memory, data may be damaged due to various causes, and data may be damaged by perturbations of the data transmission channel in which data is transmitted from the source to the destination.
손상된 데이터를 검출하고 정정하기 위한 다양한 방법들이 제안되고 있다. 잘 알려진 에러 검출 기술들에는 RS 코드(Reed-Solomon code), 헤밍 코드(Hamming code), BCH(Bose-Chaudhuri-Hocquenghem) 코드, CRC(Cyclic Redundancy Code) 코드 등이 있다. 이러한 코드들을 이용하여 손상된 데이터를 검출하고 정정하는 것이 가능하다. Various methods have been proposed for detecting and correcting corrupted data. Well-known error detection techniques include RS codes (Reed-Solomon codes), Hamming codes, Bose (Bose-Chaudhuri-Hocquenghem) codes, and CRC (Cyclic Redundancy Code) codes. It is possible to detect and correct corrupted data using these codes.
불휘발성 메모리 장치가 사용되는 대부분의 응용 분야에 있어서, 데이터는 에러 정정 코드(error correcting code: ECC)라 불리는 값 (이하, ECC 라 칭함)과 함께 플래시 메모리 장치에 저장된다. ECC 데이터는 플래시 메모리 장치의 읽기 동작시 발생하는 에러를 정정하기 위한 것이다. ECC 데이터를 이용하여 정정 가능한 비트 에러 수는 제한되어 있다. 읽기 동작시 생기는 비트 에러는 잘 알려진 블록 대체(block replacement)와 같은 별도의 구제 과정없이 에러 검출 및 정정 기술을 통해 정정될 수 있다.In most applications where a non-volatile memory device is used, the data is stored in a flash memory device along with a value called an error correcting code (ECC). The ECC data is used to correct an error that occurs during a read operation of the flash memory device. The number of correctable bit errors is limited using ECC data. The bit error that occurs during a read operation can be corrected through error detection and correction techniques without a separate remedy such as well known block replacement.
멀티 비트 데이터를 각각 저장하는 메모리 셀들을 갖는 플래시 메모리는 멀티 레벨 셀(Multi-level Cell;MLC)의 고유한 특성으로 인하여 데이터 내부에 비트 에러를 포함한다. 따라서, 비트 에러를 정정하기 위하여 플래시 메모리는 스페어 영역에 에러 정정 코드를 포함한다. 만약 비트 에러가 발생되면 플래시 메모리 시스템은 에러 정정 코드에 근거하여 비트 에러를 정정한다. A flash memory having memory cells each storing multi-bit data includes a bit error in the data due to the inherent characteristics of a multi-level cell (MLC). Therefore, in order to correct the bit error, the flash memory includes an error correction code in the spare area. If a bit error occurs, the flash memory system corrects the bit error based on the error correction code.
일반적인 플래시 메모리 시스템은 공격자(Attacker)로부터 플래시 메모리의 메인 영역의 해킹을 방지하기 위하여 플래시 메모리의 메인 영역의 데이터를 암호화(Encryption)한다. 그리고, 플래시 메모리 시스템은 암호화된 메인 영역의 데이터에 대한 에러 정정 코드를 스페어 영역에 저장한다.A typical flash memory system encrypts data in the main area of the flash memory to prevent hacking of the main area of the flash memory from the attacker. The flash memory system stores an error correction code for data in the encrypted main area in the spare area.
본 발명의 목적은 플래시 메모리의 데이터를 효율적으로 암호화하는 플래시 메모리 시스템 및 플래시 메모리 시스템의 암호화 방법을 제공하는 데 있다.An object of the present invention is to provide a flash memory system and an encryption method of a flash memory system which efficiently encrypt data of a flash memory.
본 발명의 실시 예에 따른 플래시 메모리 시스템은 입력 데이터를 저장하는 플래시 메모리; 및 상기 플래시 메모리를 제어하는 메모리 컨트롤러를 포함하고, 상기 메모리 컨트롤러는 상기 입력 데이터에 대한 제1 에러 정정 코드를 생성하고, 상기 제1 에러 정정 코드를 암호화하고, 상기 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드를 생성하고, 상기 플래시 메모리는 상기 입력 데이터를 저장하는 제1 영역 및 상기 암호화된 제1 에러 정정 코드 및 상기 제2 에러 정정 코드를 저장하는 제2 영역을 포함한다.A flash memory system according to an embodiment of the present invention includes a flash memory for storing input data; And a memory controller for controlling the flash memory, wherein the memory controller generates a first error correction code for the input data, encrypts the first error correction code, and outputs the encrypted first error correction code And the flash memory includes a first area for storing the input data and a second area for storing the encrypted first error correction code and the second error correction code.
실시 예로서, 상기 메모리 컨트롤러는 상기 제1 에러 정정 코드를 암호화하고, 상기 암호화된 제1 에러 정정 코드를 복호화하는 암호화 및 복호화부; 그리고 상기 제1 에러 정정 코드와 상기 제2 에러 정정 코드를 생성하는 에러 정정 코드 생성부를 포함한다.In an embodiment, the memory controller includes: an encryption and decryption unit for encrypting the first error correction code and for decrypting the encrypted first error correction code; And an error correction code generator for generating the first error correction code and the second error correction code.
실시 예로서, 상기 메모리 컨트롤러는 외부로부터 전송된 키를 이용하여 상기 제1 에러 정정 코드를 암호화한다.In an embodiment, the memory controller encrypts the first error correction code using a key transmitted from the outside.
실시 예로서, 상기 제2 영역은 상기 암호화된 제1 에러 정정 코드, 상기 제2 에러 정정 코드, 및 플래시 변환 레이어를 저장한다.In an embodiment, the second area stores the encrypted first error correction code, the second error correction code, and the flash conversion layer.
본 발명의 다른 실시 예에 따른 제1 영역 및 제2 영역을 포함하는 플래시 메모리 시스템의 암호화 방법은 입력 데이터에 대한 제1 에러 정정 코드를 생성하는 단계; 상기 제1 에러 정정 코드를 암호화하는 단계; 상기 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드를 생성하는 단계; 및 상기 입력 데이터를 상기 제1 영역에 저장하고, 상기 암호화된 제1 에러 정정 코드 및 상기 제2 에러 정정 코드를 상기 제2 영역에 저장하는 단계; 상기 입력 데이터, 상기 암호화된 제1 에러 정정 코드, 및 제2 에러 정정 코드를 독출하는 단계; 상기 암호화된 제1 에러 정정 코드의 에러를 검출하는 단계; 상기 제1 에러 정정 코드의 에러가 검출된 경우, 상기 제2 에러 정정 코드를 디코딩하여 상기 암호화된 제1 에러 정정 코드의 에러를 정정하는 단계; 상기 암호화된 제1 에러 정정 코드를 복호화하는 단계; 상기 입력 데이터의 에러를 검출하는 단계; 및 상기 입력 데이터에 에러가 검출된 경우 상기 복호화된 제1 에러 정정 코드를 디코딩하여 상기 입력 데이터의 에러를 정정하는 단계를 포함한다.A method of encrypting a flash memory system including a first area and a second area according to another embodiment of the present invention includes: generating a first error correction code for input data; Encrypting the first error correction code; Generating a second error correction code for the encrypted first error correction code; And storing the input data in the first area and storing the encrypted first error correction code and the second error correction code in the second area; Reading the input data, the encrypted first error correction code, and the second error correction code; Detecting an error of the encrypted first error correction code; Correcting the error of the encrypted first error correction code by decoding the second error correction code if an error of the first error correction code is detected; Decrypting the encrypted first error correction code; Detecting an error of the input data; And correcting the error of the input data by decoding the decoded first error correction code if an error is detected in the input data.
본 발명의 또 다른 실시 예에 따른 플래시 메모리 시스템은 입력 데이터를 저장하는 플래시 메모리; 및 상기 플래시 메모리를 제어하는 메모리 컨트롤러를 포함하고, 상기 메모리 컨트롤러는 상기 입력 데이터에 대한 제1 에러 정정 코드를 생성하는 에러 정정 코드 생성부; 및 상기 제1 에러 정정 코드를 암호화하고, 상기 암호화된 제1 에러 정정 코드를 복호화하는 암호화 및 복호화부를 포함하고, 상기 플래시 메모리는 복수의 페이지들을 포함하고, 상기 복수의 페이지들 각각은 메인 영역 및 스페어 영역을 포함하고, 상기 메모리 컨트롤러는 상기 입력 데이터를 상기 메인 영역에 저장하고, 상기 암호화된 제1 에러 정정 코드를 상기 스페어 영역에 저장한다.According to another aspect of the present invention, there is provided a flash memory system including: a flash memory for storing input data; And a memory controller for controlling the flash memory, wherein the memory controller comprises: an error correction code generator for generating a first error correction code for the input data; And an encryption and decryption unit for encrypting the first error correction code and for decrypting the encrypted first error correction code, wherein the flash memory includes a plurality of pages, Wherein the memory controller stores the input data in the main area and stores the encrypted first error correction code in the spare area.
실시 예로서, 상기 메인 영역은 복수의 제1 워드들을 포함하고, 상기 스페어 영역은 복수의 제2 워드들을 포함한다.In an embodiment, the main area includes a plurality of first words, and the spare area includes a plurality of second words.
실시 예로서, 상기 복수의 제2 워드들 중 일부에 상기 암호화된 제1 에러 정정 코드가 저장된다.As an embodiment, the encrypted first error correction code is stored in a part of the plurality of second words.
실시 예로서, 상기 에러 정정 코드 생성부는 상기 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드를 생성한다.In an embodiment, the error correction code generator generates a second error correction code for the encrypted first error correction code.
실시 예로서, 상기 제2 에러 정정 코드는 상기 복수의 제2 워드들 중 하나에 저장되고, 상기 암호화된 제1 에러 정정 코드보다 크기가 작다.In an embodiment, the second error correction code is stored in one of the plurality of second words and is smaller than the encrypted first error correction code.
본 발명은 일부의 데이터를 암호화함으로 메모리 시스템의 성능을 향상하고, 암호화/복호화를 위한 하드웨어 및 소프트웨어의 오버헤드(Overhead)를 감소시키고, 부트 코드의 노출을 차단하는 효과를 가진다.The present invention has the effect of improving the performance of a memory system by encrypting some data, reducing the overhead of hardware and software for encryption / decryption, and blocking the exposure of the boot code.
도 1은 본 발명에 따른 메모리 시스템을 보여주는 블록도이다.
도 2는 도 1에 도시된 플래시 메모리의 어레이를 도시한 블록도이다.
도 3은 본 발명에 따른 플래시 메모리 시스템의 암호화 방법을 도시한 순서도이다.
도 4는 도 3에 따라 암호화된 플래시 메모리 시스템을 독출하는 방법을 도시한 순서도이다.1 is a block diagram illustrating a memory system in accordance with the present invention.
2 is a block diagram illustrating the array of flash memory shown in FIG.
3 is a flowchart showing an encryption method of a flash memory system according to the present invention.
4 is a flowchart illustrating a method of reading an encrypted flash memory system according to FIG.
본 발명에 따른 멀티 레벨 셀을 포함하는 플래시 메모리의 어레이(Array)는 데이터를 저장하는 메인 영역과 데이터의 에러 정정 코드를 저장하는 스페어 영역을 포함한다. An array of flash memories including multi-level cells according to the present invention includes a main area for storing data and a spare area for storing error correction codes of data.
멀티 레벨 셀을 포함하는 플래시 메모리의 데이터는 비트 에러를 포함하고 있으므로 공격자의 해킹으로부터 보호된다. 즉, 본 발명에 따른 플래시 메모리 시스템은 플래시 메모리의 스페어 영역을 암호화(Encryption)한다. 구체적으로, 본 발명은 스페어 영역 내의 메인 영역의 데이터에 대한 에러 정정 코드를 암호화한다. The data in the flash memory containing the multilevel cell is protected from attacker hacking because it contains bit errors. That is, the flash memory system according to the present invention encrypts the spare area of the flash memory. Specifically, the present invention encrypts an error correction code for data in a main area in a spare area.
따라서, 공격자는 비트 에러를 포함하는 데이터와 암호화된 에러 정정 코드를 해킹하고, 암호화된 에러 정정 코드를 복호화해야 정확한 정보를 구할 수 있다.Therefore, the attacker can hack the encrypted error correction code and data including the bit error, and decrypt the encrypted error correction code to obtain accurate information.
본 발명에 따른 플래시 메모리 시스템은 스페어 영역의 일부 데이터(즉, 에러 정정 코드)를 암호화함으로 플래시 메모리 시스템의 성능을 향상하고, 플래시 메모리 시스템의 암호화/복호화를 위한 하드웨어 및 소프트웨어의 오버헤드(Overhead)를 감소시킨다. The flash memory system according to the present invention improves the performance of the flash memory system by encrypting some data (i.e., error correction code) in the spare area, and overheads of hardware and software for encryption / .
이하, 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자가 본 발명의 기술적 사상을 용이하게 실시할 수 있도록 본 발명의 실시예를 첨부된 도면을 참조하여 설명한다.Hereinafter, embodiments of the present invention will be described with reference to the accompanying drawings so that those skilled in the art can easily implement the technical idea of the present invention.
도 1은 본 발명에 따른 메모리 시스템을 보여주는 블록도이다. 도 1을 참조하면, 본 발명에 따른 메모리 시스템(100)은 호스트(110), 메모리 컨트롤러(120), 그리고 플래시 메모리(130)를 포함한다.1 is a block diagram illustrating a memory system in accordance with the present invention. Referring to FIG. 1, a
도 1에서, 메모리 컨트롤러(120) 및 플래시 메모리(130)는 하나의 저장 장치 내에 포함될 수 있다. 이러한 저장 장치에는 USB 메모리 및 메모리 카드(M MC(Multi_Media Card), SD 카드, xD 카드, CF 카드, SIM 카드 등) 등과 같은 이동식 저장 장치도 포함된다. 또한, 이러한 저장 장치는 컴퓨터, 노트북, 디지털 카메라, 휴대폰, MP3 플레이어, PMP(Portable Multimedia Player), 게임기 등과 같은 호스트(110)에 접속되어 사용된다.1, the
본 발명에 따른 멀티레벨 셀을 포함하는 플래시 메모리(130)의 어레이(131)에는 다수의 비트 에러(Bit Error)가 존재한다. 따라서, 공격자는 어레이(131)의 메인 영역만을 해킹해서는 온전한 정보를 얻을 수 없다.A plurality of bit errors exist in the
본 발명에 따른 멀티레벨 셀을 포함하는 플래시 메모리(130)는 스페어 영역 내에 메인 영역에 대한 에러 정정 코드를 암호화한다. 즉, 공격자는 메인 영역과 스페어 영역을 모두를 해킹하여도 정확한 정보를 얻을 수 없다. The
도 1을 참조하면, 본 발명에 따른 플래시 메모리 시스템(100)은 호스트(110), 메모리 컨트롤러(120), 그리고 플래시 메모리(130)를 포함한다. Referring to FIG. 1, a
메모리 컨트롤러(120)는 호스트 인터페이스(121), 플래시 인터페이스(Flash Interface;122), 중앙처리장치(CPU;123), ECC(Error Correction Code) 회로(124), ROM(125), RAM(126), 및 Enc/Dec 회로(127)을 포함한다. The
호스트 인터페이스(121)는 호스트(110)와 인터페이스 하도록 구성되고, 플래시 인터페이스(122)는 플래시 메모리(130)와 인터페이스 하도록 구성된다. 중앙처리장치(123)는 호스트(110)의 요청에 응답하여 플래시 메모리(130)의 읽기 또는 쓰기 동작 등을 제어하도록 구성된다.The
ECC 회로(124)는 플래시 메모리(130)로 전송되는 데이터(메인 데이터)를 이용하여 메인 영역에 저장된 데이터에 대한 제1 에러 정정 코드 그리고 제1 에러 정정 코드를 암호화한 후에 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드를 생성한다. 암호화된 제1 에러 정정 코드와 제2 에러 정정 코드는 플래시 메모리(130)의 스페어 영역(spare area)에 저장된다. ECC 회로(124)는 플래시 메모리(130)로부터 읽혀진 데이터의 에러를 검출한다. 만약 검출된 에러가 정정 범위 내이면, ECC 회로(124)는 검출된 에러를 정정한다. 한편, ECC 회로(124)는 플래시 메모리 시스템(100)에 따라, 플래시 메모리(130) 내에 위치할 수도 있고, 메모리 컨트롤러(120) 밖에 위치할 수도 있다.The
ROM(125)은 플래시 메모리(130)으로부터 부트 코드(Boot code) 등을 로딩하기 위한 기본적인 OS(Operating System) 데이터 등을 저장하며, RAM(126)은 메인 메모리 또는 버퍼 메모리로 사용된다. RAM(126)은 플래시 메모리(130)로부터 읽혀진 데이터 또는 호스트(110)로부터 제공되는 데이터를 임시 저장한다. RAM(126)은 DRAM, SRAM 등으로 구현될 수 있다.The
한편, RAM(126)은 읽기 에러 정보를 관리하는 데 필요한 테이블 정보를 저장할 수 있다. 이 테이블 정보는 메타(meta) 데이터로, 중앙처리장치(123) 제어 하에 플래시 메모리(130)의 메타 영역에 저장된다. 이 테이블 정보는 파워 온(Power On) 시에 메타 영역으로부터 RAM(126)으로 복사된다. On the other hand, the
Enc/Dec 회로(127)는 제1 에러 정정 코드를 암호화(Encryption)하거나 복호화(Decryption)한다.The Enc /
계속해서 도 1을 참조하면, 플래시 메모리(130)는 셀 어레이(131) 및 제어 유닛(132)을 포함한다. 셀 어레이(131)는 부트 코드를 저장하는 메인 영역과 그에 관한 스페어 영역 그리고 호스트(110)로부터 전송된 데이터를 저장하는 메인 영역과 그에 관한 스페어 영역을 포함한다. 제어 유닛(132)은 당업자에게 잘 알려진 바와 같이, 로우 디코더, 칼럼 디코더, 페이지 버퍼, 비트 라인 선택 회로, 그리고 데이터 버퍼 등을 포함한다. 1, the
본 발명에 따른 플래시 메모리 시스템(100)은 파워 온(Power-on) 시에 중앙 처리 장치(123)의 제어에 응답하여 플래시 메모리(130) 내에 저장된 부트 코드 및 부트 코드에 대응하는 스페어 영역의 데이터를 램(126)에 로딩한다. The
스페어 영역에는 부트 코드, 부트 코드에 대한 암호화된 제1 에러 정정 코드, 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드, 및 플래시 변환 레이어 등이 저장된다. The spare area stores a boot code, an encrypted first error correction code for the boot code, a second error correction code for the encrypted first error correction code, and a flash conversion layer.
따라서, 공격자는 램(126)에 로딩된 부트 코드를 해킹한다 하더라도 부트 코드는 비트 에러를 포함하고 있으므로 완전한 부트 코드를 알아낼 수 없다.Thus, even if the attacker hacked the boot code loaded in the
즉, 본 발명에 따른 플래시 메모리 시스템은 파워-온 시에 비트 에러가 포함된 부트 코드와 암호화된 에러 정정 코드를 램에 로딩함으로 공격자로부터 부트 코드의 노출을 차단한다. 따라서, 본 발명에 따른 플래시 메모리 시스템을 포함하는 집적회로 카드의 보안 레벨을 높이는 효과가 있다. That is, the flash memory system according to the present invention blocks the exposure of the boot code from the attacker by loading the boot code including the bit error and the encrypted error correction code into the RAM at power-on. Therefore, there is an effect of increasing the security level of the integrated circuit card including the flash memory system according to the present invention.
도 2는 도 1에 도시된 플래시 메모리의 어레이를 도시한 블록도이다. 2 is a block diagram illustrating the array of flash memory shown in FIG.
도 1 및 도 2를 참조하면, 본 발명에 따른 플래시 메모리(130)은 어레이(131) 내에 메인 영역과 스페어 영역을 포함한다. Referring to FIGS. 1 and 2, a
도 2에 도시된 하나의 페이지는 호스트로부터 전송된 데이터를 저장하는 메인 영역과 메인 영역에 대한 제1 에러 정정 코드(ECC_FM)과 제2 에러 정정 코드(ECC_FS), 및 플래시 변환 레이어 등을 저장하는 스페어 영역을 포함한다. One page shown in FIG. 2 stores a first error correction code (ECC_FM), a second error correction code (ECC_FS), and a flash conversion layer for a main area and a main area for storing data transmitted from a host And a spare area.
도 2에서, 플래시 메모리의 어레이(131)에는 한 페이지만이 도시되었으나, 플래시 메모리의 어레이(131)에는 복수의 페이지와 상기 복수의 페이지를 포함하는 복수의 블록이 있음은 당업자에 있어서 자명하다.Although only one page is shown in the
계속해서 도 1 및 도 2를 참조하면, 본 발명에 따른 플래시 메모리의 메인 영역은 256 word로 구성되고, 스페어 영역은 8 word로 구성된다. 스페어 영역 내의 제1 워드부터 제7 워드는 제1 에러 정정 코드(ECC_FM) 및 플래시 변환 레이어 등을 포함하고, 스페어 영역 내의 제8 워드는 제1 에러 정정 코드(ECC_FM)에 대한 제2 에러 정정 코드(ECC_FS)를 포함한다. 1 and 2, the main area of the flash memory according to the present invention is composed of 256 words, and the spare area is composed of 8 words. The first to seventh words in the spare area include a first error correction code (ECC_FM) and a flash conversion layer, and the eighth word in the spare area includes a second error correction code (ECC_FM) for the first error correction code (ECC_FS).
일반적인 플래시 메모리 시스템이 메인 영역의 데이터를 암호화하는데 반하여, 본 발명의 실시예에 따른 플래시 메모리 시스템은 스페어 영역 내의 제1 워드부터 제7 워드 내에 저장된 데이터(Enc Area)를 암호화한다. While a conventional flash memory system encrypts data in a main area, a flash memory system according to an embodiment of the present invention encrypts data (Enc Area) stored in a first word to a seventh word in a spare area.
따라서, 본 발명에 따른 플래시 메모리 시스템은 스페어 영역의 일부 데이터(즉, 에러 정정 코드)를 암호화함으로 플래시 메모리 시스템의 성능을 향상하고, 플래시 메모리 시스템의 암호화/복호화를 위한 하드웨어 및 소프트웨어의 오버헤드(Overhead)를 감소시킨다. Therefore, the flash memory system according to the present invention improves the performance of the flash memory system by encrypting some data (i.e., error correction code) in the spare area, and overheads of hardware and software for encryption / Overhead.
도 3은 본 발명에 따른 플래시 메모리 시스템의 암호화 방법을 도시한 순서도이다. 3 is a flowchart showing an encryption method of a flash memory system according to the present invention.
도 1 내지 도 3을 참조하면, 중앙 처리 장치(123)는 호스트(110)로부터 전송된 데이터를 램(126)에 저장한다(31). ECC 회로(124)는 상기 호스트(110)로부터 전송된 데이터에 대한 제1 에러 정정 코드(ECC_FM)을 생성한다(32). Enc/Dec 회로(127)는 생성된 제1 에러 정정 코드(ECC_FM)를 암호화한다(33). ECC 회로(124)는 암호화된 제1 에러 정정 코드(ECC_FM)에 대한 제2 에러 정정 코드(ECC_FS)를 생성한다(34). 중앙 처리 장치(123)는 호스트(110)로부터 전송된 데이터, 암호화된 제1 에러 정정 코드(ECC_FM), 및 제2 에러 정정 코드(ECC_FS)를 플래시 메모리(130)에 저장한다(35).1 to 3, the
도 4는 도 1에 도시된 암호화된 플래시 메모리 시스템으로부터 데이터를 독출하는 방법을 도시한 순서도이다. 4 is a flow chart illustrating a method for reading data from the encrypted flash memory system shown in FIG.
도 1 내지 도 4를 참조하면, 중앙 처리 장치(123)는 플래시 메모리(130)로부터 데이터(메인 영역의 데이터, 암호화된 제1 에러 정정 코드(ECC_FM), 및 제2 에러 정정 코드(ECC_FS))를 독출한다(41).1 to 4, the
중앙 처리 장치(123)는 암호화된 제1 에러 정정 코드(ECC_FM)에 에러가 검출되는지를 판단한다(42). The
만약 암호화된 제1 에러 정정 코드(ECC_FM)에 에러가 검출된다면, ECC 회로(124)는 제2 에러 정정 코드(ECC_FS)를 디코딩(Decoding)한다(43). 즉, 중앙 처리 장치(123)는 제2 에러 정정 코드(ECC_FS)에 근거하여 암호화된 제1 에러 정정 코드(ECC_FM)의 에러를 정정한다. If an error is detected in the encrypted first error correction code (ECC_FM), the
Enc/Dec 회로(127)는 암호화된 제1 에러 정정 코드(ECC_FM)를 복호화한다(44). 중앙 처리 장치(123)는 메인 영역의 데이터에 에러가 검출되는지를 판단한다(45). The Enc /
만약 메인 영역의 데이터에 에러가 검출된다면, ECC 회로(124)는 제1 에러 정정 코드(ECC_FM)를 디코딩(Decoding)한다(46). 즉, 중앙 처리 장치(123)는 제1 에러 정정 코드(ECC_FM)에 근거하여 메인 영역 데이터의 에러를 정정한다. If an error is detected in the data in the main area, the
중앙 처리 장치(123)는 메인 영역의 데이터를 램(126)에 로딩한다(47). The
본 발명에 따른 플래시 메모리 시스템은 스페어 영역의 일부 데이터(즉, 에러 정정 코드)를 암호화함으로 플래시 메모리 시스템의 성능을 향상하고, 플래시 메모리 시스템의 암호화/복호화를 위한 하드웨어 및 소프트웨어의 오버헤드(Overhead)를 감소시킨다. The flash memory system according to the present invention improves the performance of the flash memory system by encrypting some data (i.e., error correction code) in the spare area, and overheads of hardware and software for encryption / .
또한, 본 발명에 따른 플래시 메모리 시스템은 파워-온 시에 비트 에러가 포함된 부트 코드와 암호화된 에러 정정 코드를 램에 로딩함으로 공격자로부터 부트 코드의 노출을 차단한다. 그리고, 본 발명에 따른 플래시 메모리 시스템을 포함하는 집적회로 카드의 보안 레벨을 높이는 효과가 있다. In addition, the flash memory system according to the present invention blocks boot code exposure from an attacker by loading a boot code including a bit error and an encrypted error correction code into a RAM at power-on. There is an effect of increasing the security level of the integrated circuit card including the flash memory system according to the present invention.
이상에서와 같이 도면과 명세서에서 최적 실시예가 개시되었다. 여기서 특정한 용어들이 사용되었으나, 이는 단지 본 발명을 설명하기 위한 목적에서 사용된 것이지 의미한정이나 특허청구범위에 기재된 본 발명의 범위를 제한하기 위하여 사용된 것은 아니다. 그러므로 본 기술 분야의 통상의 지식을 가진 자라면 이로부터 다양한 변형 및 균등한 타 실시예가 가능하다는 점을 이해할 것이다. 따라서, 본 발명의 진정한 기술적 보호 범위는 첨부된 특허청구범위의 기술적 사상에 의해 정해져야 할 것이다.As described above, an optimal embodiment has been disclosed in the drawings and specification. Although specific terms have been employed herein, they are used for purposes of illustration only and are not intended to limit the scope of the invention as defined in the claims or the claims. Therefore, those skilled in the art will appreciate that various modifications and equivalent embodiments are possible without departing from the scope of the present invention. Accordingly, the true scope of the present invention should be determined by the technical idea of the appended claims.
100; 플래시 메모리 시스템 110; 호스트
120; 메모리 컨트롤러 121; 호스트 인터페이스
122; 플래시 인터페이스 123; 중앙처리장치
124; ECC 회로 125; ROM
126; RAM 127; Enc/Dec 회로
130; 플래시 메모리 131; 어레이
132; 제어 유닛100;
120; A
122; A
124; An
126;
130;
132; The control unit
Claims (10)
상기 플래시 메모리를 제어하는 메모리 컨트롤러를 포함하고,
상기 메모리 컨트롤러는 상기 입력 데이터에 대한 제1 에러 정정 코드를 생성하고, 상기 제1 에러 정정 코드를 암호화하고, 상기 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드를 생성하고,
상기 플래시 메모리는 상기 입력 데이터를 저장하는 제1 영역 및 상기 암호화된 제1 에러 정정 코드 및 상기 제2 에러 정정 코드를 저장하는 제2 영역을 포함하는 플래시 메모리 시스템.A flash memory for storing input data; And
And a memory controller for controlling the flash memory,
The memory controller generates a first error correction code for the input data, encrypts the first error correction code, generates a second error correction code for the encrypted first error correction code,
The flash memory including a first area for storing the input data and a second area for storing the encrypted first error correction code and the second error correction code.
상기 메모리 컨트롤러는 상기 제1 에러 정정 코드를 암호화하고, 상기 암호화된 제1 에러 정정 코드를 복호화하는 암호화 및 복호화부; 그리고
상기 제1 에러 정정 코드와 상기 제2 에러 정정 코드를 생성하는 에러 정정 코드 생성부를 포함하는 플래시 메모리 시스템.The method according to claim 1,
The memory controller comprising: an encryption and decryption unit for encrypting the first error correction code and for decrypting the encrypted first error correction code; And
And an error correction code generator for generating the first error correction code and the second error correction code.
상기 메모리 컨트롤러는 외부로부터 전송된 키를 이용하여 상기 제1 에러 정정 코드를 암호화하는 플래시 메모리 시스템.The method according to claim 1,
Wherein the memory controller encrypts the first error correction code using a key transmitted from the outside.
상기 제2 영역은 상기 암호화된 제1 에러 정정 코드, 상기 제2 에러 정정 코드, 및 플래시 변환 레이어를 저장하는 플래시 메모리 시스템.The method according to claim 1,
And the second area stores the encrypted first error correction code, the second error correction code, and the flash conversion layer.
입력 데이터에 대한 제1 에러 정정 코드를 생성하는 단계;
상기 제1 에러 정정 코드를 암호화하는 단계;
상기 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드를 생성하는 단계; 및
상기 입력 데이터를 상기 제1 영역에 저장하고, 상기 암호화된 제1 에러 정정 코드 및 상기 제2 에러 정정 코드를 상기 제2 영역에 저장하는 단계;
상기 입력 데이터, 상기 암호화된 제1 에러 정정 코드, 및 제2 에러 정정 코드를 독출하는 단계;
상기 암호화된 제1 에러 정정 코드의 에러를 검출하는 단계;
상기 제1 에러 정정 코드의 에러가 검출된 경우, 상기 제2 에러 정정 코드를 디코딩하여 상기 암호화된 제1 에러 정정 코드의 에러를 정정하는 단계;
상기 암호화된 제1 에러 정정 코드를 복호화하는 단계;
상기 입력 데이터의 에러를 검출하는 단계; 및
상기 입력 데이터에 에러가 검출된 경우 상기 복호화된 제1 에러 정정 코드를 디코딩하여 상기 입력 데이터의 에러를 정정하는 단계를 포함하는 암호화 방법.A method of encrypting a flash memory system comprising a first area and a second area,
Generating a first error correction code for the input data;
Encrypting the first error correction code;
Generating a second error correction code for the encrypted first error correction code; And
Storing the input data in the first area, and storing the encrypted first error correction code and the second error correction code in the second area;
Reading the input data, the encrypted first error correction code, and the second error correction code;
Detecting an error of the encrypted first error correction code;
Correcting the error of the encrypted first error correction code by decoding the second error correction code if an error of the first error correction code is detected;
Decrypting the encrypted first error correction code;
Detecting an error of the input data; And
And decoding the decoded first error correction code to correct an error of the input data when an error is detected in the input data.
상기 플래시 메모리를 제어하는 메모리 컨트롤러를 포함하고,
상기 메모리 컨트롤러는
상기 입력 데이터에 대한 제1 에러 정정 코드를 생성하는 에러 정정 코드 생성부; 및
상기 제1 에러 정정 코드를 암호화하고, 상기 암호화된 제1 에러 정정 코드를 복호화하는 암호화 및 복호화부를 포함하고,
상기 플래시 메모리는 복수의 페이지들을 포함하고, 상기 복수의 페이지들 각각은 메인 영역 및 스페어 영역을 포함하고,
상기 메모리 컨트롤러는 상기 입력 데이터를 상기 메인 영역에 저장하고, 상기 암호화된 제1 에러 정정 코드를 상기 스페어 영역에 저장하는 플래시 메모리 시스템.A flash memory for storing input data; And
And a memory controller for controlling the flash memory,
The memory controller
An error correction code generator for generating a first error correction code for the input data; And
And an encryption and decryption unit for encrypting the first error correction code and for decrypting the encrypted first error correction code,
The flash memory including a plurality of pages, each of the plurality of pages including a main area and a spare area,
Wherein the memory controller stores the input data in the main area and stores the encrypted first error correction code in the spare area.
상기 메인 영역은 복수의 제1 워드들을 포함하고, 상기 스페어 영역은 복수의 제2 워드들을 포함하는 플래시 메모리 시스템.The method according to claim 6,
Wherein the main area comprises a plurality of first words, and the spare area comprises a plurality of second words.
상기 복수의 제2 워드들 중 일부에 상기 암호화된 제1 에러 정정 코드가 저장되는 플래시 메모리 시스템.8. The method of claim 7,
And the encrypted first error correction code is stored in a part of the plurality of second words.
상기 에러 정정 코드 생성부는 상기 암호화된 제1 에러 정정 코드에 대한 제2 에러 정정 코드를 생성하는 플래시 메모리 시스템.9. The method of claim 8,
Wherein the error correction code generator generates a second error correction code for the encrypted first error correction code.
상기 제2 에러 정정 코드는 상기 복수의 제2 워드들 중 하나에 저장되고, 상기 암호화된 제1 에러 정정 코드보다 크기가 작은 플래시 메모리 시스템.
10. The method of claim 9,
Wherein the second error correction code is stored in one of the plurality of second words and is smaller in size than the encrypted first error correction code.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020140062356A KR101593519B1 (en) | 2014-05-23 | 2014-05-23 | Flash memory system and encryption method thereof |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020140062356A KR101593519B1 (en) | 2014-05-23 | 2014-05-23 | Flash memory system and encryption method thereof |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020070079103A Division KR20090014828A (en) | 2007-08-07 | 2007-08-07 | Flash memory system encrypting error correction code and encryption method of flash memory system |
Publications (2)
Publication Number | Publication Date |
---|---|
KR20140072855A true KR20140072855A (en) | 2014-06-13 |
KR101593519B1 KR101593519B1 (en) | 2016-02-17 |
Family
ID=51126589
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020140062356A KR101593519B1 (en) | 2014-05-23 | 2014-05-23 | Flash memory system and encryption method thereof |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR101593519B1 (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2000041031A (en) * | 1998-04-02 | 2000-02-08 | Hewlett Packard Co <Hp> | Method and device for executing data enciphery and error code correction |
KR20060054538A (en) * | 2004-11-16 | 2006-05-22 | 삼성전자주식회사 | Data processing device and method for flash memory |
-
2014
- 2014-05-23 KR KR1020140062356A patent/KR101593519B1/en active IP Right Grant
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2000041031A (en) * | 1998-04-02 | 2000-02-08 | Hewlett Packard Co <Hp> | Method and device for executing data enciphery and error code correction |
KR20060054538A (en) * | 2004-11-16 | 2006-05-22 | 삼성전자주식회사 | Data processing device and method for flash memory |
Also Published As
Publication number | Publication date |
---|---|
KR101593519B1 (en) | 2016-02-17 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10048879B2 (en) | Nonvolatile memory recovery after power failure during write operations or erase operations | |
US8171378B2 (en) | Flash memory system having encrypted error correction code and encryption method for flash memory system | |
US8726140B2 (en) | Dummy data padding and error code correcting memory controller, data processing method thereof, and memory system including the same | |
US8341500B2 (en) | Detecting corrupted data for a system having non-volatile memory | |
US9229802B2 (en) | Non-systematic coded error correction | |
US11416417B2 (en) | Method and apparatus to generate zero content over garbage data when encryption parameters are changed | |
US11403174B2 (en) | Controller and memory system | |
US10983858B2 (en) | Data writing method, memory control circuit unit and memory storage device | |
US9003264B1 (en) | Systems, methods, and devices for multi-dimensional flash RAID data protection | |
JP2024073603A (en) | Flash translation layer with hierarchical security | |
US11567825B2 (en) | Generating error checking data for error detection during modification of data in a memory sub-system | |
CN108073799B (en) | Semiconductor memory system and method of operating the same | |
US20130080787A1 (en) | Memory storage apparatus, memory controller and password verification method | |
US20110219173A1 (en) | Semiconductor memory system | |
US20180349293A1 (en) | Controller and advanced method for deleting data | |
CN113348456A (en) | Memory device with cryptographic components | |
US20110219288A1 (en) | Method of operating nonvolatile memory device, method of operating controller, and method of operating memory system including the same | |
KR101593519B1 (en) | Flash memory system and encryption method thereof | |
JP2018194948A (en) | Semiconductor memory device, memory controller and method of monitoring memory | |
JP6054753B2 (en) | Semiconductor device and data access method | |
TW202403773A (en) | Semiconductor device, and system and method for managing secure operations in the same |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A107 | Divisional application of patent | ||
A201 | Request for examination | ||
E902 | Notification of reason for refusal | ||
E90F | Notification of reason for final refusal | ||
E902 | Notification of reason for refusal | ||
E701 | Decision to grant or registration of patent right | ||
GRNT | Written decision to grant | ||
FPAY | Annual fee payment |
Payment date: 20200131 Year of fee payment: 5 |