# US 2022/0292174 A1 · Verifiability for execution in trusted execution environment

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

- Number: US 2022/0292174 A1
- Document ID: US20220292174A1
- Status: Published application
- Kind: A1
- Application number: 17/635,897
- Filed: 2019-08-19
- Published: 2022-09-15
- Earliest claimed: 2019-08-19
- Assignees: Nokia Technologies Oy
- Applicants: Nokia Technologies Oy
- Inventors: Zheng YAN; Wei SUN; Wenxiu DING
- Web page: https://patentgrep.com/patent/US20220292174A1

## CPC

- G06F 21/33: using certificates
- H04L 63/126: {the source of the received data}
- G06F 21/53: by executing in a restricted environment, e.g. sandbox or secure virtual machine
- H04L 63/123: {received data contents, e.g. message integrity}
- G06F 2221/031: Protect user input by software means
- H04L 67/10: in which an application is distributed across nodes in the network (software deployment G06F8/60; multiprogramming arrangements G06F9/46)
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)

## Abstract

Example embodiments of the present disclosure relate to verifiability for execution in a trusted execution environment (TEE). According to a method, a request for execution of a task is transmitted by a first apparatus and to a second apparatus, the task comprising a plurality of functions to be executed. A first validation key is generated from identification information of the plurality of functions based on an expected execution plan in at least one trusted execution environment of the second apparatus. An execution result for the task and a second validation key are received from the second apparatus. Correctness of the execution result is determined by comparing the first validation key with the second validation key. Through the solution, it is possible to provide the verifiability of the correctness of the execution result returned by the remote apparatus and achieves high performance on security, trust, and privacy.

## Claims

### Claim at position 1

1-32. (canceled)

### Claim 33

A first apparatus, comprising:
at least one processor; and
at least one memory including computer program code;
wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to:
transmit, to a second apparatus, a request for execution of a task, the task comprising a plurality of functions to be executed;
generate a first validation key from identification information of the plurality of functions based on an expected execution plan in at least one trusted execution environment of the second apparatus;
receive, from the second apparatus, an execution result for the task and a second validation key; and
determine correctness of the execution result by comparing the first validation key with the second validation key.

### Claim 34 (depends on 33)

The apparatus of claim 33, wherein the expected execution plan at least indicates an execution order of the plurality of functions, and wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to generate the first validation key by:
generating intermediate keys for the plurality of functions in the execution order, an intermediate key for a function being determined at least based on an intermediate key for a predecessor function of the function in the execution order; and
determining the first validation key based on the generated intermediate key for a last function of the plurality of functions.

### Claim 35 (depends on 34)

The apparatus of claim 34, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to generate the intermediate keys by: for a given function of the plurality of functions,
determining a first number of predecessor functions for the given function and a second number of successor functions for the given function in the execution order;
generating validation information for the given function based on the first number; and
generating the intermediate key for the given function based on the second number and the validation information.

### Claim 36 (depends on 35)

The apparatus of claim 35, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to generate the validation information by:
in response to the first number indicating one predecessor function, generating the validation information by concatenating the intermediate key for the one predecessor function and the identification information of the given function.

### Claim 37 (depends on 35)

The apparatus of claim 35, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to generate the validation information by:
in response to the first number indicating a plurality of predecessor functions, generating the validation information for the given function by:
combining the intermediate keys for the plurality of predecessor functions to obtain a combined intermediate key, and
concatenating the combined intermediate key and the identification information of the given function.

### Claim 38 (depends on 35)

The apparatus of claim 35, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to generate the validation information by:
in response to the first number indicating zero predecessor function, generating the validation information by concatenating a random number and the identification information of the given function, the random number being also used for generation of the second validation key.

### Claim 39 (depends on 38)

The apparatus of claim 38, wherein the at least one memory and the computer program code are configured to, with the at least one processor, further cause the first apparatus to:
generate the random number by applying a hash function to input data to be processed in the task.

### Claim 40 (depends on 35)

The apparatus of claim 35, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to generate the intermediate key based on the second number and the validation information by:
in response to the second number indicating zero successor function, generating the intermediate key for the given function by applying a hash function to the validation information.

### Claim 41 (depends on 35)

The apparatus of claim 35, wherein the expected execution plan further indicates distribution of the plurality of functions across the at least one trusted execution environment, and
wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to generate the intermediate key for the given function based on the second number and the validation information by:
in response to the second number indicating at least one successor function, determining, based on the expected execution plan, whether the at least one successor function is executed in a different trusted execution environment than that of the given function;
in response to determining that the at least one successor function is executed in a different trusted execution environment than that of the given function, generating the intermediate key for the given function by applying a hash function to the validation information; and
in response to determining that the at least one successor function is executed in a same trusted execution environment as that of the given function, determining the validation information as the intermediate key for the given function.

### Claim 42 (depends on 33)

The apparatus of claim 33, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the first apparatus to determine the correctness of the execution result by:
in response to the second validation key being the same as the first validation key, determining that the execution result is correct; and
in response to the second validation key being different from the first validation key, determining that the execution result is incorrect.

### Claim 43

A second apparatus, comprising:
at least one processor; and
at least one memory including computer program code;
wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to:
receive, from a first apparatus, a request for execution of a task, the task comprising a plurality of functions to be executed;
execute, based on an execution plan, the plurality of functions in at least one trusted execution environment to obtain an execution result for the task;
generate a second validation key from identification information of the plurality of functions based on the execution plan; and
transmit, to the first apparatus, the execution result and the second validation key for validating correctness of the execution result.

### Claim 44 (depends on 43)

The apparatus of claim 43, wherein the execution plan at least indicates an execution order of the plurality of functions, and wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the second validation key by:
generating intermediate keys for the plurality of functions in the execution order, an intermediate key for a function being determined at least based on an intermediate key for a predecessor function of the function in the execution order; and
determining the second validation key based on the generated intermediate key for a last function of the plurality of functions.

### Claim 45 (depends on 44)

The apparatus of claim 44, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the intermediate keys for the plurality of functions by:
generating the intermediate keys for the plurality of functions within the at least one trusted execution environment.

### Claim 46 (depends on 44)

The apparatus of claim 44, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the intermediate keys by: for a given function of the plurality of functions,
determining a first number of predecessor functions for the given function and a second number of successor functions for the given function in the execution order;
generating validation information for the given function based on the first number of predecessor functions; and
generating the intermediate key for the given function based on the second number and the validation information.

### Claim 47 (depends on 46)

The apparatus of claim 46, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the validation information by:
in response to the first number indicating zero predecessor function, generating the validation information by concatenating a random number and the identification information of the given function, the random number being also used by the first apparatus for generation of a first validation key.

### Claim 48 (depends on 47)

The apparatus of claim 47, wherein the random number is generated by applying a hash function to input data to be processed in the task.

### Claim 49 (depends on 47)

The apparatus of claim 47, wherein the expected execution plan further indicates distribution of the plurality of functions across the at least one trusted execution environment, and
wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the validation information by:
in response to the first number indicating at least one predecessor function for the given function, determining, based on the execution plan, whether the at least one predecessor function and the given function are executed in a same trusted execution environment as that of the given function; and
generating the validation information based on the first number and a result of the determining.

### Claim 50 (depends on 49)

The apparatus of claim 49, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the validation information based on the first number and the result of the determining by:
in response to the first number indicating one predecessor function and in response to determining that the predecessor function and the given function are executed in the same trusted execution environment, generating the validation information by concatenating the intermediate key for the predecessor function and the identification information of the given function; and
in response to the first number indicating one predecessor function and in response to determining that the predecessor function and the given function are executed in different trusted execution environments, determining the validation information by:
applying a hash function to a result of execution of the predecessor function that is obtained in the trusted execution environment where the given function is executed, to obtain a hashed result,
converting the intermediate key for the predecessor function based on the hashed result, and
concatenating the converted intermediate key and the identification information of the given function.

### Claim 51 (depends on 49)

The apparatus of claim 49, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the validation information based on the first number and the result of the determining by:
in response to the first number indicating a plurality of predecessor functions and in response to determining that the plurality of predecessor functions are executed in a same trusted execution environment as that of the given function, generating the validation information by the following:
combining the intermediate keys for the plurality of predecessor functions to obtain a combined intermediate key, and
concatenating the combined intermediate key and the identification information of the given function.

### Claim 52 (depends on 49)

The apparatus of claim 49, wherein the at least one memory and the computer program code are configured to, with the at least one processor, cause the second apparatus to generate the validation information based on the first number and the result of the determining by:
in response to the first number indicating a plurality of predecessor functions and in response to determining that the plurality of predecessor functions are executed in a different trusted execution environment than that of the given function, generating the validation information by:
for a given predecessor function of the plurality of predecessor functions, applying a hash function to a result of execution of the predecessor function that is obtained in the trusted execution environment where the given function is executed, to obtain a hashed result,
converting the intermediate key for the given predecessor function based on the hashed result, and
combining the converted intermediate keys for the plurality of predecessor functions to obtain a combined intermediate key, and
concatenating the combined intermediate key and the identification information of the given function.
