Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

I Built Tenant-Scoped Memory That Erases for Real — 89 Tests, 27 Mutations, Byte-Level Verified

说明与用途

ragleap-memory 库在 SQL 内部实现租户隔离,并通过 erase() 确保字节级别的彻底删除。

问题

Most memory libraries expose tenant isolation only in application code, leaking existence through different error messages for missing versus out‑of‑scope records.

结果

All tests passed (89 for memory, 101 for security), mutation testing killed every mutation (27/27 for memory, 30/30 for security), and byte‑level checks confirmed that erased data is no longer present in the database or journal.

工作流

  • Parse tenant scope with ragleap_security.Scope
  • Create SQLiteStore with ragleap_memory.SQLiteStore
  • Add entries with store.add(text, type, scope)
  • Search entries with store.search(query, scope)
  • Supersede entries with store.supersede(id, text, scope)
  • Soft delete with store.forget(id, scope)
  • Hard delete with store.erase(id, scope)
  • Verify byte‑level removal by grepping the database file

证据

Tenant isolation enforced inside SQL, not in app code. And erase() actually removes bytes.

来源

After erase, byte-level check: grep -a "New threshold" memory.db → not found

来源

Verified: 101 tests, 30/30 mutations killed, reproducible build matches PyPI.

来源

No Windows / NFS / multi-process writes / power-loss tests

来源

  • 记录日期: 2026-10-24T17:11:12.380Z