The content hash registry hardcoded into go-ethereum — maps key hashes (contract code hashes, domain name hashes) to content hashes. Part of the three-contract
Historical Significance
HashReg was a foundational piece of Ethereum's earliest content-addressing infrastructure. By linking contract code hashes to documentation hashes on-chain, it enabled the NatSpec system — an ambitious early attempt at making smart contract interactions human-readable. This pattern of content-addressed on-chain metadata registration predates and influenced later systems like IPFS pinning registries and ENS content records.
Context
NatSpec (Natural Specification) was part of Gavin Wood's original Ethereum design — a system where smart contract functions could be annotated with human-readable descriptions that wallets would display to users before transaction signing. To make this work on mainnet, three contracts needed to be deployed: GlobalRegistrar (name→address), HashReg (code hash→content hash), and UrlHint (content hash→URL). All three were deployed within 18 blocks of each other on September 24, 2015, ~55 days after Frontier launch.
Contract Information
Key Facts
Description
Deployed on September 24, 2015 (block 282,885), just 5 blocks after the GlobalRegistrar, HashReg is the content hash registry that maps key hashes to content hashes on Ethereum mainnet. It was deployed by the same go-ethereum core developer who set up the entire Frontier registrar infrastructure in a rapid multi-contract deployment session.
HashReg served a specific role in go-ethereum's NatSpec documentation system: when a developer compiled and deployed a Solidity contract, the compiler could generate a JSON document containing human-readable descriptions of each function. The hash of this documentation was then registered in HashReg, linked to the contract's code hash. This allowed any geth user running a transaction against a verified contract to receive a plain-English explanation of what the transaction would do — before signing it.
The contract's address was hardcoded into go-ethereum as HashRegAddr = "0x23bf622b5a65f6060d855fca401133ded3520620" // frontier in common/registrar/registrar.go. It works in conjunction with GlobalRegistrar (which maps the name "HashReg" to this address so go-ethereum can find it on-chain) and UrlHint (which maps content hashes to URLs where the actual documentation files can be retrieved).
The contract exposes two core functions called via ABI signatures: setowner() (establishing ownership before registration) and register(uint256,uint256) (mapping a key hash to a content hash). No source code was verified on Etherscan, but the contract's bytecode was compiled from Solidity source embedded in the go-ethereum codebase.
Source Verified
Bytecode hardcoded verbatim in go-ethereum v1.0.0 common/registrar/contracts.go (HashRegCode). Source from HashRegSrc in same file. Authored by Gav Wood, Ethereum Foundation. Exact 152-byte runtime match confirmed.
Historian Categories
Heuristic Analysis
The following characteristics were detected through bytecode analysis and may not be accurate.
Frontier Era
The initial release of Ethereum. A bare-bones implementation for technical users.
Bytecode Overview
Verified Source Available
Source verified through compiler archaeology and exact bytecode matching.
View Verification ProofShow source code (Solidity)
// SPDX-License-Identifier: UNLICENSED
// Reconstructed source of HashReg (0x23bf622b5a65f6060d855fca401133ded3520620)
// Originally authored by Gav Wood, Ethereum Foundation.
// Source preserved verbatim from go-ethereum v1.0.0 common/registrar/contracts.go (HashRegSrc)
// Compiler: unknown early Solidity (pre-release, Frontier era, ~Aug 7 2015)
// The bytecode was hardcoded directly in go-ethereum — no separate compilation needed.
contract HashReg {
function setowner() {
if (owner == 0) {
owner = msg.sender;
}
}
function register(uint256 _key, uint256 _content) {
if (msg.sender == owner) {
content[_key] = _content;
}
}
address owner;
mapping (uint256 => uint256) content;
}External Links
Related contracts
GlobalRegistrar
Same deployerThe canonical name registration contract hardcoded into go-ethereum — Ethereum's first mainnet naming system, mapping human-readable strings to addresses. A dir
0x339901...91a70cSeptember 24, 2015URLhint
Same deployerThe Ethereum Foundation's Frontier URL-hint registrar, hardcoded into go-ethereum.
0x73ed5e...c18626September 24, 2015TerraNullius
Same eraOne of the earliest interactive contracts on Ethereum, allowing users to stake claims and leave permanent messages on the blockchain.
0x6e38a4...844d66August 7, 2015GlobalRegistrar
Same eraThe official Ethereum GlobalRegistrar deployed by the go-ethereum team in August 2015. This was the canonical name registry contract embedded as pre-compiled by
0x1392a4...770c35August 7, 2015NameReg
Same eraFixed fee name registry deployed 7 August 2015, the night before NameRegistry and by the same account. Same 69 ETH fee, no read functions.
0xc076cf...a339a5August 7, 2015GlobalRegistrar
Same eraThe second deployment of the official Ethereum GlobalRegistrar, deployed nine days after the first. Both deployments use identical bytecode pre-compiled and emb
0xf436ce...6267d0August 8, 2015