On-Chain Attestation Registry
An owner-gated Solidity registry that appends immutable, timestamped keccak256 attestation records on Ethereum, with client-side document verification and no backend infrastructure.
GitHub ↗The registry is a single Solidity contract with no imports and no external contract dependencies — no backend, no database, no indexer, no server-side blockchain service. The frontend communicates with the contract directly through the user's wallet.
The client talks directly to the contract through the user's wallet — there is no backend, database, or indexing layer between them.
Wallet interaction, registration UI, PDF hashing, verification, and history exploration.
Provider, signer, contract abstraction, transaction submission, contract reads, and Keccak hashing.
Authorization, record validation, append-only storage, ownership, public reads, and event emission.
Canonical storage for registered provenance records.
Every registration appends one ProtocolRecord to the calling protocol's history. The contract stores and preserves these submitted claims — it does not independently verify the PDF contents, the auditor's identity, the Git commit, or the relationship between contractAddress and the audited code.
Free-form protocol identifier.
Mapping key for the protocol's history.
Free-form version string.
bytes32 document fingerprint.
bytes32 caller-supplied code-revision metadata.
Free-form attribution.
Assigned by block.timestamp.
Registration is restricted to the current contract owner through onlyOwner.
Verification is read-only and requires no transaction. PDF bytes are hashed entirely client-side — the PDF itself never leaves the browser — and only the resulting bytes32 hash is compared with on-chain state, checked against historical records, not just the latest one. The interface distinguishes four outcomes:
Records are stored in a per-address dynamic array; registration only appends, and existing records cannot be modified or deleted through the contract ABI. Historical records remain publicly readable.
- getLatestRecord() returns the most recently appended record
- getRecordCount() exposes the current number of records
- The Explorer reads contract storage directly — there is no indexer
The registry provides integrity of the registered record, not proof that the registered claims are truthful.
The current deployment exists because of an authorization-boundary remediation, not a design change: the previous contract allowed any caller to invoke registerProtocolRecord(); the current one restricts it to the owner. Deployed Solidity bytecode is immutable, so the fix required a new deployment rather than a patch.
0x8166431404B7f8e5e9d351333e08548a23Bbdae0 — allowed arbitrary callers to register records. No longer in use.
0xd8FC6C229d7666865EDE56f56C68Af01cC5021BA — adds onlyOwner, confirmed by a live non-owner simulation that reverts with NotOwner.
16/16 Solidity tests passing
Tests cover deployment/ownership, registration, unauthorized registration, field validation, ownership transfer, multi-record history, latest-record retrieval, and public read access
Deployment pipeline (manually triggered) compiles, tests, and deploys via Hardhat Ignition
Deployment pipeline verifies deployed bytecode, owner, and a record-read sanity check
Deployment pipeline runs a non-owner registration simulation
Current contract has verified source on Etherscan and Sourcify, per the project's deployment record
Ethereum Sepolia — a testnet, not Ethereum Mainnet. The core system is complete and end-to-end validated: register, verify, and explore all work against this deployment.
The registry makes provenance records tamper-evident, not inherently truthful.
Once written, a record cannot be silently modified or deleted through the contract, anyone can read it, and anyone can independently hash a document and compare it with the stored hash.
Before registration, only the owner can create records — the owner determines what claims are recorded and is trusted for the truthfulness of the submitted metadata.
Tamper-Evident ≠ Inherently Truthful