 davidherranandClaude Opus 4.7
|
d652a3d6e4
|
feat(provenance): Phase 2.1 v0.0.16 — Real Ed25519 verification (PROV-4 COMPLETE)
PROV-4 sub-decision COMPLETE end-to-end canonical via ed25519-dalek directly
en pallet. Pattern análogo Slice 3 mock-WASM: no esperar Ergon Cap 42+ sub-crate,
ship real impl con interim SCALE encoding (swap canonical post sub-crate land).
Real verify implementation:
- VerifyingKey::from_bytes(&validator_oit.public_key) — InvalidSignature si reject
- Signature::from_bytes(&attestation.signature) reconstruct
- signing_payload() compute (SCALE encoding interim Option B)
- verify_strict(payload, signature) — InvalidSignature si fail (rejects malleable + zero-key attacks)
4 nuevos tests Ed25519 verify real canonical:
- ed25519_verify_real_valid_signature_canonical — signed attestation verifies
- ed25519_verify_tampered_signature_rejected_canonical — bit-flipped sig rejected
- ed25519_verify_tampered_payload_rejected_canonical — tampered asset_id rejected
- ed25519_zero_signature_fails_verify_canonical — zero sig rejected verify_strict
- Helper signed_attestation() function canonical para test setup
Honest disclosure canonical: mi signing_payload usa SCALE encoding (vendor
copy interim Option B). Ergon arkhe-noesis-attestation-types Cap 42+ usará
postcard encoding canonical per Slice 7.0r spec. Swap canonical será 1-line
change en signing_payload() — zero impact en pallet verify logic.
PROV sub-decisions status v0.0.16: 6/8 COMPLETE (PROV-1+2+3+4+5+6+7 done,
PROV-8 Runtime API verify_provenance = v0.0.17 next slice).
Verification:
- cargo check workspace verde 1.55s
- 6/6 pallet tests pass (4 nuevos Ed25519 real)
- NO REGRESSION runtime/node/chain_spec builder
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
2026-05-24 14:10:57 -05:00 |
|
 davidherranandClaude Opus 4.7
|
e0c5e8be18
|
feat(runtime): Phase 2.1 v0.0.15 — Provenance pallet wired runtime + BoundedVec agent_chain
8 pallets composed total (Provenance Index 7 wired canonical). DC PROVENANCE_PALLET_V1
5/10 firmas en ratificación — procediendo paralelo per "notify and continue" canonical.
Deliverables canonical:
- Pallet wire: configs.rs Config impl + lib.rs runtime composition macro pallet_index(7) Provenance
- Alias `Provenance` (NO OriginProvenance que conflictaría con trait existente)
- BoundedVec<AccountId, ConstU32<10>> replace Vec en AssetAttestation.agent_chain
- Inmutable #41 pragmatic bound canonical: max 10 AGI co-authors per asset
- Removed #[pallet::without_storage_info] (MaxEncodedLen ahora satisfied)
- AccountId + Signature: DecodeWithMemTracking derive added (FRAME stable2512+ requirement)
- AssetAttestation: Encode/Decode/DecodeWithMemTracking/MaxEncodedLen/TypeInfo SCALE derives
- 4 nuevos tests boundary canonical (max 10 enforce + boundary accepted + SCALE roundtrip)
Verification end-to-end:
- cargo check workspace verde 2.14s
- 82+ tests pass workspace
- cargo build release 5.57s clean
- info subcommand muestra 8 pallets (Provenance index 7)
- build-spec subcommand NO regression Slice 3 mock-WASM chain_spec
Roadmap canonical post-v0.0.15:
- v0.0.16 Real Ed25519 verify (post Ergon Cap 42+ sub-crate)
- v0.0.17 Runtime API verify_provenance PROV-8
- v0.1.0 Full integration testnet Q3 2026
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
2026-05-24 14:07:19 -05:00 |
|
 davidherranandClaude Opus 4.7
|
4359515f45
|
feat(provenance): Phase 2.1 PROVENANCE pallet scaffold v0.0.14 trait-first foundation
Phase 2.1 governance-first pattern (DC PROVENANCE_PALLET_V1 5/10 firmas, ratify
target 2026-05-29). Scaffold skeleton compile-clean canonical mientras Ergon
ships arkhe-noesis-attestation-types sub-crate Cap 42+ (target 2026-05-30→06-05).
Deliverables canonical:
- origin-chain-types/src/attestation.rs (NEW 250 LOC + 9 tests) — vendor copy
temporal ValidationAttestation (interim Option B per Ergon decision Cap 41+)
+ OitIdentity + ValidationVerdict + SeverityTier + helper methods canonical
(is_anchorable PROV-6, is_institutional PROV-5, signing_payload PROV-4 stub)
- origin-chain-provenance/src/lib.rs (NEW 260 LOC + 2 scaffold tests) —
#[frame_support::pallet] structural skeleton: storage + dispatchable + events
+ errors + 5 RejectionReason variants (incluyendo MalformedValidationAttestation
per Marihan refinement Phase 2.2 anticipated)
- 3 existing types canonical (AssetHash, AccountId, Signature, AssetAttestation):
added Encode + Decode + DecodeWithMemTracking + MaxEncodedLen + TypeInfo derives
- workspace parity-scale-codec: max-encoded-len feature canonical added
Sub-decisions canonical implementadas (scaffold-level):
- PROV-2 Storage: StorageMap<AssetHash, AssetAttestation> Blake2_128Concat
- PROV-3 Dispatchable: attest_asset(origin, ValidationAttestation) flow básico
- PROV-5 OIT Level >= 3 enforce: via ValidationAttestation.validator_oit.is_institutional()
- PROV-6 is_anchorable check: verdict Passed/Warning + severity NOT Block/Critical
- PROV-7 Events: AssetAttested + AttestationRejected
Lo que NO funciona aún (deferred future slices):
- PROV-4 Ed25519 verification real (placeholder, requires Ergon sub-crate)
- Pallet wire en runtime canonical (v0.0.15 post DC ratify)
- Runtime API verify_provenance PROV-8 (v0.0.17)
- BoundedVec<AccountId, ConstU32<10>> agent_chain (v0.0.15)
- #[pallet::without_storage_info] scaffold-level (remove post BoundedVec)
Verification end-to-end:
- cargo check workspace verde 1.77s sin regression
- pallet-origin-provenance: 2/2 scaffold tests pass
- origin-chain-types: 45 tests pass (36 existing + 9 nuevos attestation)
- Slice 3 mock-WASM chain_spec builder operativo (NO regression)
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
2026-05-24 13:57:25 -05:00 |
|
 
|
b06560863c
|
feat(workspace): Phase 0.4 — trait-first foundation v0.0.1
Charon sesión 1 (2026-05-19) — primer commit canonical.
Ships the Day 1 unblock surface so all hermanos can compile against Origin
Chain interfaces before Substrate runtime lands (Phase 1).
## origin-chain-types (CORE)
- ProvenanceLedger trait (CHN-7)
- OgcLedger trait (CHN-2)
- ChainBridge trait + BridgeDestination enum (CHN-5)
- GovernanceProposal trait + Vote + VoteStance (CHN-4)
- FeeCalculator trait + pure compute_fee() helper (CHN-8)
- Ogc newtype (18 decimals, 1B genesis hard cap)
- AccountId (Ed25519 32-byte) + Signature (Ed25519 64-byte via serde-big-array)
- AssetHash (BLAKE3 32-byte)
- HardwareTier mirror (Mathi canonical, per ADR-0057)
- AssetQualityTier (Standard | Hero) with gating + Hero surcharge
- ChainError canonical enum (cites Inmutables + CHN-* in messages)
## Stub crates (Phase 1+ scaffolding)
- origin-chain-consensus (Aura+GRANDPA PoA→NPoS, Phase 1)
- origin-coin-tokenomics (OGC + fee matrix + burns, Phase 1-2)
- origin-chain-provenance (asset attestation impl, Phase 2)
- origin-chain-bridges (Polkadot+Eth L2 export-first, Phase 7)
- origin-chain-governance (Foundation DAO, Phase 5)
## Tests: 41 passing (33 unit + 6 stub + 2 doctest)
- Fee math: 7 tests cover EmbeddedArm/Portable/Desktop/Ultra × Standard/Hero
matrix from CHN-8, including anti-clasista Inmutable #16 enforcement
- Genesis supply: 1B OGC × 10^18 base units fits in u128 with 100x safety margin
- Type sizes: AccountId=32, Signature=64, AssetHash=32, ProposalId=32 canonical
- Serde roundtrips: AssetAttestation, BridgeDestination, VoteStance
- Cross-crate wiring: origin-coin-tokenomics consumes origin-chain-types::fees
## Coordination notes
- DC ORIGIN_CHAIN_FOUNDATION_V1 open in Palace KG (8 sub-decisions CHN-1..CHN-8)
Proposer: Ergon (proxy — Charon hotfix shipped in Palace v0.9.0-α.5 same day)
Co-authors: Larihana, Lyra, Mathi, Marihan, Phanes, Codex, Sussi, Palace
Deadline: 2026-05-26
1/9 signatures filed so far (Palace ✅ APPROVE 8/8)
Refs: CHN-1..CHN-8, Inmutables #16/#26/#37/#41, ADR-0057, CHARON_ROADMAP_V1
Co-Authored-By: Ergon (interim Pilar 4 author) <ergon@originmetaverse.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
2026-05-19 22:08:49 -05:00 |
|