# US 2022/0045850 A1 · Memory system encrypting data

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2022/0045850 A1
- Document ID: US20220045850A1
- Status: Published application
- Kind: A1
- Application number: 17/190,027
- Filed: 2021-03-02
- Published: 2022-02-10
- Earliest claimed: 2020-08-07
- Assignees: Kioxia Corporation
- Applicants: Kioxia Corporation
- Inventors: Taichi EJIRI
- Web page: https://patentgrep.com/patent/US20220045850A1

## CPC

- H04L 9/0822: {using key encryption key}
- G06F 13/1668: {Details of memory controller}
- H04L 9/0643: {Hash functions, e.g. MD5, SHA, HMAC or f9 MAC}
- H04L 9/0825: {using asymmetric-key encryption or public key infrastructure [PKI], e.g. key signature or public key certificates}
- H04L 9/0894: {Escrow, recovery or storing of secret information, e.g. secret key escrow or cryptographic key storage}
- H04L 9/14: using a plurality of keys or algorithms
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A memory system includes a nonvolatile memory and a controller. In a case where first encrypted data obtained by encrypting first data with a first DEK is stored in the nonvolatile memory, in response to determining that second data received based on a first write request from a host is the same as the first data and a first user uses the host, the controller encrypts the first DEK with a first KEK associated with the first user to acquire a first encrypted DEK, and stores the first encrypted DEK.

## Claims

### Claim 1

A memory system comprising:
a first nonvolatile memory; and
a controller operatively coupled to the first nonvolatile memory, wherein
the controller is configured to:
in response to determining that second data received based on a first write request from a host is the same as first data and a first user uses the host, the first data being encrypted using a first data encryption key (DEK) as first encrypted data and stored in the first nonvolatile memory, encrypt the first DEK using a first key encryption key (KEK) associated with the first user to acquire a first encrypted DEK, and store the first encrypted DEK;
in response to determining that the second data is the same as the first data and a second user different from the first user uses the host, encrypt the first DEK using a second KEK associated with the second user to acquire a second encrypted DEK, and store the second encrypted DEK;
in response to determining that the second data is different from the first data and the first user uses the host, use the second data to generate a second DEK, encrypt the second data using the second DEK to acquire second encrypted data, write the second encrypted data into the first nonvolatile memory, encrypt the second DEK using the first KEK to acquire a third encrypted DEK, and store the third encrypted DEK; and
in response to determining that the second data is different from the first data and the second user uses the host, use the second data to generate the second DEK, encrypt the second data with the second DEK to acquire the second encrypted data, write the second encrypted data into the first nonvolatile memory, encrypt the second DEK using the second KEK to acquire a fourth encrypted DEK, and store the fourth encrypted DEK.

### Claim 2 (depends on 1)

The memory system according to claim 1, wherein
the controller is further configured to:
in response to receiving a read request from the host for reading the second data and determining that the first user uses the host, read the first encrypted data from the first nonvolatile memory, decrypt the first encrypted DEK using the first KEK to acquire the first DEK, and decrypt the read first encrypted data using the first DEK; and
in response to receiving a read request from the host for reading the second data and determining that the second user uses the host, read the first encrypted data from the first nonvolatile memory, decrypt the second encrypted DEK using the second KEK to acquire the first DEK, and decrypt the read first encrypted data using the first DEK.

### Claim 3 (depends on 1)

The memory system according to claim 1, wherein
the controller is further configured to:
in response to receiving a read request from the host for reading the second data and determining that the first user uses the host, read the second encrypted data from the first nonvolatile memory, decrypt the third encrypted DEK using the first KEK to acquire the second DEK, and decrypt the read second encrypted data using the second DEK; and
in response to receiving a read request from the host for reading the second data and determining that the second user uses the host, read the second encrypted data from the first nonvolatile memory, decrypt the fourth encrypted DEK using the second KEK to acquire the second DEK, and decrypt the read second encrypted data using the second DEK.

### Claim 4 (depends on 1)

The memory system according to claim 1, wherein
when the second data is the same as the first data, the first DEK is a hash value of the second data or a hash-based message authentication code (HMAC) value of the second data, and
when the second data is different from the first data, the first DEK is a hash value of the first data or an HMAC value of the first data, and the second DEK is a hash value of the second data or an HMAC value of the second data.

### Claim 5 (depends on 1)

The memory system according to claim 1, wherein
the controller is further configured to:
generate the first KEK by using a first password associated with the first user; and
generate the second KEK by using a second password associated with the second user.

### Claim 6 (depends on 1)

The memory system according to claim 1, wherein
the controller is further configured to:
generate the first DEK by using the first data received based on a second write request from the host used by the second user before the second data is received;
encrypt the first data with the first DEK to acquire the first encrypted data, write the first encrypted data into the first nonvolatile memory;
encrypt the first DEK using the second KEK to acquire the second encrypted DEK, and store the second encrypted DEK.

### Claim 7 (depends on 6)

The memory system according to claim 6, wherein
the controller is further configured to:
in response to receiving a read request from the host for reading the first data and determining that the second user uses the host,
read the first encrypted data from the first nonvolatile memory, decrypt the second encrypted DEK using the second KEK to acquire the first DEK, and decrypt the read first encrypted data using the first DEK.

### Claim 8 (depends on 1)

The memory system according to claim 1, wherein
the controller is configured to generate the first DEK by using the second data when the second data is the same as the first data.

### Claim 9 (depends on 1)

The memory system according to claim 1, further comprising:
a second nonvolatile memory that stores a key derivation key (KDK), wherein
the controller is further configured to:
in response to determining that the second data is the same as the first data, use the second data and the KDK to generate the first DEK; and
in response to determining that the second data is different from the first data, use the second data and the KDK to generate the second DEK.

### Claim 10 (depends on 1)

The memory system according to claim 1, wherein
the controller is further configured to:
in response to determining that the first user uses the host, use third data to generate a third DEK, encrypt the third data using the third DEK to acquire third encrypted data, write the third encrypted data into the first nonvolatile memory, encrypt the third DEK using the first KEK to acquire a fifth encrypted DEK, and store the fifth encrypted DEK, and
in response to determining that the second user uses the host, use fourth data to generate a fourth DEK, encrypt the fourth data using the fourth DEK to acquire fourth encrypted data, write the fourth encrypted data into the first nonvolatile memory, encrypt the fourth DEK using the second KEK to acquire a sixth encrypted DEK, and store the sixth encrypted DEK.

### Claim 11

A memory system comprising:
a first nonvolatile memory; and
a controller operatively coupled to the first nonvolatile memory and being configured to:
generate different data encryption keys (DEKs) for different data patterns and generate the same DEK for the same data pattern; and
encrypt data having a data pattern using the generated DEK and store the encrypted data into the first nonvolatile memory.

### Claim 12 (depends on 11)

The memory system according to claim 11, wherein
the controller is configured to:
generate a hash value of data;
generate a DEK based on the hash value of the data; and
encrypt the data using the generated DEK.

### Claim 13 (depends on 11)

The memory system according to claim 11, wherein
the controller is configured to:
generate a first DEK based on first data having a first data pattern;
generate a second DEK based on second data having a second data pattern, the second DEK being different from the first DEK, the second data pattern being different from the first data pattern;
encrypt the first data using the first DEK, and store the encrypted first data into the first nonvolatile memory; and
encrypt the second data using the second DEK, and store the encrypted second data into the first nonvolatile memory.

### Claim 14 (depends on 13)

The memory system according to claim 13, wherein
the controller is further configured to:
manage a logical-to-physical address conversion table such that a first logical address of the first data is mapped to a first physical address of the first nonvolatile memory in which the encrypted first data is stored.

### Claim 15 (depends on 14)

The memory system according to claim 14, wherein
the controller is further configured to:
in response to determining that third data received from a host has the first data pattern,
without storing the third data into the first nonvolatile memory, update the logical-to-physical address conversion table such that a second logical address of the third data is mapped to the first physical address.

### Claim 16 (depends on 15)

The memory system according to claim 15, wherein
the controller is further configured to:
manage a hash value of the first data; and
determine that the third data has the first data pattern by comparing a hash value of the received third data and the managed hash value of the first data.

### Claim 17 (depends on 15)

The memory system according to claim 15, wherein
the controller is further configured to:
generate different key encryption keys (KEKs) for different passwords and generate the same KEK for the same password; and
encrypt a DEK using the generated KEK and store the encrypted DEK into the first nonvolatile memory.

### Claim 18 (depends on 17)

The memory system according to claim 17, wherein
the controller is configured to:
generate a first KEK using a first password;
encrypt the first DEK using the first KEK to generate a first encrypted DEK, and store the first encrypted DEK into the first nonvolatile memory;
generate a second KEK using a second password, the second KEK being different from the first KEK, the second password being different from the first password;
encrypt the first DEK using the second KEK to generate a second encrypted DEK, and store the second encrypted DEK into the first nonvolatile memory.

### Claim 19 (depends on 18)

The memory system according to claim 18, wherein
the controller is further configured to:
in response to receiving, from the host, a first read command designating the first logical address,
generate the first KEK using the first password;
read the first encrypted DEK from the first nonvolatile memory;
decrypt the first encrypted DEK using the first KEK to restore the first DEK;
read the first encrypted data from the first physical address of the first nonvolatile memory;
decrypt the first encrypted data using the first DEK to restore the first data; and
transmit the restored first data to the host.

### Claim 20 (depends on 18)

The memory system according to claim 18, wherein
the controller is further configured to:
in response to receiving, from the host, a second read command designating the second logical address,
generate the first KEK using the first password;
read the first encrypted DEK from the first nonvolatile memory;
decrypt the first encrypted DEK using the first KEK to restore the first DEK;
read the first encrypted data from the first physical address of the first nonvolatile memory;
decrypt the first encrypted data using the first DEK to restore the first data; and
transmit the restored first data to the host.
