Local-first
Salts come from your OS random generator and stay in a folder on your disk, optionally encrypted.
commitment0x0be1…40ab
stored at.twofold/records
Every rule is enforced by the contract and covered by unit, fuzz or invariant tests.
Salts come from your OS random generator and stay in a folder on your disk, optionally encrypted.
Announce, then reveal. A leaked key cannot swap the next commitment.
The CLI only prints calldata. Sign with cast, viem, ethers or a hardware wallet.
Check commitment, nonce, balance and any pending announcement before you spend gas.
One binary turns a record into exact calldata. It never signs and never sends.
$ twofold commit --depositor 0xYOU \ --recipient 0x…B0b0 --amount 1e18 …
Draws 32 random bytes, saves the record, prints the commitment.
$ twofold encode-withdraw \ --record r.json --next-amount 2e18 …
Prints the announcement and the reveal, writes the next record.
$ twofold status --record r.json ready_to_withdraw: yes
Read-only RPC. Flags stale records before they cost gas.
Short answers. The README has the long ones.
The funds behind that commitment cannot be withdrawn. There is no admin and no reset. Back up the .twofold folder offline.
Yes. A salt is single-use and bound to your address, nonce, vault and chain. Once mined, the vault has moved to the next commitment.
The announcement fixes the next commitment before the salt is public, so someone holding a leaked key cannot copy the salt and install their own.
No. It prints calldata and makes read-only RPC calls for status. You sign with the tool you trust.
Not yet. It is an MVP with unit, fuzz and invariant tests. Use testnets or amounts you are prepared to lose.
Any EVM chain with the Cancun upgrade. The target is Robinhood Chain.
A separate asset from the vault. The vault works without it, and nothing on this page is financial advice.
Build it, run the tests and read the contract before you deposit.