CWE-1299 Base Brouillon

Missing Protection Mechanism for Alternate Hardware Interface

This vulnerability occurs when a hardware component's security controls only protect the primary access path, leaving alternate interfaces unprotected. Attackers can bypass intended restrictions by…

Définition

What is CWE-1299?

This vulnerability occurs when a hardware component's security controls only protect the primary access path, leaving alternate interfaces unprotected. Attackers can bypass intended restrictions by accessing sensitive assets through these unguarded backdoors, such as shadow registers or other external-facing ports.
Modern chips and Systems-on-Chip (SoCs) often contain multiple access paths to critical internal registers—through interfaces like PCIe, USB, UART, or SMBus. If access controls are only enforced on one primary interface (e.g., PCIe), an attacker can simply route malicious transactions through an alternate, unprotected interface (like UART or USB) to modify or read protected registers, completely bypassing the intended security layer. Another common bypass involves shadow or mirror registers, which are duplicate registers that temporarily hold data before syncing with a main register. These are often implemented for performance or debugging purposes. If these shadow registers lack the same access protections as their primary counterparts, attackers can directly target them to alter system state, compromise security configurations, or leak sensitive information, effectively undermining the chip's entire protection scheme.
Impact réel

Real-world CVEs caused by CWE-1299

  • Missing protection mechanism on serial connection allows for arbitrary OS command execution.

  • Mini-PCI Express slot does not restrict direct memory access.

  • When the internal flash is protected by blocking access on the Data Bus (DBUS), it can still be indirectly accessed through the Instruction Bus (IBUS).

  • When GPIO is protected by blocking access to corresponding GPIO resource registers, protection can be bypassed by writing to the corresponding banked GPIO registers instead.

  • monitor device allows access to physical UART debug port without authentication

Comment les attaquants l'exploitent

Parcours de l'attaquant étape par étape

  1. 1

    Identifier un chemin de code qui traite des entrées non fiables sans validation.

  2. 2

    Élaborer une charge utile qui exploite le comportement non sécurisé — injection, traversal, débordement ou abus de logique.

  3. 3

    Délivrer la charge utile via une requête normale et observer la réaction de l'application.

  4. 4

    Itérer jusqu'à ce que la réponse divulgue des données, exécute le code de l'attaquant ou élève les privilèges.

Exemple de code vulnérable

Vulnerable Verilog

Vulnérable Verilog
assign addr_auth = (address == 32'hF00) ? 1: 0;
Exemple de code sécurisé

Secure Verilog

The bugged line of code is repeated in the Bad example above. The weakness arises from the fact that the SECURE_ME register can be modified by writing to the shadow register COPY_OF_SECURE_ME. The address of COPY_OF_SECURE_ME should also be included in the check. That buggy line of code should instead be replaced as shown in the Good Code Snippet below.

Sécurisé Verilog
assign addr_auth = (address == 32'hF00 || address == 32'h800F00) ? 1: 0;
What changed: the unsafe sink is replaced (or the input is validated/escaped) so the same payload no longer triggers the weakness.
Liste de contrôle de prévention

How to prevent CWE-1299

  • Requirements Protect assets from accesses against all potential interfaces and alternate paths.
  • Architecture and Design Protect assets from accesses against all potential interfaces and alternate paths.
  • Implementation Protect assets from accesses against all potential interfaces and alternate paths.
Signaux de détection

How to detect CWE-1299

SAST High

Exécuter une analyse statique (SAST) sur le code source à la recherche du motif non sécurisé dans le flux de données.

DAST Moderate

Exécuter des tests de sécurité applicative dynamique (DAST) contre le point de terminaison en ligne.

Runtime Moderate

Surveiller les journaux runtime pour détecter des traces d'exception inhabituelles, des entrées malformées ou des tentatives de contournement d'autorisation.

Code review Moderate

Revue de code : signaler tout nouveau code qui traite les entrées de cette surface sans utiliser les helpers du framework validés.

Correction automatique Plexicus

Plexicus détecte automatiquement CWE-1299 et ouvre une PR de correction en moins de 60 secondes.

Codex Remedium analyse chaque commit, identifie cette faiblesse précise et livre une pull request prête à être relue avec le correctif. Pas de tickets. Pas de transferts.

Questions fréquentes

Frequently asked questions

Qu'est-ce que CWE-1299 ?

This vulnerability occurs when a hardware component's security controls only protect the primary access path, leaving alternate interfaces unprotected. Attackers can bypass intended restrictions by accessing sensitive assets through these unguarded backdoors, such as shadow registers or other external-facing ports.

Quelle est la gravité de CWE-1299 ?

MITRE n'a pas publié de note de probabilité d'exploitation pour cette faiblesse. Traitez-la comme un impact moyen jusqu'à ce que votre modèle de menace prouve le contraire.

Quels langages ou plateformes sont affectés par CWE-1299 ?

MITRE lists the following affected platforms: Not OS-Specific, Not Architecture-Specific, Microcontroller Hardware, Processor Hardware, Bus/Interface Hardware, Not Technology-Specific.

Comment puis-je prévenir CWE-1299 ?

Protect assets from accesses against all potential interfaces and alternate paths. Protect assets from accesses against all potential interfaces and alternate paths.

Comment Plexicus détecte et corrige CWE-1299 ?

Le moteur SAST de Plexicus reconnaît la signature de flux de données de CWE-1299 à chaque commit. Lorsqu'une correspondance est trouvée, notre agent Codex Remedium ouvre une PR de correction avec le code corrigé, les tests et un résumé d'une ligne pour le relecteur.

Où puis-je en savoir plus sur CWE-1299 ?

MITRE publie la définition canonique à https://cwe.mitre.org/data/definitions/1299.html. Vous pouvez également consulter la documentation OWASP et NIST pour des conseils adjacents.

Prêt quand vous l'êtes

Arrêtez de payer par développeur.
Commencez à fermer la boucle.

Plexicus est l'ASPM natif IA qui scanne, filtre, corrige, penteste et explique — de façon autonome. Développeurs illimités, dépôts illimités, actions IA à usage équitable. Vrai niveau gratuit, €269/mo annuel quand vous êtes prêt.