FrankenMining

Security, confidentiality and OT safety

2,523 words7 subsections4 tablesPlan version 0.1

On this page7
31.0 Threat model31.1 MNPI: embargo states, walls and the public lane31.2 Venture walls, residency and personal data31.3 OT safety and the HumanAuthorityToken31.4 asupersync 0.5.0 defects and their mitigations31.5 Supply chain and build integrity31.6 Proof obligations and gates

Verdict (B4 SQ6): layered security. Two simpler hypotheses were refuted:

  • Capabilities alone (trust Cx) is refuted by defects S3(a)–(c) at the 0.5.0 pin (§31.4).
  • Perimeter only (FrankenMining trusts its callers) is refuted by securities and JV law: insiders need need-to-know walls, not just a perimeter.

The adopted design layers four things: typed CapSet regions, first-party macaroon caveats compiled before query expansion, physically separate projections where caveat compilation is not yet live, and fail-closed registries.

31.0 Threat model

Actor Goal or risk Primary controls
Insider with a trading motive Learn drill results or reserve changes before release MNPI walls, wall-scoped projections, insider-list logs (§31.1)
JV partner See the other partner's private data Venture walls, per-venture projections, verifiable bundles (§31.2)
External attacker via vendor files Code execution or data poisoning through imports Quarantine-on-import, pure-Rust reimplemented parsers, fuzzing (§32)
Compromised or manipulated agent Prompt injection, authority writes, wall breaches Agent model (§30.4), CELL-QUAR, tokens agents cannot mint
Attacker pivoting toward OT Command equipment through the twin No write conduit to Levels 0–2; outbound-only sessions (§31.3)
Cross-border transfer Breach of residency or mining-data law Residency registry enforced before bytes move (§31.2)
Litigation or discovery Records that read as admissions or disclosure claims Four false flags, no_claim lines, the counsel review in OPEN-HALL-4

31.1 MNPI: embargo states, walls and the public lane

  • Embargo state. Every assay and intercept record carries disclosure: Embargoed{wall, since} → Released{public_ref, at}. The transition to Released cites the public document (news release URL or filing id) and its valid time.
  • Walls.
    • Reading embargoed data requires the caveat mnpi_wall=W-….
    • There is no global search or graph index over embargoed data. Projections are wall-scoped, so neither counts nor absence leak across a wall.
    • Every access is an AccessEvent. Together they form an insider-list-ready log per wall. The exact list format per listing venue (TSX, NYSE, and any proposed listing) is OPEN-B4-07.
  • Exports refuse. Export, report, MCP and Avathon feeds refuse embargoed rows with exit 7 (FMINE-REF-301), unless the request cites a human-held mnpi_release capability.
  • Taint is monotone (INV-007). Confidentiality is a join-semilattice Public < Internal < Venture(V) < Mnpi(Wall), and derived data is at least the join of its inputs. MNPI-derived bytes never reach a public export, and export fuzzing tests this.
  • Site code stays in a private overlay. Site registries, profiles, configuration, fitted models and any site-specific code live in a private overlay on the issuer's network, never in this repository. A change moves from the overlay to the public core only as a reviewed patch: the issuer approves it, and it carries no site data, fitted values, site identifiers or fixtures built from site data (INV-007's taint rule applied to code).
  • The public lane is separate.
    • fmine assure public (M0) uses only public filings and issuer-website workbooks. A website workbook has no filing accession, so its registry entry holds the file's sha256 and the filed report page that reconciles it (§21.6; E107).
    • No public-lane author holds private access. Private access means being on an issuer insider list, being a party to a data agreement with the issuer, or having received non-public issuer information (R7-C136, R7-C137).
    • At GATE-DATA-01 the issuer's public lane is frozen at its last registered state. It is then either retired for that issuer or authored only by a walled author set with signed no-access attestations. AI agents cannot sign and a one-owner team may have no eligible author, so retirement is the default. M2′ public-lane content is then limited to reproducing already-published values and scoring the pre-registered FY2026 forecasts unless counsel clears more; BET-02's scored quarters come from the in-tenancy forward quarters plus FY2026.
    • Public-lane forecasts are hashed, pushed and externally time-stamped before the issuer's release and before any issuer insider sees M0 content (§10, §21.6, §37).
    • Issuer data terms (RISK-31): until the owner and counsel decide, the repository holds only locators (file:Sheet!Cell), source URLs, sha256 and computed check results. Fixtures that need values are synthetic and labelled, or fetched at test time from the pinned URL. Barrick's site terms allow copying for non-commercial, personal or educational use of unmodified material and otherwise need approval (R7-C052, R7-C158, R7-C160).
    • Internal sensitivity content never reaches a public renderer (G-HALL-5).

31.2 Venture walls, residency and personal data

Joint-venture walls.

  • Cells and projections are partitioned by venture. Partner principals receive venture= and redaction caveats.
  • Until fgdb's caveat compilation (Warden) is live, per-venture projection instances (physical separation) are used instead of row filtering.
  • Partners receive FA .fab bundles, verifiable with fa-verify, and FrankenMining certificate bundles, verifiable with fmine-verify. A partner can check numbers without seeing the other partner's private data.
  • A query spanning ventures without a cross-venture capability is refused (FMINE-REF-302).

Data residency.

  • registries/residency.toml maps (country, data_class) to {in_country_only, aggregates_exportable, exportable}.

  • The sync planner treats it as a hard constraint. Regional nodes hold in-country authority, and residency_epoch is part of every anchor.

  • An unauthorized class transfer is refused before any bytes move (exit 7, FMINE-REF-303), and fmine doctor reports it.

  • Each row of registries/residency.toml cites its statute and section, a status (FACT, FACT[U], INFERENCE), a confidence and a review_by date; the 72 rows researched for 12 countries are in W3 §4 (10 FACT, 23 FACT[U], 39 INFERENCE; E501–E549). An unknown (country, class) pair still defaults to in_country_only. Research, not legal advice: counsel confirms the W3 §7 clauses before any regional node goes live (OPEN-B4-01, narrowed).

    Country personal geoscience production financial state_secret aggregate
    PK INⁱ AGGⁱ AGGⁱ AGG INᵘ EXPⁱ
    ZM IN AGGⁱ AGGⁱ AGGᵘ IN EXPⁱ
    TZ IN IN AGGⁱ AGG INᵘ EXPⁱ
    CD IN AGGⁱ AGGⁱ AGGᵘ INᵘ EXPⁱ
    ML IN AGGⁱ AGGⁱ AGGᵘ INᵘ EXPⁱ
    PG INⁱ AGGⁱ AGGⁱ AGGᵘ INᵘ EXPⁱ
    DO INᵘ AGGⁱ AGGⁱ AGGᵘ INᵘ EXPⁱ
    AR INᵘ AGGⁱ AGGⁱ AGGᵘ INᵘ EXPⁱ
    CL IN EXPⁱ EXPⁱ EXPⁱ INᵘ EXPⁱ
    SA INᵘ AGGⁱ AGGⁱ AGGᵘ INᵘ EXPⁱ
    US EXPᵘ EXPⁱ EXPⁱ EXPⁱ INᵘ EXPⁱ
    CA EXPᵘ EXPⁱ EXPⁱ AGG INᵘ EXPⁱ

    IN = in_country_only, AGG = aggregates_exportable, EXP = exportable; ᵘ FACT[U], ⁱ INFERENCE, unmarked FACT. Pakistan (Reko Diq): personal and state_secret stay in-country; geoscience, production and financial are aggregates_exportable (BMR 2002 r.56, r.71; Companies Act 2017 s.220; E504–E508). Zambia (M2): personal is in_country_only (DPA 2021 s.70; E514), so the pilot node keeps rosters, fatigue and HR data on site; mining is a critical sector under the Cyber Security Act 2025, and a Gazette designation would pull production in-country (s.12; E520–E522).

  • Two legal shapes the three-value rule cannot express (W3 §1). "The authoritative copy stays in-country, replicas are allowed" (most book-keeping statutes) and "exportable once instrument X exists" (most data-protection laws: a permit, model clauses, consent). Rows may therefore carry optional requires (the instrument whose signed registration would relax the row: a Zambian ODPC-approved scheme, a Tanzanian PDPC permit or GST authorisation, a Chilean model clause), authority_in_country and deny_destinations fields. Until that instrument is registered the row's rule stands; rule alone remains the fail-closed contract. One row differs: Pakistan geoscience is researched as aggregates_exportable, but its requires is counsel's reading of BMR r.71(3)(i) and the Reko Diq agreement, so the planner holds it in_country_only until that reading is registered.

  • State-equity ventures. A venture with government holders (Reko Diq: federal SOEs 25%, Balochistan 25%, of which 10% free-carried; E302) adds sovereign partner principals, and §31.2 partner bundles serve government holders as well as listed companies. Holder kinds and interest bases are typed in OwnershipRef (§24.3).

Personal data (Muster). Person-level data (rosters, fatigue, competencies, CCV) is pseudonymized with a key held by the privacy-officer role (PO-MUST-4). It lives in restricted lanes, and its use is gated on a privacy impact assessment and, where applicable, works-council review (GATE-MUST-03).

Community and stakeholder data. GATE-DATA-05 and PO-MUST-4 pseudonymization also apply to stakeholder, consultation and grievance records. Importers redact on ingest even from public documents: consultation appendices and grievance forms can carry individuals' names, contact details, house location and signature (C5 §4.9). FrankenMining never reproduces those fields.

31.3 OT safety and the HumanAuthorityToken

  • No write conduit to ISA-95 Levels 0–2 exists or will exist (INV-011, NONGOAL-002).
    • Ingest is pulled through a DMZ relay or a data diode, using outbound-only sessions.
    • Historians are read through exported snapshots or a read-only OPC UA client on the relay, never a write session.
  • Effects are prepared, never actuated. EffectRegion emits EFFECT-* documents only: work orders, dig-line advice, blast designs for approval, shipment releases, posting intents and data releases.
  • HumanAuthorityToken. Even releasing a prepared effect needs a token:
    • a first-party macaroon minted by a named human through an interactive, strongly authenticated step;
    • caveats {effect_digest, site, expires ≤ 15 min, single-use nonce};
    • mint is an admin verb that is never exposed through MCP, so agents cannot mint tokens.
  • Some effects need dual attestation, for example concentrate shipment release (§17.6).
  • Manual gate and valve positions are evidence, not commands. They enter as attested observations with a freshness bound (§18.3). A stale or unknown position renders position unknown and can never support a "contained" statement (G-FREE-2). FrankenMining has no write path to the devices.
  • execution_authorized is never set true (INV-002).
  • Safety-semantic refusals apply before any effect is prepared:
    • FMINE-REF-401: unknown reactive ground → no ANFO plan;
    • FMINE-REF-402: unknown PAG → no NAF dump plan;
    • FMINE-REF-403: unknown moisture vs TML → no shipment release;
    • FMINE-REF-404: stale TSF instrumentation → no "within TARP" statement;
    • FMINE-REF-504: adjacent paste or cemented fill uncured or degraded (FillStrength(t) < UCS_design) → no secondary-stope blast plan (§16.3, G-HEAD-7).
  • A missing or expired token is refused (exit 7, FMINE-REF-304). There is no fallback actuation path, so nothing can fail open.

31.4 asupersync 0.5.0 defects and their mitigations

The suite pin, 0.5.0, carries known defects (B4 S3; asupersync CHANGELOG §v0.6.0). 0.6.0 fixes (a), (b) and (d) and adds (e). (c) is unchanged in 0.6.0, which only adds a protected third-party-caveat API, so the first-party-only rule stays in force after the bump. FrankenMining stays on 0.5.0 with the rest of the suite and mitigates each defect explicitly.

Defect at 0.5.0 Risk Mitigation Test (INT-AS-SEC-001)
(a) A restricted Cx<cap::None> can call open_child_region and receive Cx<cap::All> at the type level (at 0.5.0 the runtime mask still refuses SPAWN, so the lab mask test is the real control) Capability escalation from kernels xtask check-caps bans open_child_region outside fmine-runtime; each region's runtime mask is asserted in the lab Lint + runtime-mask lab test
(b) MacaroonKeyRing::verify accepts an all-zero signature when no retired key is set Token forgery The key ring is always constructed with a random retired key, plus an FM wrapper that rejects all-zero signatures Regression test with a zero signature
(c) Legacy third-party caveats can be stripped by the third party Delegation bypass First-party caveats only. A third-party caveat in an FM token is refused at mint. Mint refusal test
(d) Plaintext ATP-over-TCP is not refused off loopback; its manifest is unauthenticated Interception or tampering in transit ATP and sync run only over QUIC/TLS. The plaintext transport is banned by config and check-deps. Chunk hashes are verified end to end regardless of transport. Plaintext attempt → refusal (exit 7)
(e) Durable ATP sender/receiver journaling is a 0.6.0 feature Lost progress across crashes Resumable chunk receipts and OB-SEAL (§26.7) Lab partition matrix (INT-ATP-001)

GATE-PIN-06 (coordinated bump). FrankenMining moves to 0.6.x only when fgdb, FA and fastmcp have moved, and it re-runs INT-AS-SEC-001 when it does. It follows the suite and never leads.

OPEN-B4-02, answered as far as the record allows (2026-10-29).

  • There is no 0.6 release yet. crates.io's newest asupersync is 0.5.0 (12 Sep 2026); the repository's main branch declares 0.6.0, but no v0.6 tag exists (FACT, E653, E654).
  • Every sibling that takes asupersync from crates.io pins 0.5.x (=0.5.0, or a caret 0.5.0 that excludes 0.6), and the fgdb, FA, frankensqlite and frankensearch lockfiles resolve 0.5.0. Only frankensympy's runtime crates (fsym-runtime, fsym-durable, fsym-python) and frankensim follow main by path (FACT, E655).
  • FrankenMining is unaffected today: fmine-derive uses fsym-core, which has no asupersync dependency, and frankensim enters by lift, not by link.
  • The bump is coordinated by the suite maintainer who owns asupersync and the sibling repos. The trigger is a published 0.6.x followed by fgdb, FA and fastmcp pins; until then FrankenMining stays on =0.5.0 with the §31.4 mitigations, and check-deps fails any posture closure in which a path dependency brings in a second asupersync.

31.5 Supply chain and build integrity

  • Closed dependency universe. Every external crate is on an allow-list with a reason. deny.toml and the L-5 bans are CI gates. xtask check-deps inverts cargo tree to prove that no banned crate is present transitively.
  • Reproducible releases go through DSR with minisign signatures and an SBOM per binary. The release digest is recorded in every certificate's code-revision field.
  • Parsers are pure Rust and fuzzed (one fuzz target per decoder, §26.5 and §32).
  • Licence. Lifted code and much of the substrate carry "MIT + OpenAI/Anthropic Rider". Whether that rider is acceptable in a client-facing product is an owner and counsel decision (RISK-17, OPEN-STRATA-6).

31.6 Proof obligations and gates

PO / Gate Statement Verification / threshold
PO-SEC-1 Wall-scoped queries reveal nothing across walls, counts and absence included (= PO-BED-8) Differential tests: the same query with and without the wall's data must produce indistinguishable outputs for an outside principal
PO-SEC-2 No embargoed byte reaches a public export Export fuzzing over the taint lattice
PO-SEC-3 A HumanAuthorityToken is single-use, expires within 15 minutes and binds one effect digest Token property tests; replay attempts in the lab
PO-SEC-4 No code path writes to an OT endpoint check-deps (no OT write client in the closure) + deployment review
GATE-WALL-01 0 cross-wall leaks over 10⁴ generated query pairs M1
GATE-SEC-01 An independent penetration test of a site node and relay before any production site data is ingested Before M2