Skip to content

Commit 842bf8d

Browse files
committed
Merge #8408: Prevent fingerprinting, disk-DoS with compact blocks
1d06e49 Ignore CMPCTBLOCK messages for pruned blocks (Suhas Daftuar) 1de2a46 Ignore GETBLOCKTXN requests for unknown blocks (Suhas Daftuar)
2 parents ad08763 + 1d06e49 commit 842bf8d

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/main.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5343,7 +5343,6 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
53435343

53445344
BlockMap::iterator it = mapBlockIndex.find(req.blockhash);
53455345
if (it == mapBlockIndex.end() || !(it->second->nStatus & BLOCK_HAVE_DATA)) {
5346-
Misbehaving(pfrom->GetId(), 100);
53475346
LogPrintf("Peer %d sent us a getblocktxn for a block we don't have", pfrom->id);
53485347
return true;
53495348
}
@@ -5627,8 +5626,8 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
56275626
std::vector<CInv> vInv(1);
56285627
vInv[0] = CInv(MSG_BLOCK, cmpctblock.header.GetHash());
56295628
pfrom->PushMessage(NetMsgType::GETDATA, vInv);
5630-
return true;
56315629
}
5630+
return true;
56325631
}
56335632

56345633
// If we're not close to tip yet, give up and let parallel block fetch work its magic

0 commit comments

Comments
 (0)