Skip to content

translator_sv2: BIP323 version rolling mask - #656

Merged
plebhash merged 2 commits into
stratum-mining:mainfrom
plebhash:2026-07-31-bip323-sv1-api-translation
Aug 4, 2026
Merged

translator_sv2: BIP323 version rolling mask#656
plebhash merged 2 commits into
stratum-mining:mainfrom
plebhash:2026-07-31-bip323-sv1-api-translation

Conversation

@plebhash

@plebhash plebhash commented Jul 31, 2026

Copy link
Copy Markdown
Member

@plebhash plebhash changed the title translator: BIP323 version rolling mask translator_sv2: BIP323 version rolling mask Jul 31, 2026
@plebhash
plebhash marked this pull request as draft July 31, 2026 22:46
@plebhash
plebhash force-pushed the 2026-07-31-bip323-sv1-api-translation branch 4 times, most recently from fd2d031 to 8a6f1f9 Compare August 3, 2026 16:18

@GitGab19 GitGab19 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK

We can drop 8a6f1f9 and merge this one after the companion gets merged.

Use sv1_api::utils::VERSION_ROLLING_MASK (0x1FFFFFE0) instead of the
hardcoded BIP320 value 0x1FFFE000 in two places:

- downstream_message_handler.rs: mask negotiation in handle_configure
- utils.rs: default mask in validate_sv1_share

This allows version rolling of bits 5-12, extending the BIP320
range (13-28) to the full BIP323 range (5-28).
@plebhash
plebhash force-pushed the 2026-07-31-bip323-sv1-api-translation branch from 8a6f1f9 to acf8743 Compare August 4, 2026 13:36
@plebhash
plebhash force-pushed the 2026-07-31-bip323-sv1-api-translation branch from acf8743 to 8d9f18d Compare August 4, 2026 14:11
@plebhash
plebhash marked this pull request as ready for review August 4, 2026 14:12

@bit-aloo bit-aloo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK

@plebhash
plebhash merged commit 01ce980 into stratum-mining:main Aug 4, 2026
10 checks passed
@plebhash
plebhash deleted the 2026-07-31-bip323-sv1-api-translation branch August 4, 2026 14:31
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.

4 participants