Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
fa3a89d
Starting on a Spillman Channel
SatsAndSports Oct 15, 2025
6a9b31d
Step by step. Here, Bob has created his outputs, and the conditions h…
SatsAndSports Oct 17, 2025
b7495e9
SIG_ALL
SatsAndSports Oct 17, 2025
c954f63
prepare the locked outputs
SatsAndSports Oct 17, 2025
6db22c4
refund goes to Alice alone, not anyone-can-spend
SatsAndSports Oct 17, 2025
ae603e8
swapped. Now blind signatures from the mint.
SatsAndSports Oct 17, 2025
a8cc1f4
proofs fully prepared
SatsAndSports Oct 17, 2025
b821896
Some verification by Bob
SatsAndSports Oct 17, 2025
ae645fb
Bob checks DLEQ
SatsAndSports Oct 17, 2025
636b62b
Simplified a lot. Just 1 proof, and it's 1x1 multisig
SatsAndSports Oct 18, 2025
af337ec
2x2 working, and tested that both sigs really are needed. Still just …
SatsAndSports Oct 18, 2025
e4b9a93
Just one keyset is needed
SatsAndSports Oct 18, 2025
a17a05b
bob's outputs
SatsAndSports Oct 18, 2025
fc1a666
towards sig_all. Not fully working, but at least .verify_sig_all() is…
SatsAndSports Oct 18, 2025
88ef443
remove misleading comment
SatsAndSports Oct 18, 2025
6f88051
multiple proofs in a single SIG_ALL
SatsAndSports Oct 18, 2025
da2779d
second transaction, spending the other two proofs
SatsAndSports Oct 18, 2025
80ca45b
third transaction, which - as expected - fails
SatsAndSports Oct 18, 2025
f4e10de
create_swap_request_from_vector
SatsAndSports Oct 18, 2025
923700d
balance_to_spend_vector, to compute the boolean vector, and other ref…
SatsAndSports Oct 18, 2025
1afa83c
spillman refund to Alice fully working after the locktime has expired
SatsAndSports Oct 19, 2025
21805d1
Alice creates outputs in advance, and uses them in the refund. Next s…
SatsAndSports Oct 19, 2025
abfc74d
This is a combination of 5 commits:
SatsAndSports Oct 19, 2025
6c46dc9
Move Alice's outputs down. She doesn't need to commit to them in advance
SatsAndSports Oct 20, 2025
5674c32
Create a ChannelFixtures type, to store the complete channel-setup da…
SatsAndSports Oct 20, 2025
e392bd5
assert that the expected amount was spent
SatsAndSports Oct 20, 2025
e49783a
create_swap_request, with an amount instead of a spend vector
SatsAndSports Oct 20, 2025
a380d92
nice class for verifying the signature on each microtransaction
SatsAndSports Oct 20, 2025
1213767
fix wrong log message
SatsAndSports Oct 20, 2025
88e8636
get_signatures_from_swap_request
SatsAndSports Oct 20, 2025
4a48c9f
channel open announcement
SatsAndSports Oct 20, 2025
696f219
In a loop, with a nice 'BalanceUpdateMessage' class, and a method for…
SatsAndSports Oct 20, 2025
23842ad
get_sender_signed_swap_request method, for Bob to reconstruct the tra…
SatsAndSports Oct 20, 2025
edfbbff
storing the last balance update, and an intermediate one
SatsAndSports Oct 20, 2025
fe57f5d
remove the two existing 'manual' transactions, and instead Bob execut…
SatsAndSports Oct 20, 2025
1293136
Bob tries to cheat, and the mint stops him
SatsAndSports Oct 20, 2025
e7ee934
a bigger channel, tested with 1000 micropayments
SatsAndSports Oct 20, 2025
eb04319
A progress bar, so we can see the progres
SatsAndSports Oct 20, 2025
a6a288f
more transactions, and bigger locktime. Very happy now 😀
SatsAndSports Oct 20, 2025
7177764
simplify the refund demo
SatsAndSports Oct 20, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions crates/cdk/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,16 @@ required-features = ["wallet"]
name = "mint-token-bolt12"
required-features = ["wallet"]

[[example]]
name = "spillman_channel"
required-features = ["wallet", "mint"]

[dev-dependencies]
rand.workspace = true
cashu.workspace = true
cdk-sqlite.workspace = true
cdk-fake-wallet.workspace = true
cdk-common.workspace = true
bip39.workspace = true
tracing-subscriber.workspace = true
criterion.workspace = true
Expand Down
Loading