Skip to content

feat: enforce k_max limit (2323) for silent payments groups#31

Open
IsaqueFranklin wants to merge 1 commit into
BlueWallet:masterfrom
IsaqueFranklin:feat/kmax-limit
Open

feat: enforce k_max limit (2323) for silent payments groups#31
IsaqueFranklin wants to merge 1 commit into
BlueWallet:masterfrom
IsaqueFranklin:feat/kmax-limit

Conversation

@IsaqueFranklin
Copy link
Copy Markdown

This PR implements the K_MAX limit for the recipient group as specified in BIP-352.

According to the specification for creating outputs:
"If any of the groups exceed the limit of K_MAX (=2323) silent payment addresses, fail."

This PR includes the following changes:

  • Added K_MAX constant.
  • Added a fail-fast check for the recipient group size before performing any calculations.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant