Decoding Bitcoin study cohort · free, Mondays on Discord · join anytime Sign up →

Developer fellowship · month 1 · Floresta

The unglamorous work that makes a Bitcoin node safe to run.

One month, one fellow, and a lock on Floresta's front door.

The unglamorous work that makes a Bitcoin node safe to run
2PRs merged
3more in review
4code reviews

stonepillar, our developer fellow, got two pull requests merged into Floresta in November. Floresta's control interface now requires a login, the same way Bitcoin Core's does, and the node keeps a log file by default.

Why a small node is a big deal

Bitcoin makes one promise that nothing else does: you don't have to trust anyone. You can check every rule yourself.

But checking means running a node, and a normal node wants hundreds of gigabytes of disk and days of syncing. So most people don't. They trust someone else's node, and the promise quietly turns back into "trust me".

Floresta is one of the projects trying to fix that. It's a Bitcoin node written in Rust, built on Utreexo, an idea from Tadge Dryja that squeezes the list of all unspent coins from gigabytes down to a few kilobytes. The result is a node light enough for an old laptop, a tiny home server, or to live inside a wallet app.

More people verifying for themselves means a Bitcoin that is harder to capture. That is what decentralization actually looks like: software that ordinary people can run.

From "it works" to "you can rely on it"

Clever ideas get the attention. But before people can depend on a node, somebody has to do the unglamorous part: logins, logs, and what happens when the power goes out.

That's what stonepillar worked on this month.

1. A lock on the front door merged 17 Nov

Every node has a control interface called RPC. Wallets and tools use it to ask the node questions and give it commands.

Until now, Floresta's RPC had no login. By default it only listened on your own machine, so it wasn't open to the internet. But any program on that computer could talk to it, and so could anyone on your network if you exposed the port, which is easy to do with Docker or a home server.

Now it works the way Bitcoin Core does:

  • A secret cookie file, created fresh on every start. This is the default, with nothing to set up.
  • A username and password, if you'd rather have one.
  • Several users, with passwords stored only as salted hashes, never as plain text.
  • A short delay after every wrong password, so nobody can sit there guessing.

Ten commits, with tests and documentation, reviewed over many rounds by Floresta's maintainers and reviewers. It closes a feature request that had been open on the project for a long time.

2. The node keeps a diary merged 13 Nov

When something breaks, the first question is always "what do the logs say?" Floresta now writes a debug.log by default, like Bitcoin Core, and accepts Core's own flag names so people coming from bitcoind feel at home.

Both pieces were on Floresta's roadmap for this quarter, and both shipped in Floresta v0.10.0, released this week.

3. Two bugs he caught on the way in review

  • A login cookie saved with an extra line break would lock you out.
  • A node killed in the middle of syncing could wake up confused about where it had stopped.

Neither was on his to-do list. He noticed them while doing the work, and fixed them.

He also sent a follow-up to the log file work: left alone the file would grow forever, so it now trims itself on startup.

4. Reviewing other people's code

Open source runs on review. He reviewed four pull requests from other Floresta contributors this month.

What the fellowship changed

The login work wasn't new in November. stonepillar opened that pull request on 1 June, as a volunteer, in his spare time.

What changed is time. The fellowship let him focus, work through every round of review with Floresta's maintainers and reviewers, and get it over the line.

This month Floresta also added him to its GitHub organization as a member. Open source projects do that for people whose work they have come to rely on.

"stonepillar is doing a good job. He is becoming increasingly familiar with the codebase and more confident in participating in review discussions, not just on his own PRs. I'm looking forward to more contributions from him."
Chris G., Floresta maintainer and stonepillar's mentor

That is the whole idea behind Code Orange. Find talented developers. Train them. Give them a community to belong to. And support them financially, so that good work doesn't stay half-finished because rent was due.

Next

  • Get the three open pull requests reviewed and merged.
  • Keep working on how the node handles its first sync.
  • Present his work live at our Code Review Club.

Developers: want to do this yourself? Apply for the fellowship.
Maintainers: have a project that could use a focused contributor? Mentor a fellow: hello@codeorange.dev

Bitcoin Only

Ready to become a Bitcoin builder?

Join the next cohort, drop into a workshop, or come say hello in Discord. The community is free and open.