Skip to content

Releases: cashubtc/nutshell

0.16.0

25 Jul 10:06
125ce9e
Compare
Choose a tag to compare

This is major release comes with a ton of new features, bug fixes, performance improvements, and protocol updates. We have a new binary token format that is smaller, the wallet got a lot smarter with coin selection, the nutshell mint and wallet now support ecash fees, WebSocket updates, Multinut payments, and much more.

This release includes a database migration for the mint. Make sure to back up your mint database before upgrading.

New features

New binary token format

The Cashu protocol introduced a new binary Cashu TokenV4 format (with prefix cashuB) that saves around 40% space compared to the previous token format (with prefix cashuA). The Nutshell wallet will produce TokenV4 tokens by default now. To produce tokens with the old format, you can use the command cashu send --legacy <amount> (or -l for short). If you created a new token already but you'd like to see the legacy version of it, enter cashu pending -l.

Offline wallet and improved coin selection

The Nutshell wallet is now equipped with a vastly improved coin selection algorithm that allows the user to make as many transactions offline as possible while also saving on future fees by avoiding swaps with the mint as much as possible. This improves the utility, speed, and privacy of the Nutshell wallet, as it requires less communication with the mint.

Ecash fees

Nutshell now supports fees for Ecash transactions according to changes in NUT-02. Fees are determined by the number of Ecash inputs to a transaction. Fees are given in parts per thousand (ppk). As an example, if the fee is set to 250 ppk (in Satoshis), a transaction spending 4 inputs will require 1 sat in fees. Mints can enable fees by setting MINT_INPUT_FEE_PPK to an integer value in parts per thousand. Fees will only affect newly generated keysets, not old ones.

Warning: Wallet support for fees is still in active development. Enabling fees will break compatibility with most wallets in their current state. Mint operators should enable fees later in the future when there is widespread support for fees.

WebSocket subscriptions

The Cashu protocol recently introduced WebSocket subscriptions in NUT-17 which allows wallets to get notifications for state changes of mint quotes, melt quotes, and ecash spent states and the witness used for unlocking a locked token. The Nutshell mint can now receive subscription requests and send out updates to its clients. For the Nutshell wallet, this improves the responsiveness when minting new tokens as it does not require constant polling anymore. This feature will also improve the execution of smart contracts that require a timely retrieval of the witness used to unlock a token (for example when making atomic swaps against Lightning payments).

Multinut payments

The Nutshell mint now supports Multinut payments with the LND backend (see NUT-15). This feature is still experimental. To enable it, set the env variable MINT_LND_ENABLE_MPP=TRUE. To initiate a partial payment with the Nutshell wallet, use cashu pay <invoice> <amount> where <amount> is the partial amount you want the mint to send. You can initiate partial payments from different mints by repeating this command with different mints that support this feature.

Getting ready for the cloud

A lot of work has been made to extract all state of the mint from the system's memory into the database. These are preparations for making Nutshell ready for parallel deployments in a Kubernetes cluster so that multiple instances of the mint can run on top of the same database. This will allow scaling Nutshell to process many more transactions than what was previously possible.

Support for EUR

We added initial support for Euro Ecash using the StrikeWallet backend for Strike users who have access to Euro balances. FakeWallet now also supports the Euro.

Support for CLN Rest

A new CLNRestWallet backend was added that now supports CLN through the clnrest.py plugin. Previously, CLN was only supported through the c-lightning-rest third party interface for which we will phase out support through the CoreLightningRestWallet.

Protocol updates

NUT-04 and NUT-5 state fields

Mint and melt quotes now have a new state enum field that represents the state of the quote (PR) to reflect changes in the corresponding NUT-04 and NUT-05 specifications.

What's Changed

New Contributors

Full Changelog: 0.15.3...0.16.0

0.16.0-rc3

24 Jul 05:19
125ce9e
Compare
Choose a tag to compare
0.16.0-rc3 Pre-release
Pre-release

This is a huge major release with tons of new features, bug fixes, performance improvements, and protocol updates. We have a new binary token format that is smaller, the wallet got a lot smarter with coin selection, the nutshell mint and wallet now support ecash fees, WebSocket updates, Multinut payments, and so much more.

This release includes a database migration for the mint. Make sure to back up your mint database before upgrading.

New features

New binary token format

The Cashu protocol introduced a new binary Cashu TokenV4 format (with prefix cashuB) that saves around 40% space compared to the previous token format (with prefix cashuA). The Nutshell wallet will produce TokenV4 tokens by default now. To produce tokens with the old format, you can use the command cashu send --legacy <amount> (or -l for short). If you created a new token already but you'd like to see the legacy version of it, enter cashu pending -l.

Offline wallet and improved coin selection

The Nutshell wallet is now equipped with a vastly improved coin selection algorithm that allows the user to make as many transactions offline as possible while also saving on future fees by avoiding swaps with the mint as much as possible. This improves the utility, speed, and privacy of the Nutshell wallet, as it requires less communication with the mint.

Ecash fees

Nutshell now supports fees for Ecash transactions according to changes in NUT-02. Fees are determined by the number of Ecash inputs to a transaction. Fees are given in parts per thousand (ppk). As an example, if the fee is set to 250 ppk (in Satoshis), a transaction spending 4 inputs will require 1 sat in fees. Mints can enable fees by setting MINT_INPUT_FEE_PPK to an integer value in parts per thousand. Fees will only affect newly generated keysets, not old ones.

Warning: Wallet support for fees is still in active development. Enabling fees will break compatibility with most wallets in their current state. Mint operators should enable fees later in the future when there is widespread support for fees.

WebSocket subscriptions

The Cashu protocol recently introduced WebSocket subscriptions in NUT-17 which allows wallets to get notifications for state changes of mint quotes, melt quotes, and ecash spent states and the witness used for unlocking a locked token. The Nutshell mint can now receive subscription requests and send out updates to its clients. For the Nutshell wallet, this improves the responsiveness when minting new tokens as it does not require constant polling anymore. This feature will also improve the execution of smart contracts that require a timely retrieval of the witness used to unlock a token (for example when making atomic swaps against Lightning payments).

Multinut payments

The Nutshell mint now supports Multinut payments with the LND backend (see NUT-15). This feature is still experimental. To enable it, set the env variable MINT_LND_ENABLE_MPP=TRUE. To initiate a partial payment with the Nutshell wallet, use cashu pay <invoice> <amount> where <amount> is the partial amount you want the mint to send. You can initiate partial payments from different mints by repeating this command with different mints that support this feature.

Getting ready for the cloud

A lot of work has been made to extract all state of the mint from the system's memory into the database. These are preparations for making Nutshell ready for parallel deployments in a Kubernetes cluster so that multiple instances of the mint can run on top of the same database. This will allow scaling Nutshell to process many more transactions than what was previously possible.

Support for EUR

We added initial support for Euro Ecash using the StrikeWallet backend for Strike users who have access to Euro balances. FakeWallet now also supports the Euro.

Support for CLN Rest

A new CLNRestWallet backend was added that now supports CLN through the clnrest.py plugin. Previously, CLN was only supported through the c-lightning-rest third party interface for which we will phase out support through the CoreLightningRestWallet.

Protocol updates

NUT-04 and NUT-5 state fields

Mint and melt quotes now have a new state enum field that represents the state of the quote (PR) to reflect changes in the corresponding NUT-04 and NUT-05 specifications.

What's Changed

New Contributors

Full Changelog: 0.15.3...0.16.0-rc1

What's Changed

Full Changelog: 0.16.0-rc1...0.16.0-rc2

What's Changed

Full Changelog: 0.16.0-rc2...0.16.0

0.16.0-rc2

17 Jul 12:18
040ee12
Compare
Choose a tag to compare
0.16.0-rc2 Pre-release
Pre-release

This is a huge major release with tons of new features, bug fixes, performance improvements, and protocol updates. We have a new binary token format that is smaller, the wallet got a lot smarter with coin selection, the nutshell mint and wallet now support ecash fees, WebSocket updates, Multinut payments, and so much more.

This release includes a database migration for the mint. Make sure to back up your mint database before upgrading.

New features

New binary token format

The Cashu protocol introduced a new binary Cashu TokenV4 format (with prefix cashuB) that saves around 40% space compared to the previous token format (with prefix cashuA). The Nutshell wallet will produce TokenV4 tokens by default now. To produce tokens with the old format, you can use the command cashu send --legacy <amount> (or -l for short). If you created a new token already but you'd like to see the legacy version of it, enter cashu pending -l.

Offline wallet and improved coin selection

The Nutshell wallet is now equipped with a vastly improved coin selection algorithm that allows the user to make as many transactions offline as possible while also saving on future fees by avoiding swaps with the mint as much as possible. This improves the utility, speed, and privacy of the Nutshell wallet, as it requires less communication with the mint.

Ecash fees

Nutshell now supports fees for Ecash transactions according to changes in NUT-02. Fees are determined by the number of Ecash inputs to a transaction. Fees are given in parts per thousand (ppk). As an example, if the fee is set to 250 ppk (in Satoshis), a transaction spending 4 inputs will require 1 sat in fees. Mints can enable fees by setting MINT_INPUT_FEE_PPK to an integer value in parts per thousand. Fees will only affect newly generated keysets, not old ones.

Warning: Wallet support for fees is still in active development. Enabling fees will break compatibility with most wallets in their current state. Mint operators should enable fees later in the future when there is widespread support for fees.

WebSocket subscriptions

The Cashu protocol recently introduced WebSocket subscriptions in NUT-17 which allows wallets to get notifications for state changes of mint quotes, melt quotes, and ecash spent states and the witness used for unlocking a locked token. The Nutshell mint can now receive subscription requests and send out updates to its clients. For the Nutshell wallet, this improves the responsiveness when minting new tokens as it does not require constant polling anymore. This feature will also improve the execution of smart contracts that require a timely retrieval of the witness used to unlock a token (for example when making atomic swaps against Lightning payments).

Multinut payments

The Nutshell mint now supports Multinut payments with the LND backend (see NUT-15). This feature is still experimental. To enable it, set the env variable MINT_LND_ENABLE_MPP=TRUE. To initiate a partial payment with the Nutshell wallet, use cashu pay <invoice> <amount> where <amount> is the partial amount you want the mint to send. You can initiate partial payments from different mints by repeating this command with different mints that support this feature.

Getting ready for the cloud

A lot of work has been made to extract all state of the mint from the system's memory into the database. These are preparations for making Nutshell ready for parallel deployments in a Kubernetes cluster so that multiple instances of the mint can run on top of the same database. This will allow scaling Nutshell to process many more transactions than what was previously possible.

Support for EUR

We added initial support for Euro Ecash using the StrikeWallet backend for Strike users who have access to Euro balances. FakeWallet now also supports the Euro.

Support for CLN Rest

A new CLNRestWallet backend was added that now supports CLN through the clnrest.py plugin. Previously, CLN was only supported through the c-lightning-rest third party interface for which we will phase out support through the CoreLightningRestWallet.

Protocol updates

NUT-04 and NUT-5 state fields

Mint and melt quotes now have a new state enum field that represents the state of the quote (PR) to reflect changes in the corresponding NUT-04 and NUT-05 specifications.

What's Changed

New Contributors

Full Changelog: 0.15.3...0.16.0-rc1

What's Changed

Full Changelog: 0.16.0-rc1...0.16.0-rc2

0.16.0-rc1

16 Jul 09:16
21f339c
Compare
Choose a tag to compare
0.16.0-rc1 Pre-release
Pre-release

This is a huge major release with tons of new features, bug fixes, performance improvements, and protocol updates. We have a new binary token format that is smaller, the wallet got a lot smarter with coin selection, the nutshell mint and wallet now support ecash fees, WebSocket updates, Multinut payments, and so much more.

This release includes a database migration for the mint. Make sure to back up your mint database before upgrading.

New features

New binary token format

The Cashu protocol introduced a new binary Cashu TokenV4 format (with prefix cashuB) that saves around 40% space compared to the previous token format (with prefix cashuA). The Nutshell wallet will produce TokenV4 tokens by default now. To produce tokens with the old format, you can use the command cashu send --legacy <amount> (or -l for short). If you created a new token already but you'd like to see the legacy version of it, enter cashu pending -l.

Offline wallet and improved coin selection

The Nutshell wallet is now equipped with a vastly improved coin selection algorithm that allows the user to make as many transactions offline as possible while also saving on future fees by avoiding swaps with the mint as much as possible. This improves the utility, speed, and privacy of the Nutshell wallet, as it requires less communication with the mint.

Ecash fees

Nutshell now supports fees for Ecash transactions according to changes in NUT-02. Fees are determined by the number of Ecash inputs to a transaction. Fees are given in parts per thousand (ppk). As an example, if the fee is set to 250 ppk (in Satoshis), a transaction spending 4 inputs will require 1 sat in fees. Mints can enable fees by setting MINT_INPUT_FEE_PPK to an integer value in parts per thousand. Fees will only affect newly generated keysets, not old ones.

Warning: Wallet support for fees is still in active development. Enabling fees will break compatibility with most wallets in their current state. Mint operators should enable fees later in the future when there is widespread support for fees.

WebSocket subscriptions

The Cashu protocol recently introduced WebSocket subscriptions in NUT-17 which allows wallets to get notifications for state changes of mint quotes, melt quotes, and ecash spent states and the witness used for unlocking a locked token. The Nutshell mint can now receive subscription requests and send out updates to its clients. For the Nutshell wallet, this improves the responsiveness when minting new tokens as it does not require constant polling anymore. This feature will also improve the execution of smart contracts that require a timely retrieval of the witness used to unlock a token (for example when making atomic swaps against Lightning payments).

Multinut payments

The Nutshell mint now supports Multinut payments with the LND backend (see NUT-15). This feature is still experimental. To enable it, set the env variable MINT_LND_ENABLE_MPP=TRUE. To initiate a partial payment with the Nutshell wallet, use cashu pay <invoice> <amount> where <amount> is the partial amount you want the mint to send. You can initiate partial payments from different mints by repeating this command with different mints that support this feature.

Getting ready for the cloud

A lot of work has been made to extract all state of the mint from the system's memory into the database. These are preparations for making Nutshell ready for parallel deployments in a Kubernetes cluster so that multiple instances of the mint can run on top of the same database. This will allow scaling Nutshell to process many more transactions than what was previously possible.

Support for EUR

We added initial support for Euro Ecash using the StrikeWallet backend for Strike users who have access to Euro balances. FakeWallet now also supports the Euro.

Support for CLN Rest

A new CLNRestWallet backend was added that now supports CLN through the clnrest.py plugin. Previously, CLN was only supported through the c-lightning-rest third party interface for which we will phase out support through the CoreLightningRestWallet.

Protocol updates

NUT-04 and NUT-6 state fields

Mint and melt quotes now have a new state enum field that represents the state of the quote (PR) to reflect changes in the corresponding NUT-04 and NUT-05 specifications.

What's Changed

New Contributors

Full Changelog: 0.15.3...0.16.0-rc1

0.15.3

19 Apr 10:12
72ad903
Compare
Choose a tag to compare

What's Changed

This release includes a database migration for the mint. Make sure to back up your mint database before upgrading.

This update improves the crash resistance of a mint. If the mint should fail during an outgoing Lightning payment, the startup routine will now pick up those payments and invalidate all pending proofs associated with them if the payment succeeded.

The wallet can now check pending invoices thanks to work by @Guilospanck using the command cashu invoices. Various flags have been added to the command which you can see using cashu invoices --help. The wallet can now also restore ecash from all keysets of a mint with the command cashu restore thanks to an improvement by @cjbeery24.

Wallet changes

Mint changes

New Contributors

Full Changelog: 0.15.2...0.15.3

0.15.2

26 Mar 21:02
4ff9e6d
Compare
Choose a tag to compare

This update introduces a built-in rate limiter to the mint. It also includes multiple improvements for automated testing of USD backends and various other stability updates and bug fixes.

Mint

  • Mint: Add Slowapi rate limiter by @callebtc in #481
  • Mint: FakeWallet support for USD by @callebtc in #488
  • Set sat and usd wallets separately in .env (MINT_BACKEND_BOLT11_SAT, MINT_BACKEND_BOLT11_USD)
    • Note: This deprecates the old .env variable MINT_LIGHTNING_BACKEND
  • Fix: CLNRestWallet (tested with c-lightning:24.02.1 and c-lightning-rest:0.10.7) by @callebtc in #494

NUTs

Full Changelog: 0.15.1...0.15.2

0.15.1

17 Mar 12:31
30cdb81
Compare
Choose a tag to compare

This update introduces Blink as a Lightning backend for the mint and includes various other housekeeping items with smaller bug fixes.

This release includes a database migration for the mint. Make sure to back up your mint database before upgrading.

Mint

  • Add Blink as a Lightning funding source
  • Fix: Quote expiry with absolute Unix time
  • Fix: Catch CashuErrors and print them nicely
  • Fix: Do not check MeltQuote status before payment attempt
  • Fix: Mint seed encryption cashu/mint/encrypt.py

Wallet

  • Token invalidation: add setting for batch size

Protocol

New Contributors

0.15.0

15 Feb 17:38
ecad957
Compare
Choose a tag to compare

Nutshell upgrades to Cashu v1

The Cashu protocol has recently been updated to its first stable version. This release of Nutshell now supports the v1 protocol. The Cashu v1 protocol paves the way for Ecash with multiple denominations (sat, msat, usd, ...) and payment methods (Lightning, On-chain, ...). This update has been a long time in the making, with significant changes in the overall software architecture and several database migrations.

Mint runners: Always backup your mint database before upgrading.

With this release, Nutshell is also preparing for exciting upgrades in the future. These upgrades will enable you to run a Cashu mint with replication in a distributed cluster for highly available services and significantly increased throughput. Furthermore, a single deployment of a mint will be able to serve many "virtual mints" for different users.

Mint

  • New v1 API implementation with backwards compatibility. Old v0 wallets will keep working with the mint.
  • Mint can now rotate keysets by using BIP32 key derivation.
  • Each keyset can now have a separate seed from which it is generated.
  • Mint stores the seed for each keyset in the database. The seed can optionally be encrypted using a separate CLI tool cashu/mint/decrypt.py.
  • Fix P2PK multisig checks.
  • Supports database backups before future migrations via env var DB_BACKUP_PATH
  • New safety settings for limiting the maximum balance of the mint (MINT_MAX_BALANCE) and the maximum amount for mint (MINT_MAX_PEG_IN) and melt (MINT_MAX_PEG_OUT) requests.

Wallet

  • New v1 API implementation with backwards compatibility. The wallet will still work with old v0 mints.
  • Support for multiple denomination in the same wallet.
  • Many smaller issues fixed.

0.14.1

19 Dec 09:37
375b278
Compare
Choose a tag to compare

Updates in a Nutshell

  • Stateless Mint: Nutshell mint can now be run "stateless" meaning that all state is in the database. This is a step towards being able to run multiple mints workers in parallel for heavy load scenarios.
  • Max balance for mints: a new MINT_MAX_BALANCE environment flag makes sure that the mint can only hold a maximum amount.
  • CLI: Create an invoice without blocking with cashu invoice <amount> -n

What's Changed

Full Changelog: 0.14.0...0.14.1

0.14.0

14 Nov 19:39
286f850
Compare
Choose a tag to compare

Nutshell 0.14.0 brings many new features and improvements. These include a completely redesigned approach to use ecash spending conditions (programmable ecash) and the ability to transact offline (using offline signature validation). Protocol changes are according to the new specifications NUT-10, NUT-11, and NUT-12.

Protocol updates

Well-known spending conditions

Nutshell now supports NUT-10 spending conditions. This is a standardized way to create complex contracts between two Cashu users, if the mint supports a certain type of contract. One example is the P2PK implementation (see below).

Pay to Pubkey (P2PK)

P2PK allows you to lock a token to a specific pubkey. That way, only the intended receiver can redeem a token and nobody else. The recipient receives the token by providing a valid signature when redeeming it with the mint. The contract is enforced by the mint. To create a pubkey lock as a receiver, enter cashu lock. To send to this lock, the sender enters cashu send <amount> --lock <p2pk_lock_of_receiver>. This token can now be redeemed by the receiver. Read the specifications in NUT-11

DLEQ proofs

Discrete-log equality (DLEQ) proofs are now generated by the mint and handed over to wallets. Wallets can use these to verify the signature of the mint given their public key. Wallets can also send DLEQ proofs to other receiving wallets via cashu send --dleq <amount>. Receiving wallets will validate the DLEQ proof before redeeming the token via the mint. Read more information in the DLEQ PR and the specification in NUT-12.

Other Improvements

  • Wallet secret derivation fixed. Old tokens will not be restored with the new secret derivation. Use cashu selfpay to send yourself entire balance once.
  • cashu info now shows all mints
  • Wallet stores mint keysets for offline verification.
  • Mint DB with Postgres support
  • Include nostr submodule in project repo
  • Improve Docker pipeline for wallet and mint

All changes

Full Changelog: 0.13.0...0.14.0