latest.ipv8.messaging.anonymization.pex
Module Contents
Classes
Settings for the PexCommunity. |
|
New on-the-fly overlay for the PEX protocol. |
Attributes
- latest.ipv8.messaging.anonymization.pex.PEX_VERSION = 1
- class latest.ipv8.messaging.anonymization.pex.PexSettings
Bases:
latest.ipv8.community.CommunitySettings
Settings for the PexCommunity.
- class latest.ipv8.messaging.anonymization.pex.PexCommunity(settings: PexSettings)
Bases:
latest.ipv8.community.Community
New on-the-fly overlay for the PEX protocol.
- get_intro_points() list[latest.ipv8.messaging.anonymization.tunnel.IntroductionPoint]
Get a list of the most recent introduction points that were discovered using PexCommunity. :return : list of IntroductionPoint objects.
- start_announce(seeder_pk: bytes) None
Start announcing yourself as an introduction point for a certain seeder.
- Parameters:
seeder_pk – public key of the seeder (in binary format).
- stop_announce(seeder_pk: bytes) None
Stop announcing yourself as an introduction point for a certain seeder. :param seeder_pk: public key of the seeder (in binary format).
- process_extra_bytes(peer: latest.ipv8.peer.Peer, extra_bytes: bytes) None
Unpack any introduction points piggybacked onto the introduction requests and responses.
- introduction_request_callback(peer: latest.ipv8.peer.Peer, dist: latest.ipv8.messaging.payload_headers.GlobalTimeDistributionPayload, payload: latest.ipv8.messaging.payload.IntroductionRequestPayload | latest.ipv8.messaging.payload.NewIntroductionRequestPayload) None
Callback for when an introduction request comes in.
- introduction_response_callback(peer: latest.ipv8.peer.Peer, dist: latest.ipv8.messaging.payload_headers.GlobalTimeDistributionPayload, payload: latest.ipv8.messaging.payload.IntroductionResponsePayload | latest.ipv8.messaging.payload.NewIntroductionResponsePayload) None
Callback for when an introduction response comes in.
- create_introduction_request(socket_address: latest.ipv8.types.Address, extra_bytes: bytes = b'', new_style: bool = False, prefix: bytes | None = None) bytes
Piggyback introduction points onto introduction requests.
- create_introduction_response(lan_socket_address: latest.ipv8.types.Address, socket_address: latest.ipv8.types.Address, identifier: int, introduction: latest.ipv8.peer.Peer | None = None, extra_bytes: bytes = b'', prefix: bytes | None = None, new_style: bool = False) bytes
Piggyback introduction points onto introduction responses.
- send_ping(peer: latest.ipv8.peer.Peer) None
Send a ping messages to a peer.