{"id":"XE-16692","kind":"bounty","visibility":"public","source":"github","source_repo":"xeprotocol/xe","source_ref":"645","source_url":"https://github.com/xeprotocol/xe/issues/645","reporter_id":2920,"title":"[Medium] Gossipsub peer scoring disables mesh delivery/failure penalties (P3/P3b weights are 0), letting non-forwarding peers squat mesh slots","area":"p2p-sync","claimed_tier":"medium","assessed_tier":null,"verdict":"duplicate","duplicate_of":null,"tracked":true,"internal_ref":"#450","internal_url":"https://github.com/xeprotocol/core/issues/450","status":"closed","closed_reason":"duplicate","github_state":"open","disclosed_at":null,"award_xe":null,"award_approved":false,"paid_ref":"","created_at":"2026-11-17T05:13:22.887519+00:00","updated_at":"2026-11-22T23:26:17.295711+00:00","source_created_at":"2026-11-17T05:13:08+00:00","told_at":"2026-11-22T23:26:17.352991+00:00","status_changed_at":"2026-11-22T23:26:17.312666+00:00","url":"https://bounty.xe.network/XE-16692","body":"## Summary\n`topicScoreParams` (`net/gossip_score.go:60-68`) sets the mesh-message-delivery and mesh-failure-penalty parameters to 0 for every topic. Per `go-libp2p-pubsub` scoring, P3 (mesh delivery deficit) and P3b (mesh failure penalty) are multiplied by these zero weights, so a mesh peer that never forwards a single message incurs zero score penalty -- while P1 (time-in-mesh) gives it a positive, growing score. Non-forwarding peers can squat mesh slots indefinitely, degrading block/vote propagation.\n\n## Root Cause\nIn `net/gossip_score.go`, `topicScoreParams` sets:\n- `MeshMessageDeliveriesWeight/Decay/Cap/Threshold/Window/Activation: 0`\n- `MeshFailurePenaltyWeight/Decay: 0`\n\nfor all six topics (Block, Vote, StateChain, Directory, Certificate, Marketplace). Per `go-libp2p-pubsub@v0.12.0/score.go:298-313`, P3 and P3b are multiplied by these weights, so they contribute nothing. Meanwhile `TimeInMeshWeight: 0.02` with cap 100 gives up to +2.0/topic for mere tenure, so a lazy peer's score is slightly positive and grows -- it is never pruned for non-delivery and outranks peers with small negative scores during oversubscription pruning.\n\n## Impact\n- Mesh slots (D=6/topic default) can be squatted indefinitely by non-forwarding peers, degrading block/vote propagation to the slower IHAVE/IWANT gossip fallback.\n- Removes gossipsub's only remedy against free-riding. This compounds XE-8346 (Sybils holding mesh slots) with a distinct root cause: the scoring config itself neuters mesh accountability.\n\n## Verification\nSource-level at HEAD `8cc209d` (testnet-0006). The zero weights are visible directly in `net/gossip_score.go:60-68`.\n\n## Suggested fix\nEnable P3/P3b per gossipsub defaults (e.g. `MeshMessageDeliveriesWeight: -1`, threshold ~5, `MeshFailurePenaltyWeight: -1`).","patch_refs":[],"thread":[{"id":18884,"source":"desk","source_ref":"reply:16561","author":"Joseph Denne","team":true,"body":"Thanks. This is the same finding as an earlier report that is not public, which was filed first; the programme pays the\nfirst verifiable submission, so this one closes as a duplicate. If you believe it is a different\nbug, file a new report that links https://bounty.xe.network/XE-16692 and says what differs; it is read like any other.","created_at":"2026-11-22T23:26:17.295711+00:00"}]}