TPM-Protected Java Bytecode Encryption Against Reverse Engineering
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Conventional Java-based devices are vulnerable to unauthorized access and reverse engineering due to the ease with which Java bytecode can be read and decrypted from memory after the device is delivered or circulated.
Innovation Solution
The method involves encrypting machine code, such as Java bytecode, using a device-specific key provided by a Trusted Platform Module (TPM) module, storing it in the device's memory, and ensuring the key cannot be read after manipulation, thereby preventing unauthorized access by using a TPM module to block and irreversibly destroy the key in case of tampering.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Adaptability or versatility
If Java bytecode is stored in device memory for execution, then the device can run portable Java programs, but the bytecode can be easily read and decompiled by unauthorized third parties
Solution Approach 1:
The patent introduces a Trusted Platform Module (TPM) as an intermediary security component that generates and protects the device-specific key. The TPM securely stores the key and controls its availability, acting as a mediator between the encrypted bytecode and the decryption process. This intermediary prevents unauthorized access while allowing legitimate execution, resolving the contradiction between code accessibility and security.
Solution Approach 2:
The patent transforms the bytecode from a readable format to an encrypted format using device-specific keys. This parameter change in the code's state (from plaintext to ciphertext) prevents unauthorized reading and decompilation while maintaining the ability to execute the program through controlled decryption by the JVM, thus protecting portability while eliminating security vulnerabilities.
2Reliability
If the device-specific key is stored in the TPM module for decryption, then the machine code can be protected from unauthorized access, but the key becomes vulnerable to manipulation attacks
Solution Approach 1:
The patent implements preliminary anti-action by detecting manipulation attempts on the TPM module before an attacker can extract the device-specific key. The system proactively identifies tampering and takes preventive measures to invalidate or destroy the key, ensuring that even if the TPM is accessed, the key cannot be extracted. This preliminary protective action neutralizes the vulnerability to manipulation attacks while maintaining code protection.
3Object-affected harmful factors
If the machine code is encrypted using a device-specific key, then unauthorized access is prevented, but the code cannot be executed without decryption
Solution Approach 1:
The patent implements self-service by enabling the encrypted bytecode to automatically decrypt itself during the execution process using the device-specific key from the TPM module. The JVM's class loader handles the decryption transparently as part of the normal loading process, eliminating the need for separate manual decryption steps. This self-service mechanism maintains ease of operation while ensuring security, as the code protects itself through integrated decryption capabilities.
Data Source
AI summary
A method for the protection against access to a machine code of a device, has the steps: (a) encrypting a machine code by a device-specific key, which is provided by a TPM (Trusted Platform Module) module present in the device, (b) storing the encrypted machine code in a memory of the device, (c) wherein the device-specific key can no longer be read from the TPM module after a manipulation of the device.


