Faultline

Earthquake cat bond on Hedera: a locked rule, signed USGS data and payout in one transaction

Faultline

Created At

ETHGlobal Mumbai

Winner of

Hedera

Hedera - Tokenize Anything with Hedera Studios 3rd place

Project Description

Faultline

Faultline is an on-chain parametric earthquake catastrophe bond built on Hedera using Asset Tokenization Studio (ATS). It replaces traditional SPVs, manual calculation agents, and fragmented reporting with automated, auditable smart contracts.

The Problem

Traditional catastrophe bonds transfer disaster risk to capital markets, reaching $65.5B outstanding by Q3 2026. However, issuance remains slow and expensive. High-risk emerging regions like India lack sovereign cat bonds or parametric cover, despite active seismic zones like Kutch (site of the 2001 M7.7 Bhuj earthquake).

How It Works

  1. Deposit & Issuance: A sponsor funds an HTS stablecoin coupon reserve. KYC-cleared investors deposit stablecoin into FaultlinePool, which mints ATS bond units 1:1.
  2. Immutable Rules: Terms are hashed on-chain (termsHash) at issuance. The Kutch rule covers coordinates 22.5–24.5° N, 68.5–71.5° E (depth ≤ 70 km) with a linear payout from 0% loss at M7.0 to 100% at M8.0 (USGS-reviewed).
  3. Oracle Attestation: Post-quake, the calculation agent ingests USGS data, signs an EIP-712 attestation, and logs it to an HCS topic. A relayer forwards this to FaultlineTrigger.
  4. Challenge Window: A time-locked dispute window allows the trustee to pause or veto erroneous reports (bounded trust).
  5. Instant Settlement: Calling execute() applies an O(1) global loss index, writing down all holders and releasing payout to the sponsor in one transaction.
  6. Maturity: Investors redeem remaining principal plus accrued coupon yield.

Hedera Architecture

  • ATS v8: Regulated security token, KYC verification, and lifecycle management.
  • HTS: Stablecoin collateral, coupon distributions, and disaster payouts.
  • HCS: Tamper-proof, ordered audit log for signed oracle data.
  • EVM Contracts: Pool and trigger settlement logic.
  • Mirror Node: Fast queries for the Next.js/MetaMask dashboard (Investor, Sponsor, Trustee, Replay, Evidence, Issuer).

Testnet Results & Metrics

  • Historical Replay: Replayed 2001 Bhuj event (usp000a8ds) with an exact 70% loss settlement.
  • Trustee Veto: Successfully intercepted and vetoed a synthetic invalid trigger.
  • Balance Audit: Zero-leakage accounting across 34 live test transactions ($501 = 500 deposits + 1 reserve).
  • Verification: Smart contracts verified on Sourcify (exact match).
  • Test Suite: 436 Hardhat, 83 Oracle, 99 Unit, and 11 Playwright tests.

Note: Faultline is an unaudited prototype for demonstration only. Not a licensed insurance or securities product.

How it's Made

Faultline Architecture & Implementation

Tech Stack

  • Smart Contracts: Solidity 0.8.28, OpenZeppelin Contracts v5

  • Testing & Deployment:

  • Hardhat 2: Compilation, unit testing, security checks, and fast-check invariant fuzzing (436 tests)

  • Hardhat 3: Testnet execution using an encrypted keystore (zero plaintext private keys)

  • Oracle CLI: TypeScript, Hedera SDK (@hashgraph/sdk 2.81), ethers v6, Zod

  • Frontend Dashboard: Next.js 16, React 19, Tailwind CSS v4, ethers v6; tested via Vitest and Playwright; hosted on Vercel


System Integration & Lifecycle

  • Token Lifecycle: The bond is an ATS v8 security token deployed via the ATS factory. FaultlinePool holds the exclusive issuer role to mint tokens 1:1 against HTS stablecoin deposits and burns them at maturity using controllerRedeem
  • O(1) Accounting: Scalable settlements avoid looping over holders (O(n)). The pool updates a single global loss index and coupon index; all balance and payout adjustments evaluate on-demand from index deltas
  • Trigger Verification: FaultlineTrigger validates oracle EIP-712 signatures against termsHash (RFC 8785 canonical JSON + keccak256), managing dispute windows, trustee pauses, vetoes, and replay protection
  • Deterministic Terms: The termsHash logic resides in a shared TypeScript library imported across contract tests, the oracle, and the dashboard to guarantee consensus on parameter rules

Integrated Ecosystem Services

  • Asset Tokenization Studio (ATS): Handles regulatory compliance, KYC gating, role partitioning, and controller-directed redemptions
  • Hedera Token Service (HTS): Native ledger support for stablecoin collateral, coupon distributions, and payout transfers
  • Hedera Consensus Service (HCS): Serves as an immutable, sequential audit trail for oracle attestations; the client verifies EIP-712 signatures directly from mirror node streams
  • Infrastructure & Data:
  • USGS ComCat: Authoritative source for earthquake magnitude, coordinates, and depth
  • Hedera Mirror Node: Backs dashboard event streams and HCS feeds
  • RPC Layer: Hashio JSON-RPC relay with automatic failover to thirdweb
  • Contract Verification: Fully verified with exact bytecode matches on Sourcify

Engineering Solutions & Edge Cases

  1. Testnet Historical Replay:
  • Shrunk the real 2001 Bhuj event (usp000a8ds) into a 30-minute testnet risk window via timeOffsetSec
  • Hardcoded chain-ID guards prevent replay terms from ever executing on mainnet
  1. Automated Trustee Pause:
  • Pre-signed pause transactions execute instantly upon oracle attestation broadcast, confirming within 6 seconds of a 120-second challenge window (114 seconds remaining)
  1. HTS Empty Revert Handling:
  • HTS system calls revert with empty data in the EVM, obscuring KYC or freeze failures
  • Decodes failure reasons via mirror node trace analysis to display actionable UI error states instead of raw EVM reverts
  1. 1.3× Gas Buffering:
  • Compensates for EIP-3529 storage refund anomalies in ATS execution paths by applying an automatic 1.3× buffer over standard eth_estimateGas values to eliminate INSUFFICIENT_GAS failures
  1. Non-EVM Workflow Fallbacks:
  • To work around lack of HCS EVM precompiles, the dashboard outputs prefilled CLI commands for HCS topic creation, HTS KYC granting, and oracle binding directly from the issuer portal
  1. Decoupled Wallet Execution:
  • The frontend handles read simulations, gas estimation, and receipt polling across dedicated RPCs with automatic retries; browser wallets are used solely for signature authorizations
  1. Idempotent Deployments:
  • All deployment and interaction scripts default to dry-run mode unless explicitly flagged (EXECUTE=1), supporting clean, repeatable demo states
background image mobile

Join the mailing list

Get the latest news and updates