Skip to content

Introduce asset registry; extend block multi-root model, semantics and PQ/AI policies; enforce native token mint policy#310

Merged
aoxc merged 2 commits intodevelopfrom
codex/propose-new-block-format-design
Mar 24, 2026
Merged

Introduce asset registry; extend block multi-root model, semantics and PQ/AI policies; enforce native token mint policy#310
aoxc merged 2 commits intodevelopfrom
codex/propose-new-block-format-design

Conversation

@aoxc
Copy link
Owner

@aoxc aoxc commented Mar 24, 2026

Motivation

  • Provide an on-chain AssetRegistry with lifecycle states, certificate validation and deterministic receipts to manage asset registration and governance.
  • Evolve the block model to a multi-root, section-based CMB v1 design to support Execution/Identity/Post-Quantum/AI/Settlement/Constitutional/TimeSeal semantics and capability flags.
  • Add canonical policy handling for post-quantum signature migration and enforce semantic invariants at build time to prevent invalid blocks.
  • Tighten native token minting so the ledger respects supply model policies (e.g. MintDisabled).

Description

  • Adds a new crates/aoxcore/src/asset/mod.rs implementing AssetRegistry, AssetRegistryEntry, RegistryCertificate, state enums, validation, lifecycle transitions, receipt-emitting helpers and unit tests, and exports the module via crates/aoxcore/src/lib.rs with pub mod asset;.
  • Updates crates/aoxcore/src/native_token.rs to replace mintable: bool with NativeTokenPolicy::supply_model: SupplyModel, introduce allows_mint() logic, return NativeTokenError::MintDisabledPolicy when minting is disallowed, add related error code ERROR_CODE_MINT_DISABLED and tests (mint_is_rejected_when_supply_model_disables_mint, default_policy_is_canonical_native).
  • Extends aoxcunity block model with new section types and multi-root header fields by updating types.rs (new Execution/Identity/PostQuantum/Ai/ExternalSettlement/Constitutional/TimeSeal types, SignaturePolicy enum, capability flags, header fields and helpers), hash.rs (new root domains, section hashing, capability flags propagation and new helper hash functions), and builder.rs (canonicalization, semantic validation calls, header field population and additional tests).
  • Adds policy_registry.rs for resolve_signature_policy and enforce_signature_policy_migration (with PQ_MANDATORY_START_EPOCH) and semantic.rs for validate_block_semantics, validate_capability_section_alignment and validate_root_semantic_bindings with tests covering PQ, AI, TimeSeal and capability alignment rules.
  • Exposes new types and helpers from aoxcunity/src/lib.rs and updates docs by adding CMB v1 design and final semantic audit pages and SUMMARY.md entries.

Testing

  • Ran unit tests in the workspace covering aoxcore asset tests and native_token tests; all asset and native token tests passed (validation, lifecycle flows, receipts and mint-policy cases).
  • Ran aoxcunity block module unit tests covering builder determinism, duplicate section detection, capability flag exposure, time-seal/AI/PQ semantic validation, root-binding checks and policy registry behavior; all tests passed.
  • cargo test across the modified crates was exercised and completed successfully.

Codex Task

Repository owner deleted a comment from chatgpt-codex-connector bot Mar 24, 2026
@aoxc aoxc merged commit b2e8941 into develop Mar 24, 2026
0 of 2 checks passed
@aoxc aoxc deleted the codex/propose-new-block-format-design branch March 24, 2026 14:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant