# US 2021/0342457 A1 · Data processing method and device

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

- Number: US 2021/0342457 A1
- Document ID: US20210342457A1
- Status: Published application
- Kind: A1
- Application number: 17/374,766
- Filed: 2021-07-13
- Published: 2021-11-04
- Earliest claimed: 2019-04-18
- Assignees: Advanced New Technologies Co., Ltd.
- Applicants: Advanced New Technologies Co., Ltd.
- Inventors: Yuncheng WU; Wenxiang WANG; Le ZHANG; Li LIN
- Web page: https://patentgrep.com/patent/US20210342457A1

## CPC

- G06F 21/602: {Providing cryptographic facilities or services}
- G06F 21/606: {by securing the transmission between two devices or processes}
- G06N 20/00: Machine learning
- G06F 2221/2149: Restricted operating environment
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

A method, implementable by a data processing server comprising a trusted execution environment, includes: obtaining a ciphertext of target data from an external system; obtaining one or more parameters of a model for processing the target data; obtaining, via a data transmission channel between the trusted execution environment and the external system, an encryption key associated with the ciphertext of the target data; inputting the ciphertext of the target data and the one or more parameters of the model to the trusted execution environment; decrypting, in the trusted execution environment, the ciphertext using the encryption key to obtain the target data; processing, in the trusted execution environment, the obtained target data using the model with the one or more parameters to obtain a result; encrypting, in the trusted execution environment, the result using the encryption key; and sending the encrypted result to the external system.

## Claims

### Claim 1

A data processing method, implementable by a data processing server comprising a trusted execution environment, the method comprising:
obtaining data from an external system, wherein the data includes a first ciphertext of target data;
determining whether the data includes a second ciphertext for training a model for processing the target data;
in response to determining that the data includes the second ciphertext for training the model for processing the target data, determining whether the external system provides initialization parameter values for training the model;
in response to determining that the external system provides the initialization parameter values for training the model, training the model in the trusted execution environment with the initialization parameter values and the second ciphertext to obtain one or more parameters of the model for processing the first ciphertext;
obtaining, via a data transmission channel between the trusted execution environment and the external system, an encryption key associated with the first ciphertext;
inputting the first ciphertext and the one or more parameters of the model to the trusted execution environment;
decrypting, in the trusted execution environment, the first ciphertext using the encryption key to obtain the target data;
processing, in the trusted execution environment, the obtained target data using the model with the one or more parameters to obtain a result;
encrypting, in the trusted execution environment, the result using the encryption key; and
sending the encrypted result to the external system.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
in response to determining that the data does not include the second ciphertext for training the model for processing the target data, obtaining parameters of the model stored on the data processing server, for processing the first ciphertext.

### Claim 3 (depends on 1)

The method of claim 1, further comprising:
in response to determining that the external system does not provide the initialization parameter values for training the model, obtaining sample data from the second ciphertext, and determining the initialization parameter values based on the sample data in the trusted execution environment.

### Claim 4 (depends on 1)

The method of claim 1, wherein the one or more parameters of the model for processing the first ciphertext comprise at least one of a mean, vector, or covariance matrix of the model.

### Claim 5 (depends on 1)

The method of claim 1, wherein training the model in the trusted execution environment with the initialization parameter values and the second ciphertext to obtain one or more parameters of the model for processing the first ciphertext comprises:
training the model in the trusted execution environment via an iterative process.

### Claim 6 (depends on 1)

The method of claim 1, wherein training the model in the trusted execution environment with the initialization parameter values and the second ciphertext to obtain one or more parameters of the model for processing the first ciphertext comprises:
decrypting, in the trusted execution environment, the second ciphertext to obtain sample data for training the model; and
determining, in the trusted execution environment, the one or more parameters by training the model based on the sample data.

### Claim 7 (depends on 1)

The method of claim 1, further comprising:
obtaining from the external system the initialization parameter values for the one or more parameters of the model.

### Claim 8 (depends on 1)

The method of claim 1, wherein inputting the first ciphertext and the one or more parameters of the model to the trusted execution environment comprises:
inputting the first ciphertext and the one or more parameters of the model in a serialized form to the trusted execution environment by calling a Java Native Interface (JNI) function.

### Claim 9

A system for processing data, the system comprising one or more processors including a trusted execution environment and comprising one or more non-transitory computer-readable memories coupled to the one or more processors and configured with instructions executable by the one or more processors to cause the system to perform operations comprising:
obtaining data from an external system, wherein the data includes a first ciphertext of target data;
determining whether the data includes a second ciphertext for training a model for processing the target data;
in response to determining that the data includes the second ciphertext for training the model for processing the target data, determining whether the external system provides initialization parameter values for training the model;
in response to determining that the external system provides the initialization parameter values for training the model, training the model in the trusted execution environment with the initialization parameter values and the second ciphertext to obtain one or more parameters of the model for processing the first ciphertext;
obtaining, via a data transmission channel between the trusted execution environment and the external system, an encryption key associated with the ciphertext of the target data;
inputting the ciphertext of the target data and the one or more parameters of the model to the trusted execution environment;
decrypting, in the trusted execution environment, the ciphertext of the target data using the encryption key to obtain the target data;
processing, in the trusted execution environment, the obtained target data using the model with the one or more parameters to obtain a result;
encrypting, in the trusted execution environment, the result using the encryption key; and
sending the encrypted result to the external system.

### Claim 10 (depends on 9)

The system of claim 9, wherein the operations further comprise:
in response to determining that the data does not include the second ciphertext for training the model for processing the target data, obtaining parameters of the model stored on the data processing server, for processing the first ciphertext.

### Claim 11 (depends on 9)

The system of claim 9, wherein the operations further comprise:
in response to determining that the external system does not provide the initialization parameter values for training the model, obtaining sample data from the second ciphertext, and determining the initialization parameter values based on the sample data in the trusted execution environment.

### Claim 12 (depends on 9)

The system of claim 9, wherein the one or more parameters of the model for processing the first ciphertext comprise at least one of a mean, vector, or covariance matrix of the model.

### Claim 13 (depends on 9)

The system of claim 9, wherein training the model in the trusted execution environment with the initialization parameter values and the second ciphertext to obtain one or more parameters of the model for processing the first ciphertext comprises:
training the model in the trusted execution environment via an iterative process.

### Claim 14 (depends on 9)

The system of claim 9, wherein training the model in the trusted execution environment with the initialization parameter values and the second ciphertext to obtain one or more parameters of the model for processing the first ciphertext comprises:
decrypting, in the trusted execution environment, the second ciphertext to obtain sample data for training the model; and
determining, in the trusted execution environment, the one or more parameters by training the model based on the sample data.

### Claim 15 (depends on 9)

The system of claim 9, wherein the operations further comprise:
obtaining from the external system the initialization parameter values for the one or more parameters of the model.

### Claim 16 (depends on 9)

The system of claim 9, wherein inputting the ciphertext of the target data and the one or more parameters of the model to the trusted execution environment comprises:
inputting the ciphertext of the target data and the one or more parameters of the model in a serialized form to the trusted execution environment by calling a Java Native Interface (JNI) function.

### Claim 17

A non-transitory computer-readable storage medium configured with instructions executable by one or more processors comprising a trusted execution environment, to cause the one or more processors to perform operations comprising:
obtaining data from an external system, wherein the data includes a first ciphertext of target data;
determining whether the data includes a second ciphertext for training a model for processing the target data;
in response to determining that the data includes the second ciphertext for training the model for processing the target data, determining whether the external system provides initialization parameter values for training the model;
in response to determining that the external system provides the initialization parameter values for training the model, training the model in the trusted execution environment with the initialization parameter values and the second ciphertext to obtain one or more parameters of the model for processing the first ciphertext;
obtaining, via a data transmission channel between the trusted execution environment and the external system, an encryption key associated with the ciphertext of the target data;
inputting the ciphertext of the target data and the one or more parameters of the model to the trusted execution environment;
decrypting, in the trusted execution environment, the ciphertext of the target data using the encryption key to obtain the target data;
processing, in the trusted execution environment, the obtained target data using the model with the one or more parameters to obtain a result;
encrypting, in the trusted execution environment, the result using the encryption key; and
sending the encrypted result to the external system.

### Claim 18 (depends on 17)

The non-transitory computer-readable storage medium of claim 17, wherein the operations further comprise:
in response to determining that the data does not include the second ciphertext for training the model for processing the target data, obtaining parameters of the model stored on the data processing server, for processing the first ciphertext.

### Claim 19 (depends on 17)

The non-transitory computer-readable storage medium of claim 17, wherein the operations further comprise:
in response to determining that the external system does not provide the initialization parameter values for training the model, obtaining sample data from the second ciphertext, and determining the initialization parameter values based on the sample data in the trusted execution environment.

### Claim 20 (depends on 17)

The non-transitory computer-readable storage medium of claim 17, wherein the one or more parameters of the model for processing the first ciphertext comprise at least one of a mean, vector, or covariance matrix of the model.
