Trusted Execution Environment
A Trusted Execution Environment (TEE) is a secure area in a processor that protects sensitive crypto operations and private keys from external access.
What Is a Trusted Execution Environment?
A trusted execution environment (TEE) is an isolated area of a device's main processor in which code and data are protected from the rest of the system, including the operating system. ARM TrustZone, found in most smartphone chips, and Intel SGX are well-known implementations.
The processor switches between a normal world and a secure world. An app asks the secure side to perform an operation, such as signing with a stored key, and receives only the result. Phones use this for fingerprint data, payment credentials and hardware-backed key storage.
A TEE is not a separate chip. It shares the processor and memory with ordinary software and gives little protection against physical attack, and researchers have repeatedly extracted secrets from TEEs through side channels and implementation bugs. A secure element is a dedicated chip built to resist physical tampering, and it is what most hardware wallets use to protect keys.
For self-custody, a TEE matters mainly on the phone: wallet apps and the companion apps of hardware wallets use it to protect locally stored secrets. It raises the bar against malware, but the phone remains a general-purpose, internet-connected device, whereas a hardware wallet keeps the keys on a separate device with its own screen.
Real-World Examples
Example 1: A mobile app keeps an encryption key in the phone's hardware-backed keystore. Malware in another app cannot read the key, but an attacker who takes over the unlocked app itself can still ask the keystore to use it.
Example 2: A buyer sees “secure element” on a hardware wallet's spec sheet and “TEE” on a phone's. The first is a separate tamper-resistant chip; the second is a protected mode of the main processor.
Frequently Asked Questions
How is a TEE different from the secure element in a hardware wallet?
A TEE is a protected mode of the device's main processor and shares the processor and memory with ordinary software. A secure element is a separate chip built to resist physical tampering, and it is what most hardware wallets use to protect keys. A TEE gives little protection against physical attack, which is the main difference.
Does a phone's TEE make a mobile wallet app as safe as a hardware wallet?
No. A TEE raises the bar against malware by keeping locally stored secrets away from other apps, but the phone remains a general-purpose, internet-connected device. A hardware wallet keeps the keys on a separate device with its own screen. Researchers have also extracted secrets from TEEs through side channels and implementation bugs.
Can malware use a key that is stored in a phone's TEE?
Malware in another app cannot read a key held in the hardware-backed keystore, because apps receive only the result of an operation, never the key. But an attacker who takes over the unlocked app that owns the key can still ask the keystore to use it, for example to sign or decrypt something.
Sources
Ready to Choose a Secure Wallet?
Use our tools to find the right hardware wallet for your needs.