Safeguard
Application Security•

CWE-1242 Undocumented Features and Chicken Bits in Devices

Hidden switches meant for failure analysis can become attacker entry points. CWE-1242 explains chicken bits and how to keep them out of shipped devices.

Safeguard Security Team
3 min read

CWE-1242 is about devices that ship with chicken bits or other undocumented features. They were put there for engineers. An attacker who finds them has a way in that the security design never accounted for. It matters most for device makers, including ICS and OT equipment.

How it happens

A chicken bit is an undocumented bit that can switch off a functional security feature. Designers add them to isolate faulty components, turn off features that hurt performance, or get controllability for debug and test. Undocumented features serve the same purpose by another route.

The trouble starts when these controls reach the field.

MITRE's example describes a device with secure boot. The boot code lives in a separate SPI flash chip and contains special access features meant only for failure analysis and only for the designer to unlock. Attackers dump the code and reverse engineer it. They find the hidden features and activate them by sending specific commands over UART before secure boot finishes. From there they can read and write memory through UART, run arbitrary code and dump all memory.

What an attacker gains

The consequences in the MITRE record are broad. They include reading and modifying memory, executing unauthorized code or commands, gaining privileges or assuming identity, and bypassing protection mechanisms. Confidentiality, integrity and availability are all in scope. The common thread is that attackers exploit these interfaces for unauthorized access.

How to find it

No detection methods are listed in the record. Reasonable checks follow from the description:

  • Compare the documented interface list with what the firmware actually responds to.
  • Review boot and debug code paths for commands or registers that nothing in the specification explains.
  • Treat any control that disables a security feature as a finding until it is documented and gated.

How to fix it

MITRE's guidance for the design and implementation phases is direct. Implementing chicken bits in a released product is highly discouraged. If you have them at all, make sure they are disabled in production devices. Document all interfaces. MITRE rates this as high effectiveness.

The example adds two more steps. Remove chicken bits and hidden features that are exposed to attackers. For any feature the manufacturer does not want to expose, add authorization that relies on cryptographic primitives.

Quick check

What is a chicken bit?

An undocumented bit used to disable certain functional security features, typically to help isolate faulty components or support debug and test.

Is hiding a feature enough protection?

No. In MITRE's example, attackers dumped the boot code, reverse engineered it and found the hidden commands. Obscurity did not hold.

Sources

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.