Changeset View
Changeset View
Standalone View
Standalone View
test/functional/p2p_leak.py
#!/usr/bin/env python3 | #!/usr/bin/env python3 | ||||
# Copyright (c) 2017 The Bitcoin Core developers | # Copyright (c) 2017 The Bitcoin Core developers | ||||
# Distributed under the MIT software license, see the accompanying | # Distributed under the MIT software license, see the accompanying | ||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php. | # file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
"""Test message sending before handshake completion. | """Test message sending before handshake completion. | ||||
A node should never send anything other than VERSION/VERACK/REJECT until it's | A node should never send anything other than VERSION/VERACK/REJECT until it's | ||||
received a VERACK. | received a VERACK. | ||||
This test connects to a node and sends it a few messages, trying to intice it | This test connects to a node and sends it a few messages, trying to intice it | ||||
into sending us something it shouldn't.""" | into sending us something it shouldn't. | ||||
""" | |||||
import time | import time | ||||
from test_framework.mininode import ( | from test_framework.mininode import ( | ||||
mininode_lock, | mininode_lock, | ||||
network_thread_join, | network_thread_join, | ||||
network_thread_start, | network_thread_start, | ||||
P2PInterface, | P2PInterface, | ||||
▲ Show 20 Lines • Show All 151 Lines • Show Last 20 Lines |