Weakness · High
CWE-1313: Hardware Allows Activation of Test or Debug Logic at Runtime
What it is
During runtime, the hardware allows for test or debug logic (feature) to be activated, which allows for changing the state of the hardware. This feature can alter the intended behavior of the system and allow for alteration and leakage of sensitive data by an adversary.
- Severity (our rating)
- High
- Likelihood of exploit
- Not rated by MITRE
- Introduced during
- Architecture and Design, Implementation, Integration
- Exploited in the wild
- No CVE in CISA's catalog
In more detail
An adversary can take advantage of test or debug logic that is made accessible through the hardware during normal operation to modify the intended behavior of the system. For example, an accessible Test/debug mode may allow read/write access to any system data. Using error injection (a common test/debug feature) during a transmit/receive operation on a bus, data may be modified to produce an unintended message. Similarly, confidentiality could be compromised by such features allowing access to secrets.
What an attacker can do
- Modify Memory (Confidentiality, Integrity, Availability)
- Read Memory (Confidentiality, Integrity, Availability)
- DoS: Crash, Exit, or Restart (Confidentiality, Integrity, Availability)
- DoS: Instability (Confidentiality, Integrity, Availability)
- DoS: Resource Consumption (CPU) (Confidentiality, Integrity, Availability)
- DoS: Resource Consumption (Memory) (Confidentiality, Integrity, Availability)
- DoS: Resource Consumption (Other) (Confidentiality, Integrity, Availability)
- Execute Unauthorized Code or Commands (Confidentiality, Integrity, Availability)
- Gain Privileges or Assume Identity (Confidentiality, Integrity, Availability)
- Bypass Protection Mechanism (Confidentiality, Integrity, Availability)
- Alter Execution Logic (Confidentiality, Integrity, Availability)
- Quality Degradation (Confidentiality, Integrity, Availability)
- Unexpected State (Confidentiality, Integrity, Availability)
- Reduce Performance (Confidentiality, Integrity, Availability)
- Reduce Reliability (Confidentiality, Integrity, Availability)
How to prevent it
Architecture and Design
- Insert restrictions on when the hardware's test or debug features can be activated. For example, during normal operating modes, the hardware's privileged modes that allow access to such features cannot be activated. Configuring the hardware to only enter a test or debug mode within a window of opportunity such as during boot or configuration stage. The result is disablement of such test/debug features and associated modes during normal runtime operations.
Implementation
- Insert restrictions on when the hardware's test or debug features can be activated. For example, during normal operating modes, the hardware's privileged modes that allow access to such features cannot be activated. Configuring the hardware to only enter a test or debug mode within a window of opportunity such as during boot or configuration stage. The result is disablement of such test/debug features and associated modes during normal runtime operations.
Integration
- Insert restrictions on when the hardware's test or debug features can be activated. For example, during normal operating modes, the hardware's privileged modes that allow access to such features cannot be activated. Configuring the hardware to only enter a test or debug mode within a window of opportunity such as during boot or configuration stage. The result is disablement of such test/debug features and associated modes during normal runtime operations.
H2 Security
Found it in your code?
We review where it appears, fix it with your team, and check it was not already used against you.
Talk to our teamT Academy
Stop writing it in the first place
Learn to build software and systems without weaknesses like this one, with practice on real hosts in your browser, every objective checked on the machine.
Start freeSource: MITRE Common Weakness Enumeration, CWE version 4.19.1. CWE is a trademark of The MITRE Corporation.