TEE Call Emulation for Secure Device Testing and Analysis

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

The challenge of effectively testing and analyzing the Trusted Execution Environment (TEE) of a Device Under Test (DUT) is hindered by hardware isolation, closed-source nature, lack of debug capabilities, and limited dynamic analysis options, making it difficult to assess security and identify vulnerabilities.

Innovation Solution

Emulating the TEE using a software emulator to intercept calls from the Rich Execution Environment (REE) and process them in an emulated TEE, allowing for dynamic analysis and response transmission, enabling inspection and modification of the emulated code.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If hardware isolation is implemented for TEE, then security and confidentiality are improved, but testing and analysis capability deteriorates

Engineering Contradiction:
ImprovesecurityVSAvoidtesting capability
Core Design Contradiction:
ReliabilityVSDifficulty of detecting and measuring

Solution Approach 1:

A hardware bridge is introduced as an intermediary component between the TEE and external testing apparatus. This bridge includes a test interface that can be selectively activated to allow external access to the TEE for testing purposes, while maintaining isolation during normal operation. The bridge acts as a controlled gateway that enables testing without compromising the security model.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The TEE's isolation state is made dynamic rather than static. The test interface of the hardware bridge can be activated or deactivated based on operational mode - disabled during normal secure operation to maintain isolation, and enabled during testing phases to allow analysis. This dynamic switching resolves the contradiction between maintaining constant isolation and enabling testing.

Inventive Principle:
Principle #15Dynamics

2Reliability

If closed-source TEE is used, then security is improved, but dynamic analysis capability deteriorates

Engineering Contradiction:
ImprovesecurityVSAvoiddynamic analysis
Core Design Contradiction:
ReliabilityVSEase of operation

Solution Approach 1:

The hardware bridge with its test interface serves as a mediator that enables dynamic analysis of closed-source TEE code. By providing a controlled interface through which test data can be input and responses observed, the bridge allows dynamic behavior analysis without requiring source code access or modifying the TEE's closed-source nature.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

Instead of attempting to analyze the original closed-source TEE directly, the system creates a copy or replica of the TEE environment through the hardware bridge interface. This allows testing and dynamic analysis on the replicated interface while the original TEE remains intact and secure, enabling analysis without compromising the closed-source constraint.

Inventive Principle:
Principle #26Copying

3Reliability

If hardware isolation is implemented, then confidentiality is improved, but debug capability deteriorates

Engineering Contradiction:
ImproveconfidentialityVSAvoiddebug capability
Core Design Contradiction:
ReliabilityVSEase of repair

Solution Approach 1:

The hardware bridge acts as a debugging intermediary that provides debug capabilities without breaking confidentiality. The test interface allows debugging operations such as setting breakpoints, inspecting state, and controlling execution flow while maintaining the confidential nature of the TEE through the isolated hardware path.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

Traditional software-based debugging mechanisms that would require breaking isolation are replaced with a dedicated hardware debugging interface. This hardware-based approach substitutes the need for software modifications or isolation breaches, providing debug capability through a physical interface that respects the confidentiality boundaries.

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

4Reliability

If TEE code is encrypted or obfuscated, then security is improved, but static analysis capability deteriorates

Engineering Contradiction:
ImprovesecurityVSAvoidstatic analysis
Core Design Contradiction:
ReliabilityVSDifficulty of detecting and measuring

Solution Approach 1:

The hardware bridge with its test interface serves as an intermediary that enables static analysis of encrypted or obfuscated TEE code. By allowing controlled input of test cases and observation of outputs through the bridge, analysts can perform static analysis on the interface behavior and infer properties about the obscured internal code without needing to decrypt or deobfuscate it.

Inventive Principle:
Principle #24Intermediary (Mediator)

Data Source

PatentUS12493685B2Method and apparatus for testing a device under test
Publication Date: 2025.12.09 SONY GROUP CORP
  • US12493685B2 patent drawing
  • US12493685B2 patent drawing

AI summary

A method for testing a Device Under Test (DUT) is provided. The method includes emulating a Trusted Execution Environment (TEE) of the DUT by means of a software emulator in order to provide an emulated TEE. The method further comprises intercepting at the DUT a call from a Rich Execution Environment (REE) of the DUT into the TEE of the DUT. In addition, the method includes transmitting the call to the emulated TEE such that the call is processed by the emulated TEE. The method includes transmitting a response of the emulated TEE to the REE. The response is based on the call.