Skip to content

Instantly share code, notes, and snippets.

@okjodom
Last active May 26, 2023 02:25
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save okjodom/c62308a7762541420b0b12d4d8688a87 to your computer and use it in GitHub Desktop.
Save okjodom/c62308a7762541420b0b12d4d8688a87 to your computer and use it in GitHub Desktop.
About Fedimint

What is Fedimint:

  • Bitcoin custody protocol. Here is a primer
  • most applicable in a community context

Personas in Fedimint

  • The guardians (aka. custodians, aka. federation members)
    • technical community members
    • runs a federation which holds funds on behalf of the community
    • jointly manage an onchain bitcoin wallet (threshold multisig)
    • coordinate through distributed consensus
  • The clients
    • users of a fedimint
    • benefit from shared custody and other functionality provided by the federation
    • join one / more fedimint federations from a client app like Fedi
    • guardians are also users!
  • The gateways
    • economic actors that provide lightning swap service to federations
    • bridge the fedimint federation instance, to the rest of the world via lightning
    • one gateway can serve any number of federations
    • future: There can be other variants of gateways
    • See community lightning workshop, btc++

Technology components of Fedimint

  • Ref
  • Distributed Consensus as the Federation
    • Federation guardians coordinate through Honey Badger Byzantine Fault Tolerant Consensus (HBBFT)
    • Each member guardian is running a node, that automatically takes part in the concensus cycles (epochs)
    • Each node in a federation is running the same set of Fedimint Modules (more on this, below)
  • Lightning Gateways
    • specialized to send/receive lightning payments on behalf of other clients in the fed
    • built on top of the Fedimint Lightning module.

Extensibility of Fedimints (Modules)

  • Extends functionality of Fedimints
  • Modules plug in to the fedimint consensus system,
    • define new transaction types
    • define new consensus rules
    • plugs into the same distributed consensus algorithm of Fedimint
  • Anyone can build a module :)
  • Default Modules
    • Wallet Module
    • Mint Module
      • blinded mint for generating e-cash
      • replaceable by any other desirable accounting system, say ZCash
    • Lightning Module
      • contracts for swapping between bitcoin, e-cash to/from lightning
  • Other Module Examples, see fedimint discussions

The Fedimint Flow

  • Community selects it's guardians
  • Guardians set up the federation
  • Someone adds a lightning gateway to the federation
    • multiple gateways can be added to a federation
  • All community members join the federation from their client app of choice
    • Fedi is the first of Fedimint user clients

Hands-on

Next-time

  • Set up a federation
  • Set up a fedimint gateway
  • Build a fedimint module

Look-ups

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment