Skip to content

Commit 9e58ef3

Browse files
authored
Merge pull request #24 from gheber/update/safety-model
Extended safety model: long-term access
2 parents b318332 + 2e0d12c commit 9e58ef3

1 file changed

Lines changed: 22 additions & 7 deletions

File tree

models/Safety Hazard.md

Lines changed: 22 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ Our primary goal is to keep HDF5 files, tools, and workflows out of unsafe state
4848
- **Availability:** files and tools should fail safe, remain recoverable where possible, and avoid cascading breakage.
4949
- **In-memory safety:** internal structures should not drift into states that cause wrong writes, wrong frees, or silent corruption.
5050
- **Privacy protection:** metadata, logs, temporary artifacts, and extension behavior should not leak sensitive information.
51+
- **Long-term interpretability:** files designated for retention remain readable and semantically interpretable for their retention horizon, either directly or through a preserved fallback path.
5152

5253
## 2) HDF5 Control System (H5CS) model
5354

@@ -68,8 +69,8 @@ flowchart LR
6869

6970
### What matters in practice
7071

71-
- **Controllers:** application code, HDF5 API layers, metadata cache, free-space manager, chunk cache, plugin loaders, and parts of the OS or filesystem stack that influence persistence.
72-
- **Control actions:** emit durable bytes, mark dirty or clean, evict entries, reuse free space, parse structures, load extensions, and signal durability.
72+
- **Controllers:** application code, HDF5 API layers, metadata cache, free-space manager, chunk cache, plugin loaders, parts of the OS or filesystem stack that influence persistence, archive curator, package/distribution manager, plugin registry, signing/CA infrastructure, and integrator.
73+
- **Control actions:** emit durable bytes, mark dirty or clean, evict entries, reuse free space, parse structures, load extensions, and signal durability, record dependency manifest, archive plugin artifact, verify compatibility, transcode to archival profile, and revalidate/migrate before support ends.
7374
- **Controlled state:** on-disk metadata and raw data, in-memory caches and indices, in-flight writes, temporary files, logs, and plugin search paths.
7475
- **Feedback:** return codes, error stacks, file locking outcomes, validation results, checksums, reopen behavior, and monitoring signals.
7576

@@ -119,6 +120,9 @@ Describe hazards as state conditions, not events. Good hazard statements look li
119120
- in-memory state diverges from disk without a safe replay or repair path
120121
- durability-signaling actions can complete before required bytes are actually safe
121122
- sensitive metadata can escape through logs or artifacts
123+
- the file requires an external decoder that is unavailable or unverifiable
124+
- plugin semantics are required but not durably recorded
125+
- a compatible decoder exists but cannot be rebuilt or trusted
122126

123127
### Step 3 - Enumerate unsafe control actions
124128

@@ -210,6 +214,16 @@ Record the hazard in the register and tag it with one or more SSP categories fro
210214
- Common tags: **PRV**, **OPS**
211215
- Typical controls: logging review, redaction guidance, safe defaults for traces and dumps, artifact retention controls
212216

217+
### Example 5 - Long-term interpretability failure
218+
219+
**Scenario:** A filter/VOL/VFD is required to interpret retained data, but the artifact, source, key chain, or compatible runtime is no longer available.
220+
221+
- Trigger: time passes, dependencies rot, or the artifact is lost or compromised
222+
- Unsafe state: the file cannot be interpreted or trusted for its retention horizon
223+
- Loss: data becomes inaccessible or unreliable, even if the bytes are still there
224+
- Common tags: **FMT**, **EXT**, **TCD**, **SCD**, **UNK**
225+
- Typical controls: durable recording of plugin semantics, fallback to archival profiles, artifact preservation guidance, monitoring for vulnerable dependencies
226+
213227
## 5) Hazard register template
214228

215229
Use this template for entries in the hazard register, including updates to [audit/registry/safety-hazards](../audit/registry/safety-hazards).
@@ -261,18 +275,19 @@ Use the hazard families below as the safety vocabulary, then tag each finding wi
261275
| **H6** | Parser ambiguity | Weak validation or underspecified interpretation allows malformed or divergent parses. |
262276
| **H7** | Extension boundary violation | A filter, VOL, VFD, wrapper, or plugin violates assumptions that the core library depends on. |
263277
| **H8** | Operational, privacy, or supply-chain exposure | Misconfiguration, artifact leakage, unsafe deployment, or compromised distribution introduces a safety-relevant hazard. |
278+
| **H9** | External dependency failure | Correct interpretation of a retained HDF5 file depends on external code, artifacts, keys, or build context that later becomes unavailable, unverifiable, or incompatible. |
264279

265280
### Alignment table
266281

267282
| Vulnerability category | What it looks like in a safety review | Hazard families most often involved |
268283
| --- | --- | --- |
269-
| **FMT** (File format) | malformed or partially persisted file structures, dangling references, ambiguous parsing, weak integrity checks | H1, H2, H6 |
284+
| **FMT** (File format) | malformed or partially persisted file structures, dangling references, ambiguous parsing, weak integrity checks, plugin semantics needed to interpret stored bytes | H1, H2, H6, H9 |
270285
| **LIB** (Core Library) | memory safety faults, cache or free-space logic errors, wrong durability semantics, unsafe internal defaults | H2, H3, H4, H5 |
271-
| **EXT** (Extensions/plugins) | filters, VOLs, VFDs, or wrappers producing invalid state or loading unsafe code paths | H7, H8 |
272-
| **TCD** (Toolchain/deps) | dependency flaws, wrapper behavior drift, unpinned toolchains, build-time semantic changes | H5, H7, H8 |
273-
| **OPS** (Operational/usage) | unsafe sharing modes, weak locking, durability misunderstandings, bad deployment assumptions | H2, H3, H8 |
286+
| **EXT** (Extensions/plugins) | filters, VOLs, VFDs, or wrappers producing invalid state or loading unsafe code paths | H7, H8, H9 |
287+
| **TCD** (Toolchain/deps) | dependency flaws, wrapper behavior drift, unpinned toolchains, build-time semantic changes | H5, H7, H8, H9 |
288+
| **OPS** (Operational/usage) | unsafe sharing modes, weak locking, durability misunderstandings, bad deployment assumptions | H2, H3, H8, H9 |
274289
| **PRV** (Privacy-specific) | metadata leakage, unsafe logging, retained debug artifacts, traceability surprises | H8 |
275-
| **SCD** (Supply Chain/dist.) | unsigned or compromised binaries, plugin path hijacking, unsafe distribution channels | H7, H8 |
290+
| **SCD** (Supply Chain/dist.) | unsigned or compromised binaries, plugin path hijacking, unsafe distribution channels | H7, H8, H9 |
276291
| **UNK** (Unknown) | newly discovered or not-yet-classified hazard chains | any |
277292

278293
## 7) Checklists for reviewers

0 commit comments

Comments
 (0)