pretty-prints various bitcoin data structures
Find a file
2026-03-02 15:51:22 -05:00
block.go im bashing my head into a wall 2025-12-31 18:44:07 -05:00
expected.txt mminor optimizations 2025-09-23 11:19:03 -04:00
go.mod chore: update deps again 2026-03-02 15:51:22 -05:00
go.sum chore: update deps again 2026-03-02 15:51:22 -05:00
LICENSE gpl my beloved 2025-09-23 16:53:14 -04:00
main.go fix: something idk i forgot to commit this a month ago 2026-03-02 15:51:22 -05:00
README.MD chore: update deps again 2026-03-02 15:51:22 -05:00
showoff.png update showoff pic 2025-12-29 14:27:40 -05:00

xxbitcoin

pretty-prints various bitcoin data structures

kinda like fd but less technical and bitcoin-focused

Usage

xxbitcoin --type <data structure type> <hex-encoded structure>

it reads from stdin if not passed a string too

echo <hex-encoded structure> | xxbitcoin --type <data structure type>

pogolo coinbase script, displayed in ansi.tools

Features

  • decodes scripts, coinbase scripts, and block headers
  • pretty colors :3

Bugs

  • doesnt properly chunk all strings (errors tend to be tricky)
  • alignment isnt always perfect
  • like zero error handling (for now)

TODO

  • refactor to a more modular system
  • refactor chunking
    • always split around hex bytes in header
  • accept raw binary as input
  • decode transactions
    • decode txout destinations?
  • decode blocks
  • decode stratum v1 messages
  • decode stratum v2 messages
  • error handling
  • allow for different window sizes?