Feat/peer blacklisting#113
Conversation
Signed-off-by: g-k-s-03 <govindsingh97704@gmail.com>
Signed-off-by: g-k-s-03 <govindsingh97704@gmail.com>
…lean bug and apply_transaction malformed guard Signed-off-by: g-k-s-03 <govindsingh97704@gmail.com>
Signed-off-by: g-k-s-03 <govindsingh97704@gmail.com>
Signed-off-by: g-k-s-03 <govindsingh97704@gmail.com>
Signed-off-by: g-k-s-03 <govindsingh97704@gmail.com>
…unters, defer mark_seen, cap buffer size Signed-off-by: g-k-s-03 <govindsingh97704@gmail.com>
feat: implement P2P interception layer for peer misbehavior detection
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (6)
WalkthroughThis PR propagates explicit ChangesValidationStatus, fee validation, and datadir wiring
Estimated code review effort: 4 (Complex) | ~60 minutes Sequence Diagram(s)sequenceDiagram
participant Peer
participant NetworkHandler
participant Mempool
participant Chain
participant P2PNetwork
Peer->>NetworkHandler: tx message
NetworkHandler->>Mempool: add_transaction(tx)
Mempool-->>NetworkHandler: accepted/rejected
NetworkHandler-->>P2PNetwork: ValidationStatus (VALID/INVALID/MALFORMED/FAILED)
P2PNetwork->>P2PNetwork: _handle_validation_status(peer, status)
alt threshold reached
P2PNetwork->>Peer: ban + disconnect
else within threshold
P2PNetwork-->>Peer: no action
end
Peer->>NetworkHandler: block message
NetworkHandler->>Chain: add_block(block)
Chain-->>NetworkHandler: status
NetworkHandler-->>P2PNetwork: status
Possibly related PRs
Suggested labels: Suggested reviewers: Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Addressed Issues:
Fixes #(TODO:issue number)
Screenshots/Recordings:
TODO: If applicable, add screenshots or recordings that demonstrate the interface before and after the changes.
Additional Notes:
AI Usage Disclosure:
We encourage contributors to use AI tools responsibly when creating Pull Requests. While AI can be a valuable aid, it is essential to ensure that your contributions meet the task requirements, build successfully, include relevant tests, and pass all linters. Submissions that do not meet these standards may be closed without warning to maintain the quality and integrity of the project. Please take the time to understand the changes you are proposing and their impact. AI slop is strongly discouraged and may lead to banning and blocking. Do not spam our repos with AI slop.
Check one of the checkboxes below:
I have used the following AI models and tools: TODO
Checklist
Summary by CodeRabbit
New Features
Bug Fixes