CWE-1330 Variante Rascunho

Remanent Data Readable after Memory Erase

Sensitive data stored in memory hardware can still be accessed or reconstructed even after a standard clear or erase command has been executed.

Definição

What is CWE-1330?

Sensitive data stored in memory hardware can still be accessed or reconstructed even after a standard clear or erase command has been executed.
Data remanence happens when memory hardware doesn't completely eliminate stored information during a standard erase operation. This can occur due to performance-focused designs that only clear organizational metadata (like file pointers) while leaving the actual data intact, or due to the physical properties of memory types like SRAM and DRAM, where residual electrical charge can retain data. To counter this, memory devices often provide separate 'secure erase' commands designed to overwrite the actual data cells. For robust protection, especially in self-encrypting storage devices, a 'cryptographic erase' is used. This method doesn't overwrite the encrypted data on the physical media; instead, it permanently deletes the decryption keys. Since the remaining data is still encrypted, protection relies entirely on the strength of the encryption algorithm. Therefore, understanding your hardware's specific erase capabilities is critical for ensuring data is truly irrecoverable.
Impacto no mundo real

Real-world CVEs caused by CWE-1330

  • Firmware Data Deletion Vulnerability in which a base station factory reset might not delete all user information. The impact of this enables a new owner of a used device that has been "factory-default reset" with a vulnerable firmware version can still retrieve, at least, the previous owner's wireless network name, and the previous owner's wireless security (such as WPA2) key. This issue was addressed with improved, data deletion.

Como os atacantes a exploram

Trajeto do atacante passo a passo

  1. 1

    Consider a device that uses flash memory for non-volatile-data storage. To optimize flash-access performance or reliable-flash lifetime, the device might limit the number of flash writes/erases by maintaining some state in internal SRAM and only committing changes to flash memory periodically.

  2. 2

    The device also supports user reset to factory defaults with the expectation that all personal information is erased from the device after this operation. On factory reset, user files are erased using explicit, erase commands supported by the flash device.

  3. 3

    In the given, system design, the flash-file system can support performance-optimized erase such that only the file metadata are erased and not the content. If this optimized erase is used for files containing user data during factory-reset flow, then device, flash memory can contain remanent data from these files.

  4. 4

    On device-factory reset, the implementation might not erase these copies, since the file organization has changed and the flash file system does not have the metadata to track all previous copies.

  5. 5

    A flash-memory region that is used by a flash-file system should be fully erased as part of the factory-reset flow. This should include secure-erase flow for the flash media such as overwriting patterns multiple times followed by erase.

Exemplo de código vulnerável

Vulnerable pseudo

A MITRE não publicou um exemplo de código para este CWE. O padrão abaixo é ilustrativo — consulte os Recursos para referências canónicas.

Vulnerável pseudo
// Example pattern — see MITRE for the canonical references.
function handleRequest(input) {
  // Untrusted input flows directly into the sensitive sink.
  return executeUnsafe(input);
}
Exemplo de código seguro

Secure pseudo

Seguro pseudo
// Validate, sanitize, or use a safe API before reaching the sink.
function handleRequest(input) {
  const safe = validateAndEscape(input);
  return executeWithGuards(safe);
}
What changed: the unsafe sink is replaced (or the input is validated/escaped) so the same payload no longer triggers the weakness.
Lista de verificação de prevenção

How to prevent CWE-1330

  • Architecture and Design - Support for secure-erase commands that apply multiple cycles of overwriting memory with known patterns and of erasing actual content. - Support for cryptographic erase in self-encrypting, memory devices. - External, physical tools to erase memory such as ultraviolet-rays-based erase of Electrically erasable, programmable, read-only memory (EEPROM). - Physical destruction of media device. This is done for repurposed or scrapped devices that are no longer in use.
Sinais de deteção

How to detect CWE-1330

Architecture or Design Review

- Testing of memory-device contents after clearing or erase commands. - Dynamic analysis of memory contents during device operation to detect specific, confidential assets. - Architecture and design analysis of memory clear and erase operations.

Dynamic Analysis with Manual Results Interpretation

- Testing of memory-device contents after clearing or erase commands. - Dynamic analysis of memory contents during device operation to detect specific, confidential assets. - Architecture and design analysis of memory clear and erase operations.

CWE-1330

Don't catalog this weakness. Prove it's reachable.

Plexicus turns CWE catalogs into evidence: every CWE-pattern is matched against your real code graph, reach is proven on a sandbox clone, and verified findings ship as reviewed PRs.

Perguntas frequentes

Frequently asked questions

O que é o CWE-1330?

Sensitive data stored in memory hardware can still be accessed or reconstructed even after a standard clear or erase command has been executed.

Qual a gravidade do CWE-1330?

A MITRE não publicou uma classificação de probabilidade de exploração para esta fraqueza. Trate-a como impacto médio até o seu modelo de ameaças provar o contrário.

Que linguagens ou plataformas são afetadas pelo CWE-1330?

MITRE lists the following affected platforms: Not OS-Specific, Not Architecture-Specific, Security Hardware, Not Technology-Specific.

Como posso prevenir o CWE-1330?

- Support for secure-erase commands that apply multiple cycles of overwriting memory with known patterns and of erasing actual content. - Support for cryptographic erase in self-encrypting, memory devices. - External, physical tools to erase memory such as ultraviolet-rays-based erase of Electrically erasable, programmable, read-only memory (EEPROM). - Physical destruction of media device. This is done for repurposed or scrapped devices that are no longer in use.

Como é que o Plexicus deteta e corrige o CWE-1330?

O motor SAST do Plexicus correlaciona a assinatura de fluxo de dados do CWE-1330 em cada commit. Quando é encontrada uma correspondência, o nosso agente Codex Remedium abre um PR de correção com o código corrigido, testes e um resumo de uma linha para o revisor.

Onde posso saber mais sobre o CWE-1330?

A MITRE publica a definição canónica em https://cwe.mitre.org/data/definitions/1330.html. Pode também consultar a documentação da OWASP e do NIST para orientações adjacentes.

Pronto para validar o que importa?

Pronto para validar o que importa.

O Plexicus é Proof-Driven AppSec: achados validados, compreensão contextual e remediação revisada — ancorada em evidência, escopada com você.

Qualificação

Verifique se o AI Swarm Pentest se adequa ao seu ambiente.

Partilhe o contexto mínimo. Vamos rever o escopo e indicar o próximo passo comercial.

Antes de enviar — verifique se se encaixa

0 / 280

Sem compromisso. Se não se encaixa, dizemos.

SAMPLE HANDOVER · ILLUSTRATIVE

Sample evidence handover

A trimmed view of what your team receives at the end of an AI Swarm Pentest engagement. Real engagements include full technical evidence, executive narrative, and a remediation plan.

VALIDATED FINDING Evidence attached

Server-Side Request Forgery in webhooks/receiver

demo-project/sample-app · src/webhooks/receiver.py:42

SeverityHigh CVSS 3.18.6 Priority79 Confirmedvia replay

Untrusted caller-supplied URLs reach an internal egress without an allowlist. Replayed in a sandbox against a fresh authorized target — the same control was validated to fail twice.

REVIEWER-READY REMEDIATION Merge-ready PR

Validate the target URL against an allowlist of permitted hostnames. Reject private/internal IP ranges. Enforce HTTPS only.

plexicus/remediation/webhooks-ssrf 3 changed · 0 new files
42resp = requests.get(target_url)
42+if not is_allowed_host(target_url):
43+  raise WebhookRejected(target_url)
44+resp = requests.get(target_url, timeout=5)
Every engagement hands over:
  • Executive briefing
  • Validated findings list
  • Merge-ready PRs
  • Compliance mapping (NIS2 · DORA · CRA)
Ronda privada Para investidores