{
 "format": "zoobc-conformance-vectors/1",
 "edition": "0.6.1",
 "chapter": "30",
 "license": "CC BY 4.0, ZooBC Foundation",
 "cases": [
  {
   "id": "30-1-cli",
   "chapter": "30",
   "section": "1",
   "title": "The command line",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "start": "--start /etc/zoobc/node.conf --log-level debug starts the daemon with debug logging",
    "log_level_alone": "exit 1",
    "no_argument": "a self-test, exit 0",
    "exit_codes": "0 normal stop, 1 start-up error, 3 spine alarm",
    "default_config": "~/.zoobc/node.conf"
   }
  },
  {
   "id": "30-2-chain-id",
   "chapter": "30",
   "section": "2",
   "title": "The chain id of a TestNet built from the shipped genesis file",
   "kind": "30-eth-chain-id",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "genesis": "3A2897E7C5AD6143429BAB33A92D14D11FFD6FC281F2B62A6FD6B49C183B863D"
   },
   "expected": {
    "chain_id": "142817832"
   },
   "note": "0x0883 << 16 | 0x3A << 8 | 0x28 = 0x08833A28. The relaunch sets the genesis timestamp at launch, so a live chain answers the id of the genesis hash it announces on launch day."
  },
  {
   "id": "30-2-chain-id-devnet",
   "chapter": "30",
   "section": "2",
   "title": "The chain id of a DevNet built from the shipped genesis file",
   "kind": "30-eth-chain-id",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "genesis": "A37B1692EC47C7B17A7F9CB4C13CC8A73A1D5E843565A5733B9DA2A544DF99F8"
   },
   "expected": {
    "chain_id": "142844795"
   },
   "note": "0x0883 << 16 | 0xA3 << 8 | 0x7B = 0x0883A37B."
  },
  {
   "id": "30-2-chain-id-retired",
   "chapter": "30",
   "section": "2",
   "title": "The retired TestNet genesis keeps 883",
   "kind": "30-eth-chain-id",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "genesis": "F2F8B91BBE3437F32DF3317C39C28FE08EB874BED18C8EB3DE2C658C650D7B3A"
   },
   "expected": {
    "chain_id": "883"
   }
  },
  {
   "id": "30-2-chain-id-prefix-only",
   "chapter": "30",
   "section": "2",
   "title": "A genesis sharing only the retired genesis's first eight bytes derives its own id",
   "kind": "30-eth-chain-id",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "genesis": "F2F8B91BBE3437F3000000000000000000000000000000000000000000000000"
   },
   "expected": {
    "chain_id": "142865144"
   }
  },
  {
   "id": "30-2-public-ip-port",
   "chapter": "30",
   "section": "2",
   "title": "public_ip with a port stops the node",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[network]\npublic_ip = 203.0.113.7:8001\n"
   },
   "expected": {
    "error": "Invalid public_ip '203.0.113.7:8001' (an IPv4 address without a port, e.g. 203.0.113.7)"
   }
  },
  {
   "id": "30-2-public-ip",
   "chapter": "30",
   "section": "2",
   "title": "public_ip stated as an IPv4 address",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[network]\npublic_ip = 203.0.113.7\n"
   },
   "expected": {
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "node_id": "2996207447635562078",
    "public_ip": "203.0.113.7"
   }
  },
  {
   "id": "30-2-api-on",
   "chapter": "30",
   "section": "2",
   "title": "api_enabled = on is false in [api]",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[api]\napi_enabled = on\n"
   },
   "expected": {
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "node_id": "2996207447635562078",
    "api_enabled": "false"
   }
  },
  {
   "id": "30-2-api-True",
   "chapter": "30",
   "section": "2",
   "title": "api_enabled = True is false in [api] (exact spelling only)",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[api]\napi_enabled = True\n"
   },
   "expected": {
    "api_enabled": "false"
   }
  },
  {
   "id": "30-2-node-On",
   "chapter": "30",
   "section": "2",
   "title": "auto_resync = Off and upnp_enabled = ON read in any case outside [api] and [rpc]",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\nauto_resync = Off\n[network]\nupnp_enabled = ON\n"
   },
   "expected": {
    "auto_resync": "false",
    "upnp_enabled": "true"
   }
  },
  {
   "id": "30-2-log-mib",
   "chapter": "30",
   "section": "2",
   "title": "max_log_file_size = 10 is 10 MiB",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[logging]\nmax_log_file_size = 10\n"
   },
   "expected": {
    "max_log_file_size": "10485760"
   }
  },
  {
   "id": "30-2-log-bytes",
   "chapter": "30",
   "section": "2",
   "title": "max_log_file_size = 20000 is 20,000 bytes",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[logging]\nmax_log_file_size = 20000\n"
   },
   "expected": {
    "max_log_file_size": "20000"
   }
  },
  {
   "id": "30-2-defaults",
   "chapter": "30",
   "section": "2",
   "title": "The defaults of the keys read here",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "node_id": "2996207447635562078",
    "auto_resync": "true",
    "upnp_enabled": "true",
    "public_ip": "",
    "api_enabled": "true",
    "max_log_file_size": "52428800",
    "require_signed_receipt_requests": "false"
   }
  },
  {
   "id": "30-2-notify-no-from",
   "chapter": "30",
   "section": "2",
   "title": "[notifications] with notify_email and no smtp_from stops the node",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[notifications]\nnotify_email = ops@example.org\nsmtp_host = mail.example.org\n"
   },
   "expected": {
    "error": "[notifications] with notify_email requires smtp_host and smtp_from"
   }
  },
  {
   "id": "30-2-notify-tls",
   "chapter": "30",
   "section": "2",
   "title": "smtp_tls must be starttls, tls or off",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[notifications]\nsmtp_tls = ssl\n"
   },
   "expected": {
    "error": "notifications smtp_tls must be starttls, tls or off"
   }
  },
  {
   "id": "30-2-notify-port",
   "chapter": "30",
   "section": "2",
   "title": "smtp_port 0 stops the node",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[notifications]\nsmtp_port = 0\n"
   },
   "expected": {
    "error": "notifications smtp_port must be between 1 and 65535"
   }
  },
  {
   "id": "30-2-notify-ok",
   "chapter": "30",
   "section": "2",
   "title": "A complete [notifications] section",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n[notifications]\nnotify_email = ops@example.org, night@example.org\nsmtp_host = mail.example.org\nsmtp_from = node@example.org\n"
   },
   "expected": {
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "node_id": "2996207447635562078",
    "notify_email": "ops@example.org,night@example.org"
   }
  },
  {
   "id": "30-2-receipts-default",
   "chapter": "30",
   "section": "2",
   "title": "A node.conf without require_signed_receipt_requests reads false",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "require_signed_receipt_requests": "false"
   }
  },
  {
   "id": "30-2-receipts-on",
   "chapter": "30",
   "section": "2",
   "title": "require_signed_receipt_requests = true under [node]",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\nrequire_signed_receipt_requests = true\n"
   },
   "expected": {
    "require_signed_receipt_requests": "true"
   }
  },
  {
   "id": "30-2-receipts-installer",
   "chapter": "30",
   "section": "2",
   "title": "What the installer and the relaunch write for require_signed_receipt_requests",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "new_node_conf": "true, for the release v0.6.1-testnet or v0.6.1-devnet",
    "kept_without_the_key": "the installer adds true",
    "kept_with_false": "kept false by the installer, set to true by the relaunch's staging step",
    "read_without_the_key": "false"
   }
  },
  {
   "id": "30-2-outside-section",
   "chapter": "30",
   "section": "2",
   "title": "A key = value before any section",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "listen_address = 0.0.0.0:8001\n[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "error": "*"
   }
  },
  {
   "id": "30-2-no-owner",
   "chapter": "30",
   "section": "2",
   "title": "A configuration without an owner address",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\n"
   },
   "expected": {
    "error": "*"
   }
  },
  {
   "id": "30-2-btc-default-pair",
   "chapter": "30",
   "section": "2",
   "title": "The Bitcoin-style adapter refuses the pair zoobc / zoobc",
   "kind": "30-btc-credentials",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "user": "zoobc",
    "password": "zoobc"
   },
   "expected": {
    "error": "*"
   }
  },
  {
   "id": "30-2-btc-no-password",
   "chapter": "30",
   "section": "2",
   "title": "The Bitcoin-style adapter needs both user and password",
   "kind": "30-btc-credentials",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "user": "operator",
    "password": ""
   },
   "expected": {
    "error": "*"
   }
  },
  {
   "id": "30-2-btc-ok",
   "chapter": "30",
   "section": "2",
   "title": "Operator-chosen credentials are usable",
   "kind": "30-btc-credentials",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "user": "operator",
    "password": "s3cret"
   },
   "expected": {
    "usable": "true"
   }
  },
  {
   "id": "30-2-ports",
   "chapter": "30",
   "section": "2",
   "title": "The default ports and limits",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "p2p": "8001",
    "api": "8080",
    "eth_rpc": "8545 (127.0.0.1)",
    "btc_rpc": "8332, off",
    "write_requests_per_minute": "300",
    "read_requests_per_minute": "0 (unlimited)",
    "auth_failure_lockout_threshold": "20",
    "auth_failure_lockout_seconds": "300",
    "max_mempool_size": "25000",
    "max_pending_txs_per_sender": "50",
    "min_mempool_age_seconds": "10",
    "storage_replication": "5",
    "storage_epoch_blocks": "240",
    "archive_min_disk_gb": "20",
    "bridge_min_disk_gb": "20",
    "bridge_min_ram_mb": "512",
    "max_log_file_size": "50 MiB"
   }
  },
  {
   "id": "30-3-node-id",
   "chapter": "30",
   "section": "3",
   "title": "The node id of a public TestNet node key",
   "kind": "30-node-id",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "public_key": "EB89F581920CAC9343663A33911D76CEF5C89390F25865651D902792B881AD65"
   },
   "expected": {
    "node_id": "1417521806099974635"
   },
   "note": "LE u64 of EB89F581920CAC93 = 0x93AC0C9281F589EB, bit 63 cleared."
  },
  {
   "id": "30-3-seed",
   "chapter": "30",
   "section": "3",
   "title": "A 32-byte private key is a seed: its public key and node id",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = 5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "node_id": "2996207447635562078"
   }
  },
  {
   "id": "30-3-secret-key",
   "chapter": "30",
   "section": "3",
   "title": "A 64-byte private key: the public key is its last 32 bytes",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d965e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "node_id": "2996207447635562078"
   }
  },
  {
   "id": "30-3-znk",
   "chapter": "30",
   "section": "3",
   "title": "node_public_key given as a ZNK_ address",
   "kind": "30-node-config",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = ZNK_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJH435X\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "node_id": "2996207447635562078"
   }
  },
  {
   "id": "30-3-znk-bad-checksum",
   "chapter": "30",
   "section": "3",
   "title": "A ZNK_ text whose checksum is that of the ZBC_ form is refused",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = ZNK_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "error": "*"
   }
  },
  {
   "id": "30-3-wrong-length",
   "chapter": "30",
   "section": "3",
   "title": "A 33-byte private key is refused",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d9600\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "error": "*"
   }
  },
  {
   "id": "30-3-mismatch",
   "chapter": "30",
   "section": "3",
   "title": "A public key that does not match the private key is refused",
   "kind": "30-node-config",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "config": "[node]\nnode_private_key = 51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\nnode_public_key = fd4472bbdec43b919aa37b9b3366a3318f2902a753a15f5fd6d43c44b5121b67\nnode_owner_address = ZBC_L2HLFDOM_VKKKTEXX_C2P2M6LG_EB6ZNKSV_356SJUWW_5QPVHDE7_EFJA3PEX\n"
   },
   "expected": {
    "error": "*"
   }
  },
  {
   "id": "30-3-rotation",
   "chapter": "30",
   "section": "3",
   "title": "A key rotation takes effect 120 blocks after its block",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "delay_blocks": "120"
   }
  },
  {
   "id": "30-3-observer",
   "chapter": "30",
   "section": "3",
   "title": "A key with no row in the registry",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "value": "observer mode: the node syncs and relays; nothing is written to the registry"
   }
  },
  {
   "id": "30-3-registry-unreadable",
   "chapter": "30",
   "section": "3",
   "title": "A registry table that cannot be read stops the start",
   "kind": "reference",
   "validity": "invalid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "exit": "1",
    "error": "Cannot read the node registry at startup: <reason>"
   }
  },
  {
   "id": "30-4-no-genesis",
   "chapter": "30",
   "section": "4",
   "title": "A database without block 0",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "exit": "1",
    "message": "Cannot read the genesis block hash; the chain identity is unknown"
   }
  },
  {
   "id": "30-4-upnp",
   "chapter": "30",
   "section": "4",
   "title": "The UPnP mapping",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "lease_seconds": "3600",
    "renew_seconds": "1200"
   }
  },
  {
   "id": "30-4a-clock",
   "chapter": "30",
   "section": "4a",
   "title": "2026-11-04 00:00:00 UTC",
   "kind": "30-utc-seconds",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "utc": "2026-11-04 00:00:00"
   },
   "expected": {
    "seconds": "1793750400"
   }
  },
  {
   "id": "30-4a-clock-27",
   "chapter": "30",
   "section": "4a",
   "title": "The stand-in timestamp 1,794,211,200 is 2026-11-09 08:00:00 UTC",
   "kind": "30-utc-seconds",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "utc": "2026-11-09 08:00:00"
   },
   "expected": {
    "seconds": "1794211200"
   }
  },
  {
   "id": "30-4a-bounds",
   "chapter": "30",
   "section": "4a",
   "title": "The clock bounds",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "production_stops_above_seconds": "7",
    "handshake_fails_above_seconds": "600"
   }
  },
  {
   "id": "30-4b-pinned",
   "chapter": "30",
   "section": "4b",
   "title": "The TestNet spine genesis pin on a TestNet node",
   "kind": "30-spine-pin",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "line": "0 7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "stored_hash": "7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "auto_resync": "true",
    "marker_present": "false"
   },
   "expected": {
    "pinned": "true",
    "height": "0",
    "hash": "7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "warning": "false",
    "conflict": "false",
    "marker_written": "false",
    "starts": "true"
   }
  },
  {
   "id": "30-4b-rebuilt-timestamp",
   "chapter": "30",
   "section": "4b",
   "title": "The shipped pin on a node whose genesis was rebuilt on another timestamp without the pin re-derived",
   "kind": "30-spine-pin",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "line": "0 7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "stored_hash": "81BEAC4CE216D6949A442A9E0206791771417E879646B8183FE1E8779DC1E38A",
    "auto_resync": "true",
    "marker_present": "false"
   },
   "expected": {
    "pinned": "true",
    "conflict": "true",
    "marker_written": "true",
    "starts": "false"
   },
   "note": "The stored spine block 0 is the one built on 1,794,211,200; auto_resync is on."
  },
  {
   "id": "30-4b-conflict-resync",
   "chapter": "30",
   "section": "4b",
   "title": "The pin with its last character changed, auto_resync on: the marker is written, the node stops",
   "kind": "30-spine-pin",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "line": "0 7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545D",
    "stored_hash": "7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "auto_resync": "true",
    "marker_present": "false"
   },
   "expected": {
    "pinned": "true",
    "conflict": "true",
    "marker_written": "true",
    "starts": "false"
   }
  },
  {
   "id": "30-4b-conflict-off",
   "chapter": "30",
   "section": "4b",
   "title": "The same with auto_resync off: the node exits",
   "kind": "30-spine-pin",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "line": "0 7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545D",
    "stored_hash": "7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "auto_resync": "false",
    "marker_present": "false"
   },
   "expected": {
    "conflict": "true",
    "marker_written": "false",
    "starts": "false"
   }
  },
  {
   "id": "30-4b-conflict-marker",
   "chapter": "30",
   "section": "4b",
   "title": "The same with a marker already there: the node exits, no new marker",
   "kind": "30-spine-pin",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "line": "0 7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545D",
    "stored_hash": "7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "auto_resync": "true",
    "marker_present": "true"
   },
   "expected": {
    "conflict": "true",
    "marker_written": "false",
    "starts": "false"
   }
  },
  {
   "id": "30-4b-malformed",
   "chapter": "30",
   "section": "4b",
   "title": "The line 12 7CD9: no pin",
   "kind": "30-spine-pin",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "line": "12 7CD9",
    "stored_hash": "7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "auto_resync": "true",
    "marker_present": "false"
   },
   "expected": {
    "pinned": "false",
    "warning": "false",
    "starts": "true"
   },
   "note": "A hash of another length than 64 characters is not read: no pin, nothing logged."
  },
  {
   "id": "30-4b-not-hex",
   "chapter": "30",
   "section": "4b",
   "title": "64 characters that are not hex: a warning, no pin",
   "kind": "30-spine-pin",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "line": "12 ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ",
    "stored_hash": "7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C",
    "auto_resync": "true",
    "marker_present": "false"
   },
   "expected": {
    "pinned": "false",
    "warning": "true",
    "starts": "true"
   }
  },
  {
   "id": "30-4c-clock-ahead",
   "chapter": "30",
   "section": "4c",
   "title": "A node whose clock is 700 s ahead: its calls and its handshakes are refused",
   "kind": "30-clock-skew",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "offset": "700",
    "method": "Heartbeat"
   },
   "expected": {
    "call_status": "UNAUTHENTICATED",
    "call": "Heartbeat: signed request timestamp outside the 600 s window; check NTP",
    "handshake": "handshake timestamp out of window: your clock is +700 s from ours (limit 600 s); check NTP"
   }
  },
  {
   "id": "30-4c-clock-within",
   "chapter": "30",
   "section": "4c",
   "title": "A clock 599 s behind is still inside the window",
   "kind": "30-clock-skew",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "offset": "-599",
    "method": "Heartbeat"
   },
   "expected": {
    "call_status": "OK",
    "call": "accepted",
    "handshake": "accepted"
   }
  },
  {
   "id": "30-4c-nine-behind-one",
   "chapter": "30",
   "section": "4c",
   "title": "Nine unregistered nodes behind 203.0.113.7 handshake with one peer: the ninth is refused",
   "kind": "30-handshake-hosts",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "handshakes": "203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001\n203.0.113.7 203.0.113.7:8001"
   },
   "expected": {
    "hosts": "203.0.113.7\n203.0.113.7\n203.0.113.7\n203.0.113.7\n203.0.113.7\n203.0.113.7\n203.0.113.7\n203.0.113.7\n203.0.113.7",
    "results": "stored 203.0.113.7:8001\nstored 203.0.113.7:8001\nstored 203.0.113.7:8001\nstored 203.0.113.7:8001\nstored 203.0.113.7:8001\nstored 203.0.113.7:8001\nstored 203.0.113.7:8001\nstored 203.0.113.7:8001\nToo many unregistered peers from host 203.0.113.7"
   }
  },
  {
   "id": "30-4c-ipv6-one-host",
   "chapter": "30",
   "section": "4c",
   "title": "Two unregistered nodes in one IPv6 /64 count against one host",
   "kind": "30-handshake-hosts",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "handshakes": "2001:db8:1:2:3:4:5:6 [2001:db8:1:2:3:4:5:6]:8001\n2001:db8:1:2:ffff::1 [2001:db8:1:2:ffff::1]:8001"
   },
   "expected": {
    "hosts": "2001:db8:1:2::/64\n2001:db8:1:2::/64",
    "results": "stored [2001:db8:1:2:3:4:5:6]:8001\nstored [2001:db8:1:2:ffff::1]:8001"
   }
  },
  {
   "id": "30-4c-behind-nat",
   "chapter": "30",
   "section": "4c",
   "title": "A node advertising 0.0.0.0:8001 behind NAT gets an entry with no address",
   "kind": "30-handshake-hosts",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "handshakes": "198.51.100.20 0.0.0.0:8001"
   },
   "expected": {
    "hosts": "198.51.100.20",
    "results": "stored with no address"
   },
   "note": "The peer never dials such an entry and never passes it on; the node syncs by its own calls."
  },
  {
   "id": "30-5-production-halt",
   "chapter": "30",
   "section": "5",
   "title": "A 0.6.1 node on the chain where bundle 602 is decided for height 56,000 stops producing there",
   "kind": "29-readiness-gate",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "registry": "11",
    "bundle": "602",
    "rules_at_zero": "true",
    "registered_at": "50000",
    "signals": "55300 K1\n55400 K2\n55500 K3\n55600 K4\n55700 K5\n55800 K6\n55998 K7\n55999 K8",
    "tip": "55999"
   },
   "expected": {
    "h_star": "56000",
    "halt": "FATAL: readiness for future rule bundle 602 observed from height 56000 and this binary carries bundle 601: block production stops at height 56000 (validation continues). Remedy: install the registered release of bundle 602 (the self-updater, or the release the registry lists), then restart"
   },
   "note": "The chain of 29 §4b: the node logs the line once per height from 56,000, does not produce, and keeps validating and syncing."
  },
  {
   "id": "30-5-streak-log-only",
   "chapter": "30",
   "section": "5",
   "title": "12 failed fork resolutions against 3 peers over 2,000 s, height frozen, no signed evidence",
   "kind": "30-wedge-streak",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "attempts": "0 P1 5000\n100 P2 5000\n200 P3 5000\n300 P1 5000\n400 P2 5000\n500 P3 5000\n600 P1 5000\n700 P2 5000\n800 P3 5000\n900 P1 5000\n1000 P2 5000\n2000 P3 5000",
    "evidence": "false",
    "auto_resync": "true"
   },
   "expected": {
    "log_lines": "1",
    "wedge": "false",
    "marker": "false"
   },
   "note": "Eleven failures in the first 1,000 s, the twelfth at 2,000 s: only the twelfth completes the streak."
  },
  {
   "id": "30-5-streak-evidence",
   "chapter": "30",
   "section": "5",
   "title": "The same streak with the fork resolver's beyond-bound verdict sets the wedge reason",
   "kind": "30-wedge-streak",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "attempts": "0 P1 5000\n100 P2 5000\n200 P3 5000\n300 P1 5000\n400 P2 5000\n500 P3 5000\n600 P1 5000\n700 P2 5000\n800 P3 5000\n900 P1 5000\n1000 P2 5000\n2000 P3 5000",
    "evidence": "true",
    "auto_resync": "true"
   },
   "expected": {
    "log_lines": "0",
    "wedge": "true",
    "marker": "true"
   }
  },
  {
   "id": "30-5-cadences",
   "chapter": "30",
   "section": "5",
   "title": "The daemon loop's cadences",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "selection_seconds": "1",
    "main_loop_seconds": "1",
    "registration_refresh_seconds": "5",
    "candidate_attempt_seconds": "10",
    "deferred_spine_checks_seconds": "10",
    "newer_release_notice_blocks": "5760",
    "peer_ahead_window_seconds": "120",
    "chain_lock_wait_seconds": "30",
    "streak": "10 failed resolutions, 2 peers, 1800 s, at most once per 86400 s"
   }
  },
  {
   "id": "30-6-layout",
   "chapter": "30",
   "section": "6",
   "title": "Where a node with db_path = /var/lib/zoobc/blockchain.db keeps its files",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "markers": "/var/lib/zoobc/",
    "snapshots": "$HOME/.zoobc/snapshots/",
    "log": "log_path",
    "wedged_kept_days": "7"
   }
  },
  {
   "id": "30-7-hour",
   "chapter": "30",
   "section": "7",
   "title": "One hour of a registered node's peer loops",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "heartbeat_cycles": "120",
    "sync_passes": "about 360",
    "discovery_asks": "60",
    "announcement_rounds": "120"
   }
  },
  {
   "id": "30-8-archival-disk",
   "chapter": "30",
   "section": "8",
   "title": "An archival node with 4 GB free and archive_min_disk_gb = 5",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "value": "the archival program is not started"
   }
  },
  {
   "id": "30-8-restart",
   "chapter": "30",
   "section": "8",
   "title": "Supervised child restarts and the service unit",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "child_restart_seconds": "2, 4, 8, 16, 30, 30, …",
    "unit_restart_seconds": "10",
    "unit_start_limit": "10 per 600 s",
    "open_files": "65536"
   }
  },
  {
   "id": "30-8a-response",
   "chapter": "30",
   "section": "8a",
   "title": "The message a gateway signs for {\"height\":0}",
   "kind": "30-gateway-response",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "method": "GET",
    "target": "/api/v1/blockchain/height",
    "time": "1794211200",
    "body": "{\"height\":0}",
    "key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "signature": "213271868213041dca35e28505d9e3ebf4d8ca31461df2ffba5f26895d84a49bb6cc2d6d3686cfaadbf51d705e2fbd334eb2de1308d90cffd83658af102a2103"
   },
   "expected": {
    "body_hash": "f947796a2d6baaae145426dc76446c7f400a6aef337b627885ad7b422d734628",
    "message": "5a42472d524553502d56310a4745540a2f6170692f76312f626c6f636b636861696e2f6865696768740a313739343231313230300af947796a2d6baaae145426dc76446c7f400a6aef337b627885ad7b422d734628",
    "digest": "f00b9bf1fc198ce9c4dab690eed03dcdf404b1816b2a4fa938faaba6802da2e1",
    "signature_valid": "true"
   },
   "note": "The 85-byte message. The key is a stand-in gateway key (the first key of the test mnemonic); the signature is over the digest."
  },
  {
   "id": "30-8a-body-changed",
   "chapter": "30",
   "section": "8a",
   "title": "The same answer with the body {\"height\":1}: the signature made over the first does not verify",
   "kind": "30-gateway-response",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "method": "GET",
    "target": "/api/v1/blockchain/height",
    "time": "1794211200",
    "body": "{\"height\":1}",
    "key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152",
    "signature": "213271868213041dca35e28505d9e3ebf4d8ca31461df2ffba5f26895d84a49bb6cc2d6d3686cfaadbf51d705e2fbd334eb2de1308d90cffd83658af102a2103"
   },
   "expected": {
    "digest": "577753ad4545a61823de61619ebb99dc852088580bef76a6ce9b12a0e9b12562",
    "signature_valid": "false"
   }
  },
  {
   "id": "30-8a-installer-63",
   "chapter": "30",
   "section": "8a",
   "title": "A gateway key of 63 characters is refused by the installer",
   "kind": "30-gateway-identity",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "installer_key": "51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d9"
   },
   "expected": {
    "error": "the gateway key must be 64 hex characters (got 63)"
   }
  },
  {
   "id": "30-8a-installer-not-hex",
   "chapter": "30",
   "section": "8a",
   "title": "A gateway key with a character that is not hex is refused by the installer",
   "kind": "30-gateway-identity",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "installer_key": "51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d9g"
   },
   "expected": {
    "error": "the gateway key must be 64 hex characters (got a non-hex character)"
   }
  },
  {
   "id": "30-8a-file",
   "chapter": "30",
   "section": "8a",
   "title": "The gateway reads its key from the identity file and signs",
   "kind": "30-gateway-identity",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "file": "# ZooBC gateway identity (ZBG).\nGATEWAY_KEY=51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\n"
   },
   "expected": {
    "signed": "true",
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152"
   }
  },
  {
   "id": "30-8a-file-quoted",
   "chapter": "30",
   "section": "8a",
   "title": "A quoted value with a carriage return is read the same",
   "kind": "30-gateway-identity",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "file": "  GATEWAY_KEY=\"51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d96\"\r\n"
   },
   "expected": {
    "signed": "true",
    "public_key": "5e8eb28dccaa94a992f7169fa67966207d96aa55df7d24d2d6ec1f538c9f2152"
   }
  },
  {
   "id": "30-8a-file-63",
   "chapter": "30",
   "section": "8a",
   "title": "A GATEWAY_KEY= value of 63 characters written by hand: the gateway runs unsigned",
   "kind": "30-gateway-identity",
   "validity": "invalid",
   "source": "computed",
   "inputs": {
    "file": "# ZooBC gateway identity (ZBG).\nGATEWAY_KEY=51bae95d58f32304a5c9d894819989a4fb04da6115d9a43612a026e7a5dd5d9\n"
   },
   "expected": {
    "signed": "false"
   }
  },
  {
   "id": "30-9-slots",
   "chapter": "30",
   "section": "9",
   "title": "11 registered keys, pace 2, no authority pace",
   "kind": "30-update-slots",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "registered": "11",
    "pace": "2",
    "authority_pace": "",
    "min_window": "240"
   },
   "expected": {
    "window": "240",
    "slots": "0\n21\n43\n65\n87\n109\n130\n152\n174\n196\n218"
   }
  },
  {
   "id": "30-9-authority-pace",
   "chapter": "30",
   "section": "9",
   "title": "11 registered keys, the authority's pace 2: the window is exact",
   "kind": "30-update-slots",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "registered": "11",
    "pace": "2",
    "authority_pace": "2",
    "min_window": "240"
   },
   "expected": {
    "window": "6",
    "slots": "0\n0\n1\n1\n2\n2\n3\n3\n4\n4\n5"
   }
  },
  {
   "id": "30-9-slow-pace",
   "chapter": "30",
   "section": "9",
   "title": "11 registered keys, the authority's pace 0.1 (one node every 10 blocks)",
   "kind": "30-update-slots",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "registered": "11",
    "pace": "2",
    "authority_pace": "0.1",
    "min_window": "240"
   },
   "expected": {
    "window": "110",
    "slots": "0\n10\n20\n30\n40\n50\n60\n70\n80\n90\n100"
   }
  },
  {
   "id": "30-9-updater",
   "chapter": "30",
   "section": "9",
   "title": "The updater's timer and defaults",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "first_run": "15 min after boot",
    "period": "10 min ± 2 min",
    "delay_testnet_blocks": "11520",
    "delay_devnet_blocks": "120",
    "window_minimum_blocks": "240",
    "nodes_per_block": "2 (0.01 … 50)",
    "retry_hours": "12",
    "rebuild_at_most_every_seconds": "86400"
   }
  },
  {
   "id": "30-9a-relaunch-genesis",
   "chapter": "30",
   "section": "9a",
   "title": "The relaunch release built aside: its block 0 hashes to the genesis the gateway serves",
   "kind": "06-genesis-hash",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "timestamp": "1793509027",
    "config_hash": "b4d46ec1c521cbd143109591bdc5188c76e120779a048f858a5b2c29125ab381"
   },
   "expected": {
    "genesis_hash": "3A2897E7C5AD6143429BAB33A92D14D11FFD6FC281F2B62A6FD6B49C183B863D"
   },
   "note": "Built from the shipped TestNet files on their own timestamp; it equals the gateway's block 0, so the install goes on."
  },
  {
   "id": "30-9a-relaunch-pin",
   "chapter": "30",
   "section": "9a",
   "title": "The release's spine pin names spine block 0 of those files",
   "kind": "06-spine-genesis",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "blocksmiths": "ZNK_AKSQOGOA_DU5YCAYN_LO4GNMS6_NHYVM2G6_CULAXJI3_IPGQYGZV_FSRL4CNJ\nZNK_K6HRYARU_J53UJZ4E_JNVJVRK5_NE6TBKMA_HAQAE6BS_4ILZZDNI_RZROSENN\nZNK_M2RLFRTV_MWHLGJ4Y_F4HMOU45_4GVVD5JI_2WDP6L4T_QGX2CX4G_5N7EBXNW\nZNK_NONKLR6K_P4I4GKZ3_Y3QAMVYT_DGTVEGVK_I4XTYQRP_KJRG4SGD_QM7KMOED\nZNK_NTCBXDPZ_MGXSYD7A_LPQQ2MUI_7EYWDNJI_FWBXU24D_A75EC54P_DTRJCBCV\nZNK_OFPKRYXV_DO6LO6FC_NZU5OO6R_ARH6HJB5_O3FRZ5WL_YOU2MYNC_7OWAOVEQ\nZNK_QHQ776AK_Z7IM5FCA_QOB4VUHF_YUKBQKMY_XWI6S5FQ_REXZZSH6_H3OYYGWA\nZNK_U7UJWJNS_JQIRMXDI_MQNO7PTF_FGD526MM_ACHC74E6_FGGFPICI_4Y2DHPIO\nZNK_5OE7LAMS_BSWJGQ3G_HIZZCHLW_Z324RE4Q_6JMGKZI5_SATZFOEB_VVSQ7LVF\nZNK_6RBPKBET_FUKVULLK_GFFWNLDC_LXWYY32Q_346DWOFR_XVRNFHYN_6VTGYG62\nZNK_6VUSWJU6_MMR76BYH_QUCWOHOK_UTHUBIDV_GQR5ALCU_5SNRCCLX_ZXJ4PHV6",
    "timestamp": "1793509027",
    "version": "1"
   },
   "expected": {
    "block_hash": "7cd929c4d52d9c9455ed179d24a65f90ecbf3d1a3e1214a19611635791b3545c"
   }
  },
  {
   "id": "30-9a-relaunch-install",
   "chapter": "30",
   "section": "9a",
   "title": "A TestNet node holding another chain X, given that release",
   "kind": "reference",
   "validity": "valid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "value": "X differs from the new block 0: the old database is discarded and the node starts on the new block 0 with the spine pin 0 7CD929C4D52D9C9455ED179D24A65F90ECBF3D1A3E1214A19611635791B3545C"
   }
  },
  {
   "id": "30-9a-gateway-other-chain",
   "chapter": "30",
   "section": "9a",
   "title": "The same release from a gateway still serving X",
   "kind": "reference",
   "validity": "invalid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "error": "REFUSING to install: this release is not the chain at <gateway>",
    "written": "nothing"
   }
  },
  {
   "id": "30-9a-flip-genesis",
   "chapter": "30",
   "section": "9a",
   "title": "A flip to the launch timestamp T: every node builds the same genesis hash",
   "kind": "06-genesis-hash",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "timestamp": "1794211200",
    "config_hash": "b4d46ec1c521cbd143109591bdc5188c76e120779a048f858a5b2c29125ab381"
   },
   "expected": {
    "preimage": "0100000000000000807df16a000000000000000000000000000000000000000000000000000000000000000000000000b4d46ec1c521cbd143109591bdc5188c76e120779a048f858a5b2c29125ab381",
    "genesis_hash": "55e52151d7245d28e44c55368f111bb5995beac88362eec01e100e457302fc30"
   },
   "note": "T = 1,794,211,200 stands for the launch timestamp; the TestNet config hash is the shipped file's."
  },
  {
   "id": "30-9a-flip-pin",
   "chapter": "30",
   "section": "9a",
   "title": "And every node's spine pin is rewritten to spine block 0 built on T",
   "kind": "06-spine-genesis",
   "validity": "valid",
   "source": "computed",
   "inputs": {
    "blocksmiths": "ZNK_AKSQOGOA_DU5YCAYN_LO4GNMS6_NHYVM2G6_CULAXJI3_IPGQYGZV_FSRL4CNJ\nZNK_K6HRYARU_J53UJZ4E_JNVJVRK5_NE6TBKMA_HAQAE6BS_4ILZZDNI_RZROSENN\nZNK_M2RLFRTV_MWHLGJ4Y_F4HMOU45_4GVVD5JI_2WDP6L4T_QGX2CX4G_5N7EBXNW\nZNK_NONKLR6K_P4I4GKZ3_Y3QAMVYT_DGTVEGVK_I4XTYQRP_KJRG4SGD_QM7KMOED\nZNK_NTCBXDPZ_MGXSYD7A_LPQQ2MUI_7EYWDNJI_FWBXU24D_A75EC54P_DTRJCBCV\nZNK_OFPKRYXV_DO6LO6FC_NZU5OO6R_ARH6HJB5_O3FRZ5WL_YOU2MYNC_7OWAOVEQ\nZNK_QHQ776AK_Z7IM5FCA_QOB4VUHF_YUKBQKMY_XWI6S5FQ_REXZZSH6_H3OYYGWA\nZNK_U7UJWJNS_JQIRMXDI_MQNO7PTF_FGD526MM_ACHC74E6_FGGFPICI_4Y2DHPIO\nZNK_5OE7LAMS_BSWJGQ3G_HIZZCHLW_Z324RE4Q_6JMGKZI5_SATZFOEB_VVSQ7LVF\nZNK_6RBPKBET_FUKVULLK_GFFWNLDC_LXWYY32Q_346DWOFR_XVRNFHYN_6VTGYG62\nZNK_6VUSWJU6_MMR76BYH_QUCWOHOK_UTHUBIDV_GQR5ALCU_5SNRCCLX_ZXJ4PHV6",
    "timestamp": "1794211200",
    "version": "1"
   },
   "expected": {
    "block_hash": "81beac4ce216d6949a442a9e0206791771417e879646b8183fe1e8779dc1e38a"
   }
  },
  {
   "id": "30-9a-repair-mismatch",
   "chapter": "30",
   "section": "9a",
   "title": "The repair mode given a timestamp that is not the chain's, on a node pinned at 0 7CD929C4…545C",
   "kind": "reference",
   "validity": "invalid",
   "source": "computed",
   "inputs": {},
   "expected": {
    "error": "the spine pin does not name the genesis just built: <T> is not this chain's genesis timestamp.",
    "node": "left stopped",
    "pin": "unchanged"
   }
  }
 ]
}
