forked from 256foundation/hydrapool
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
sv2Stratum v2 relatedStratum v2 related
Description
Summary
Currently the SV2 extended channel implementation uses a fixed 6/6 extranonce split: 6-byte pool prefix (server_id[2] + channel_id[4]) and 6-byte proxy search space, within the 12-byte coinbase extranonce slot.
This works well for most cases (2^48 combinations is plenty), but a downstream proxy requesting min_extranonce_size > 6 will be rejected with unsupported-min-extranonce-size.
Proposed Enhancement
- Make the extranonce prefix length configurable (e.g., pool config or dynamic based on
min_extranonce_sizefrom proxy) - Allow shorter pool prefixes (e.g., 2-4 bytes) to give proxies more search space when requested
- Consider making the total extranonce slot size configurable (currently hard-coded at 12 bytes via
EXTRANONCE1_SIZE + EXTRANONCE2_SIZE)
Context
- SV1 uses a hard-coded 4/8 split (same 12-byte slot)
- The 12-byte slot is baked into
build_coinbase_transaction()viaEXTRANONCE_SEPARATOR - Extended channel extranonce structure:
coinbase_tx_prefix + extranonce_prefix + proxy_extranonce + coinbase_tx_suffix - Related: Implement Extended Mining Channel support #8 (Extended Mining Channels), Implement SubmitSharesExtended handler #14 (SubmitSharesExtended)
Priority
Low — the fixed 6/6 split covers all realistic use cases. This is a future improvement for spec completeness.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
sv2Stratum v2 relatedStratum v2 related