Skip to content

Commit c5e0528

Browse files
committed
Allow relay always if the peer is at or below bip37 version.
1 parent 4554e3b commit c5e0528

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/protocols/protocol_transaction_in.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,11 @@ protocol_transaction_in::protocol_transaction_in(full_node& node,
5151
chain_(chain),
5252

5353
// TODO: move relay to a derived class protocol_transaction_in_70001.
54-
relay_from_peer_(node.network_settings().relay_transactions),
54+
// In the mean time, restrict by negotiated protocol level.
55+
// Because of inconsistent implementation by version we must allow relay
56+
// at bip37 version or below. Enforcement starts above bip37 version.
57+
relay_from_peer_(negotiated_version() <= version::level::bip37 ||
58+
node.network_settings().relay_transactions),
5559

5660
// TODO: move memory_pool to a derived class protocol_transaction_in_60002.
5761
refresh_pool_(negotiated_version() >= version::level::bip35 &&

0 commit comments

Comments
 (0)