About Me
I’m Gordon Murray, an independent researcher in the Kaspa community. My work focuses on improving Kaspa’s networking layer, including publishing a whitepaper on RLNC for BlockDAG propagation LinkeIn link. This post is a condensed version of that research, with additional ideas about enabling Kaspa to run over wireless mesh networks. The whitepaper was highlighted on my LinkedIn by Gilad Aviram, who encouraged me to share it here for discussion at the request of Michael Sutton. I should also note that I’ve been inspired by the pioneering work of Muriel Médard on network coding and the Optimum P2P project, which demonstrated RLNC’s real-world benefits in Ethereum.
Proposal: Applying Random Linear Network Coding (RLNC) to Kaspa’s P2P Layer (Including Wireless Mesh Networks)
Executive Summary
Kaspa’s BlockDAG currently achieves ~10 blocks per second (BPS) and aims for 100+ BPS. While consensus (GHOSTDAG) is efficient, the network layer remains a bottleneck:
• Redundant gossip floods overlapping transactions.
• Multiple block bodies per second stress bandwidth.
• Global latency skew reduces blue-set inclusion fairness.
I propose integrating Random Linear Network Coding (RLNC) into Kaspa’s P2P layer. RLNC optimizes propagation by transmitting linear combinations of blocks/transactions, so nearly every received shard is innovative.
This directly benefits:
• Block propagation (reduces redundancy)
• IBD (Initial Block Download) (faster sync, fewer stalls)
• Mempool sync (efficient transaction relay)
• And critically, enables Kaspa to run over wireless mesh networks for maximum decentralization.
Layer Separation: RLNC is Consensus-Agnostic
┌─────────────────────────────────────┐
│ Application Layer │
├─────────────────────────────────────┤
│ Consensus Layer │
│ (Kaspa PoW: Mining + GHOSTDAG) │
├─────────────────────────────────────┤
│ Network / P2P Layer │
│ ← RLNC OPERATES HERE → │
├─────────────────────────────────────┤
│ Transport Layer │
└─────────────────────────────────────┘
RLNC optimizes the network layer. Consensus remains untouched: whether PoW or PoS, blocks must still propagate efficiently.
Current P2P Implementation (Rusty-Kaspa)
In kaspad/src/p2p/flows:
• Block relay → flows/block/handle_incoming.rs
• Transaction relay → flows/transaction/relay.rs
• Initial Block Download → flows/ibd
All rely on gossip-based flooding: every block or transaction is propagated individually. This ensures delivery, but at high BPS causes:
- Redundant transmission of overlapping transactions.
- Bandwidth stress from concurrent block bodies.
- Latency skew → slower blocks earn less blue score, reducing fairness.
RLNC Benefits for Kaspa
1. Block Propagation
• Encode multiple concurrent blocks into shards.
• Peers forward different shards → receivers decode originals once rank is full.
• Reduces redundant gossip.
2. IBD (Initial Block Download)
• Sync peers send coded shards over block ranges.
• New nodes don’t stall on missing blocks.
• Faster historical sync.
3. Transaction Relay
• Batch encode mempool transactions.
• Even if wireless peers miss shards, decoding succeeds once enough arrive.
Kaspa over Wireless Mesh Networks
Why RLNC is Ideal for Mesh
Wireless mesh networks are lossy, variable-latency, and retransmission-expensive. RLNC was originally developed for these conditions (multicast, satellite, ad-hoc).
Mesh-Specific Benefits
• Multicast efficiency → one radio transmission helps multiple neighbors.
• Partition healing → shards rapidly fill in missing data after splits.
• Resilience → innovative shards survive packet loss.
• Energy efficiency → fewer retransmissions save battery-powered nodes.
To our knowledge, no high-throughput PoW BlockDAG has ever been adapted to wireless mesh. Prior experiments used Hyperledger Fabric or PoA Ethereum with low block rates. Kaspa + RLNC would be the first truly high-rate permissionless blockchain optimized for mesh networks.
Example: RLNC in Rusty-Kaspa
// protocol/src/messages/rlnc.rs
#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct RlncShard {
pub coefficients: Vec<u8>, // Random GF(2^8) coefficients
pub payload: Vec<u8>, // Encoded block/tx data
pub commitments: Vec<Hash>, // Merkle roots for integrity
}
Extend block relay (flows/block):
fn propagate_blocks_rlnc(blocks: Vec<Block>) {
let shards = rlnc::encode(blocks, redundancy_factor);
for (peer, shard) in peers.iter().zip(shards) {
send_message(peer, Message::RlncShard(shard));
}
}
On receiving side:
fn handle_rlnc_shard(shard: RlncShard) {
decoder.add_shard(shard);
if decoder.is_ready() {
let blocks = decoder.decode();
for block in blocks {
validate_and_insert(block); // consensus unchanged
}
}
}
Quantitative Outlook (Whitepaper Results)
Formal model: RLNC improves finality when
3(1−η)τ > δ
where:
• η = efficiency factor (bandwidth savings)
• τ = network mixing time
• δ = decode overhead
Example from whitepaper:
• With W=10 blocks, ρ=0.6 overlap → η ≈ 0.46 (54% savings).
• τ ≈ 80ms → RLNC can tolerate δ up to ~130ms.
• Optimized decoding achieves δ < 5ms.
Thus RLNC yields 40–60% bandwidth savings and reduced ordering lag, improving blue-set fairness.
Deployment Strategy
- Phase I: Systematic RLNC for block bodies (send some uncoded chunks + coded shards).
- Phase II: Transaction batch gossip.
- Phase III: Multi-tip coding across sliding windows.
- Phase IV: Test with
simpaunder lossy/mesh conditions. - Phase V: Opt-in rollout (
--enable-rlnc).
This roadmap is backward-compatible and can begin in private relay overlays before public deployment.
Conclusion
RLNC directly addresses Kaspa’s network bottlenecks:
• Reduces redundant gossip traffic.
• Speeds up IBD and transaction relay.
• Improves blue-set inclusion fairness at high BPS.
• Enables Kaspa to run over wireless mesh networks, maximizing decentralization.
Bottom Line: RLNC is not just a bandwidth optimization — it is a novel enabler that could make Kaspa the first high-throughput PoW BlockDAG blockchain to run efficiently on mesh networks.
Call to Action
I invite Kaspa devs and researchers to:
- Review the proposed
RlncShardmessage type and relay flow. - Use
simpawith lossy network parameters to emulate mesh conditions. - Discuss feasibility, trade-offs, and next steps.
With RLNC, Kaspa can scale not just in datacenters but across community-built mesh deployments, making it censorship-resistant, resilient, and globally distributed.