These 71 commits are when the Protocol Buffers files have changed:
| Commit: | 84bd0c5 | |
|---|---|---|
| Author: | acul71 | |
fix(relay): enforce destination reservation on Circuit Relay v2 CONNECT Fixes #1342. Reject CONNECT when the destination has no active reservation (NO_RESERVATION=204), enforce source per-reservation connection limits separately, add get_reservation() API, regression tests, and regenerate circuit protobuf with 6.x toolchain. Co-authored-by: Cursor <cursoragent@cursor.com>
The documentation is generated from this commit.
| Commit: | a0dd62e | |
|---|---|---|
| Author: | yashksaini-coder | |
Merge remote-tracking branch 'upstream/main' into webrtc
| Commit: | 9b359fd | |
|---|---|---|
| Author: | sumanjeet0012 | |
feat: Implement Bitswap 1.3.0 with payment gating - Added PaymentGatedDecisionEngine to handle payment-required logic for block serving. - Introduced PaymentTerms, PaymentAuthorization, PaymentReceipt, and PaymentRejection messages in the new bitswap_1_3_0.proto. - Enhanced existing MerkleDag class to store internal nodes with a callback for payment gating. - Created BitswapPaymentClient_1_3 to manage client-side payment authorizations and receipts. - Updated balanced_layout function to support payment gating and internal node storage. - Added necessary protobuf definitions and generated Python files for Bitswap 1.3.0.
| Commit: | ea01b07 | |
|---|---|---|
| Author: | sumanjeet0012 | |
Merge remote-tracking branch 'origin/main' into improvement/bitswap
| Commit: | c7d74b0 | |
|---|---|---|
| Author: | sumanjeet0012 | |
feat: enhance DHT record handling with signing and verification for icompatibility with ipfs kubo - Added support for signed records in the DHT by introducing `make_signed_put_record` function. - Updated `ValueStore` to create signed records when storing values. - Enhanced `Envelope` class to handle raw payload types for peer records. - Introduced utility functions for signing and verifying DHT records. - Updated protobuf definitions to include author and signature fields in records. - Improved logging and debug messages for better traceability.
| Commit: | aff06d7 | |
|---|---|---|
| Author: | yashksaini-coder | |
feat(webrtc): add signaling protocol for private-to-private connections Implements /webrtc-signaling/0.0.1 for SDP and ICE candidate exchange over Circuit Relay v2 streams. Bilateral ICE_DONE mechanism (specs#585) ensures neither side closes the signaling stream before the other has received all candidates. WebRTCPrivateTransport handles /p2p-circuit/webrtc/ multiaddrs. WebRTCPrivateListener registers a stream handler for incoming signaling.
| Commit: | dca354e | |
|---|---|---|
| Author: | yashksaini-coder | |
feat(webrtc): add protobuf schema, constants and exception hierarchy Wire format for WebRTC data-channel messages per the libp2p spec: Message { Flag flag, bytes message } with FIN/STOP_SENDING/RESET/FIN_ACK. Constants include protocol codes (0x0118, 0x0119, 0x01D2), message size limits, data-channel ID allocation rules, Noise prologue prefix, and ICE/DTLS defaults matching go-libp2p.
| Commit: | 2663ad7 | |
|---|---|---|
| Author: | Manu Sheel Gupta | |
| Committer: | GitHub | |
Merge branch 'main' into enh/1231-add-gossipsub-1.3-support
| Commit: | d4cc6e7 | |
|---|---|---|
| Author: | Winter-Soren | |
added newsfragement, replaced string with hex method and protocol version check
| Commit: | 9f26915 | |
|---|---|---|
| Author: | Yash Saini | |
| Committer: | GitHub | |
Merge branch 'main' into IPNS
| Commit: | 9a3f328 | |
|---|---|---|
| Author: | Winter-Soren | |
feat: implement GossipSub v1.3 support with extensions and improved peer scoring
| Commit: | a33003f | |
|---|---|---|
| Author: | asmit27rai | |
feat(kad-dht): implement IPNS validator for DHT record validation - Add IPNS protobuf definition (IpnsEntry message) - Implement IPNSValidator class following IPNS spec - Integrate IPNS validator with DHT (apply_fallbacks, validate_config) - Add cbor2 dependency for DAG-CBOR decoding - Add comprehensive tests (19 test cases) Closes #1157 Signed-off-by: asmit27rai <raiasmit10@gmail.com>
| Commit: | 67c0720 | |
|---|---|---|
| Author: | Winter-Soren | |
feat: implement GossipSub with extensions, adaptive gossip, enhanced scoring, and rate limiting
| Commit: | fef6e77 | |
|---|---|---|
| Author: | Winter-Soren | |
implement persistent peerstore with Protocol Buffer serialization, context managers, and configurable sync
| Commit: | 882c8b4 | |
|---|---|---|
| Author: | acul71 | |
Fix flaky test: preserve empty bytes in NoiseExtensions early_data - Change proto3 early_data field to optional bytes to enable presence tracking - Update from_protobuf to use HasField() instead of empty check - Regenerate protobuf code - Fix documentation in protocol_buffer.py for create_status function
| Commit: | c8e1283 | |
|---|---|---|
| Author: | acul71 | |
Merge remote-tracking branch 'origin/main' into feat/protobuf-spec-for-noise # Conflicts: # libp2p/relay/circuit_v2/protocol_buffer.py
| Commit: | 1c7c87e | |
|---|---|---|
| Author: | Manu Sheel Gupta | |
| Committer: | GitHub | |
Merge branch 'main' into feature/file_sharing
| Commit: | 9c9250b | |
|---|---|---|
| Author: | acul71 | |
Merge origin/main and fix type error in protocol_buffer.py - Resolved merge conflict in circuit_pb2.py by regenerating from proto source - Fixed type error in protocol_buffer.py by using proper ValueType cast for protobuf enum - Updated protobuf files from proto source after merge
| Commit: | cb67ea1 | |
|---|---|---|
| Author: | Antriksh Gwal | |
| Committer: | lla-dane | |
add spr in all hop messages
| Commit: | badb069 | |
|---|---|---|
| Author: | Antriksh Gwal | |
| Committer: | lla-dane | |
Add SPR field in relayV2 protobuf
| Commit: | d9e8e46 | |
|---|---|---|
| Author: | acul71 | |
| Committer: | bomanaps | |
feat: experimental full spec-compliant Noise protocol implementation ๐ฏ SPEC COMPLIANCE ACHIEVED: - โ Added stream_muxers field to NoiseExtensions (spec requirement) - โ Removed legacy data field from NoiseHandshakePayload (cleanup) - โ Updated protobuf schema to match official libp2p/specs/noise - โ Maintained early_data support as Python extension ๐ง CORE CHANGES: - libp2p/security/noise/messages.py: Added stream_muxers, removed legacy fields - libp2p/security/noise/pb/noise.proto: Updated schema for spec compliance - libp2p/security/noise/patterns.py: Fixed handshake payload creation - libp2p/security/noise/transport.py: Added static key caching support ๐งช TESTING: - โ All 1064 tests passing - โ Full tox parallel execution successful - โ Wheel builds working correctly - โ Type checking and linting clean ๐ INTEROP READY: - Compatible with Go, Rust, JavaScript implementations - Stream muxers support for spec compliance - WebTransport certificate hashes preserved - Early data maintained as Python extension Next phase: Interoperability testing with other libp2p implementations
| Commit: | 90d8ae2 | |
|---|---|---|
| Author: | bomanaps | |
| Committer: | bomanaps | |
Implement complete libp2p Noise protocol extensions
| Commit: | 8012c05 | |
|---|---|---|
| Author: | Sumanjeet | |
| Committer: | GitHub | |
Merge branch 'main' into feature/file_sharing
| Commit: | 4906e6a | |
|---|---|---|
| Author: | sumanjeet0012 | |
fixed some type errors
| Commit: | c377495 | |
|---|---|---|
| Author: | Manu Sheel Gupta | |
| Committer: | GitHub | |
Merge branch 'main' into enh/806-add-gossipsub-1.2-support
| Commit: | 19c8063 | |
|---|---|---|
| Author: | lla-dane | |
| Committer: | lla-dane | |
Init py-peer-record module
| Commit: | 5f1114e | |
|---|---|---|
| Author: | lla-dane | |
| Committer: | lla-dane | |
added record validators in kad-dht
| Commit: | 8410c9d | |
|---|---|---|
| Author: | sumanjeet0012 | |
Add integration tests for MerkleDag and DAG-PB functionality - Created `test_dag.py` to test the MerkleDag class, including methods for adding bytes and files, fetching files, and verifying file information. - Implemented tests for handling small and large data, progress tracking, and error handling. - Added `test_dag_pb.py` to test the encoding and decoding of DAG-PB structures, including file and directory nodes. - Introduced a verification script `verify_bitswap.py` to ensure the Bitswap implementation's structure and functionality, including imports, configuration, block store operations, message creation, and file structure validation.
| Commit: | 232f034 | |
|---|---|---|
| Author: | Manu Sheel Gupta | |
| Committer: | GitHub | |
Merge branch 'main' into enh/806-add-gossipsub-1.2-support
| Commit: | 4fd4da9 | |
|---|---|---|
| Author: | sumanjeet0012 | |
Initial commit for bitswap
| Commit: | b9474b1 | |
|---|---|---|
| Author: | sumanjeet0012 | |
Initial commit for rendezvous implementation
| Commit: | 6075139 | |
|---|---|---|
| Author: | Soham Bhoir | |
| Committer: | GitHub | |
Merge branch 'main' into enh/806-add-gossipsub-1.2-support
| Commit: | 56526b4 | |
|---|---|---|
| Author: | lla-dane | |
| Committer: | lla-dane | |
signed-peer-record transfer integrated with pubsub rpc message trasfer
| Commit: | 2d4d4a3 | |
|---|---|---|
| Author: | Manu Sheel Gupta | |
| Committer: | GitHub | |
Merge branch 'main' into enh/806-add-gossipsub-1.2-support
| Commit: | 53db128 | |
|---|---|---|
| Author: | lla-dane | |
| Committer: | lla-dane | |
fix typos
| Commit: | 8c097d3 | |
|---|---|---|
| Author: | Winter-Soren | |
feat: add GossipSub 1.2 support with IDONTWANT messages
| Commit: | cb11f07 | |
|---|---|---|
| Author: | Soham Bhoir | |
| Committer: | GitHub | |
feat/606-enable-nat-traversal-via-hole-punching (#668) * feat: base implementation of dcutr for hole-punching * chore: removed circuit-relay imports from __init__ * feat: implemented dcutr protocol * added test suite with mock setup * Fix pre-commit hook issues in DCUtR implementation * usages of CONNECT_TYPE and SYNC_TYPE have been replaced with HolePunch.Type.CONNECT and HolePunch.Type.SYNC * added unit tests for dcutr and nat module and * added multiaddr.get_peer_id() with proper DNS address handling and fixed method signature inconsistencies * added assertions to verify DCUtR hole punch result in integration test --------- Co-authored-by: Manu Sheel Gupta <manusheel.edu@gmail.com>
| Commit: | 2d335d4 | |
|---|---|---|
| Author: | lla-dane | |
| Committer: | lla-dane | |
Integrated Signed-peer-record transfer with identify/identify-push
| Commit: | 6431fb8 | |
|---|---|---|
| Author: | lla-dane | |
| Committer: | lla-dane | |
Implemented: Envelope wrapper class + linter hacks for protobuf checks
| Commit: | aa6039b | |
|---|---|---|
| Author: | lla-dane | |
| Committer: | lla-dane | |
PeerRecord class with ProtoBuff implemented
| Commit: | c486188 | |
|---|---|---|
| Author: | Mystical | |
| Committer: | Mystical | |
updated protobuf for prune message
| Commit: | 66bd027 | |
|---|---|---|
| Author: | Soham Bhoir | |
| Committer: | GitHub | |
Feat/587-circuit-relay (#611) * feat: implemented setup of circuit relay and test cases * chore: remove test files to be rewritten * added 1 test suite for protocol * added 1 test suite for discovery * fixed protocol timeouts and message types to handle reservations and stream operations. * Resolved merge conflict in libp2p/tools/utils.py by combining timeout approach with retry mechanism * fix: linting issues * docs: updated documentation with circuit-relay * chore: added enums, improved typing, security and examples * fix: created proper __init__ file to ensure importability * fix: replace transport_opt with listen_addrs in examples, fixed typing and improved code * fix type checking issues across relay module and test suite * regenerated circuit_pb2 file protobuf version 3 * fixed circuit relay example and moved imports to top in test_security_multistream * chore: moved imports to the top * chore: fixed linting of test_circuit_v2_transport.py --------- Co-authored-by: Manu Sheel Gupta <manusheel.edu@gmail.com>
| Commit: | d61bca7 | |
|---|---|---|
| Author: | Sumanjeet | |
| Committer: | GitHub | |
Kademlia DHT implementation in py-libp2p (#579) * initialise the module * added content routing * added routing module * added peer routing * added value store * added utilities functions * added main kademlia file * fixed create_key_from_binary function * example to test kademlia dht * added protocol ID and enhanced logging for peer store size in provider and consumer nodes * refactor: specify stream type in handle_stream method and add peer in routing table * removed content routing * added default value of count for finding closest peers * added functions to find close peers * refactor: remove content routing and enhance peer discovery * added put value function * added get value function * fix: improve logging and handle key encoding in get_value method * refactor: remove ContentRouting import from __init__.py * refactor: improved basic kademlia example * added protobuf files * replaced json with protobuf * refactor: enhance peer discovery and routing logic in KadDHT * refactor: enhance Kademlia routing table to use PeerInfo objects and improve peer management * refactor: enhance peer addition logic to utilize PeerInfo objects in routing table * feat: implement content provider functionality in Kademlia DHT * refactor: update value store to use datetime for validity management * refactor: update RoutingTable initialization to include host reference * refactor: enhance KBucket and RoutingTable for improved peer management and functionality * refactor: streamline peer discovery and value storage methods in KadDHT * refactor: update KadDHT and related classes for async peer management and enhanced value storage * refactor: enhance ProviderStore initialization and improve peer routing integration * test: add tests for Kademlia DHT functionality * fix linting issues * pydocstyle issues fixed * CICD pipeline issues solved * fix: update docstring format for find_peer method * refactor: improve logging and remove unused code in DHT implementation * refactor: clean up logging and remove unused imports in DHT and test files * Refactor logging setup and improve DHT stream handling with varint length prefixes * Update bootstrap peer handling in basic_dht example and refactor peer routing to accept string addresses * Enhance peer querying in Kademlia DHT by implementing parallel queries using Trio. * Enhance peer querying by adding deduplication checks * Refactor DHT implementation to use varint for length prefixes and enhance logging for better traceability * Add base58 encoding for value storage and enhance logging in basic_dht example * Refactor Kademlia DHT to support server/client modes * Added unit tests * Refactor documentation to fixsome warning * Add unit tests and remove outdated tests * Fixed precommit errora * Refactor error handling test to raise StringParseError for invalid bootstrap addresses * Add libp2p.kad_dht to the list of subpackages in documentation * Fix expiration and republish checks to use inclusive comparison * Add __init__.py file to libp2p.kad_dht.pb package * Refactor get value and put value to run in parallel with query timeout * Refactor provider message handling to use parallel processing with timeout * Add methods for provider store in KadDHT class * Refactor KadDHT and ProviderStore methods to improve type hints and enhance parallel processing * Add documentation for libp2p.kad_dht.pb module. * Update documentation for libp2p.kad_dht package to include subpackages and correct formatting * Fix formatting in documentation for libp2p.kad_dht package by correcting the subpackage reference * Fix header formatting in libp2p.kad_dht.pb documentation * Change log level from info to debug for various logging statements. * fix CICD issues (post revamp) * fixed value store unit test * Refactored kademlia example * Refactor Kademlia example: enhance logging, improve bootstrap node connection, and streamline server address handling * removed bootstrap module * Refactor Kademlia DHT example and core modules: enhance logging, remove unused code, and improve peer handling * Added docs of kad dht example * Update server address log file path to use the script's directory * Refactor: Introduce DHTMode enum for clearer mode management * moved xor_distance function to utils.py * Enhance logging in ValueStore and KadDHT: include decoded value in debug logs and update parameter description for validity * Add handling for closest peers in GET_VALUE response when value is not found * Handled failure scenario for PUT_VALUE * Remove kademlia demo from project scripts and contributing documentation * spelling and logging --------- Co-authored-by: pacrob <5199899+pacrob@users.noreply.github.com>
| Commit: | 4b18607 | |
|---|---|---|
| Author: | Paschal | |
| Committer: | GitHub | |
Feat: Adding Yamux as default multiplexer, keeping Mplex as fallback (#538) * feat: Replace mplex with yamux as default multiplexer in py-libp2p * Retain Mplex alongside Yamux in new_swarm with messaging that Yamux is preferred * moved !BBHII to a constant YAMUX_HEADER_FORMAT at the top of yamux.py with a comment explaining its structure * renamed the news fragment to 534.feature.rst and updated the description * renamed the news fragment to 534.feature.rst and updated the description * added a docstring to clarify that Yamux does not support deadlines natively * Remove the __main__ block entirely from test_yamux.py * Replaced the print statements in test_yamux.py with logging.debug * Added a comment linking to the spec for clarity * Raise NotImplementedError in YamuxStream.set_deadline per review * Add muxed_conn to YamuxStream and test deadline NotImplementedError * Fix Yamux implementation to meet libp2p spec * Fix None handling in YamuxStream.read and Yamux.read_stream * Fix test_connected_peers.py to correctly handle peer connections * fix: Ensure StreamReset is raised on read after local reset in yamux * fix: Map MuxedStreamError to StreamClosed in NetStream.write for Yamux * fix: Raise MuxedStreamReset in Yamux.read_stream for closed streams * fix: Correct Yamux stream read behavior for NetStream tests Fixed est_net_stream_read_after_remote_closed by updating NetStream.read to raise StreamEOF when the stream is remotely closed and no data is available, aligning with test expectations and Fixed est_net_stream_read_until_eof by modifying YamuxStream.read to block until the stream is closed ( ecv_closed=True) for =-1 reads, ensuring data is only returned after remote closure. * fix: Correct Yamux stream read behavior for NetStream tests Fixed est_net_stream_read_after_remote_closed by updating NetStream.read to raise StreamEOF when the stream is remotely closed and no data is available, aligning with test expectations and Fixed est_net_stream_read_until_eof by modifying YamuxStream.read to block until the stream is closed ( ecv_closed=True) for =-1 reads, ensuring data is only returned after remote closure. * fix: raise StreamEOF when reading from closed stream with empty buffer * fix: prioritize returning buffered data even after stream reset * fix: prioritize returning buffered data even after stream reset * fix: Ensure test_net_stream_read_after_remote_closed_and_reset passes in full suite * fix: Add __init__.py to yamux module to fix documentation build * fix: Add __init__.py to yamux module to fix documentation build * fix: Add libp2p.stream_muxer.yamux to libp2p.stream_muxer.rst toctree * fix: Correct title underline length in libp2p.stream_muxer.yamux.rst * fix: Add a = so that is matches the libp2p.stream\_muxer.yamux length * fix(tests): Resolve race condition in network notification test * fix: fixing failing tests and examples with yamux and noise * refactor: remove debug logging and improve x25519 tests * fix: Add functionality for users to choose between Yamux and Mplex * fix: increased trio sleep to 0.1 sec for slow environment * feat: Add test for switching between Yamux and mplex * refactor: move host fixtures to interop tests * chore: Update __init__.py removing unused import removed unused ```python import os import logging ``` * lint: fix import order * fix: Resolve conftest.py conflict by removing trio test support * fix: Resolve test skipping by keeping trio test support * Fix: add a newline at end of the file --------- Co-authored-by: acul71 <luca.pisani@birdo.net> Co-authored-by: acul71 <34693171+acul71@users.noreply.github.com>
| Commit: | 9655c88 | |
|---|---|---|
| Author: | Winter-Soren | |
| Committer: | Paul Robinson | |
feat/561-added autonat service
| Commit: | d55c577 | |
|---|---|---|
| Author: | sumanjeet0012@gmail.com | |
| Committer: | Paul Robinson | |
Refactor: changed PeerInfo to Peer_Info in autonat.proto to avoid conflicts
| Commit: | e9674d2 | |
|---|---|---|
| Author: | Winter-Soren | |
| Committer: | Paul Robinson | |
refractored Peer_Info to PeerInfo as imports
| Commit: | c770a05 | |
|---|---|---|
| Author: | pacrob | |
| Committer: | Paul Robinson | |
rebuild protobufs adding ECC_P256 to KeyType
| Commit: | 9448371 | |
|---|---|---|
| Author: | pacrob | |
| Committer: | pacrob | |
run lint and fix errors, except mypy
| Commit: | 728d9e5 | |
|---|---|---|
| Author: | mhchia | |
| Committer: | mhchia | |
Noise: update pb
| Commit: | 0324a69 | |
|---|---|---|
| Author: | mhchia | |
Noise: add `PatternXX`
| Commit: | 82dcce2 | |
|---|---|---|
| Author: | Chih Cheng Liang | |
| Committer: | GitHub | |
Remove kademlia module (#377) * Remove kademlia and routing/kademlia * cleanup * Fix routed_host test * lint mypy * fix doc * remove set_up_nodes_by_transport_and_disc_opt and fix typing
| Commit: | 08b57fa | |
|---|---|---|
| Author: | Alex Stokes | |
| Committer: | Alex Stokes | |
Add core handler for `identify` protocol
| Commit: | afb79da | |
|---|---|---|
| Author: | Dominik Muhs | |
Fix typo
| Commit: | fd08bcf | |
|---|---|---|
| Author: | Alex Stokes | |
| Committer: | Alex Stokes | |
Add `secio` protobufs
| Commit: | 59b373b | |
|---|---|---|
| Author: | mhchia | |
| Committer: | mhchia | |
Add `plaintext.proto` Update Makefile to handle the import in `plaintext.proto`. Import path is modified to be relative to the project root. And we run `protoc` from where `Makefile` locates, i.e. the project root. Reference: - plaintext.proto: https://github.com/libp2p/go-libp2p-core/blob/62b2c6c482ef265f6b975d59244fd7b2169aaabf/sec/insecure/pb/plaintext.proto
| Commit: | 61f78c8 | |
|---|---|---|
| Author: | Alex Stokes | |
| Committer: | Alex Stokes | |
Add abstraction for a cryptographic key
| Commit: | 14da7d4 | |
|---|---|---|
| Author: | ZX | |
| Committer: | GitHub | |
Merge branch 'master' into peer_routing
| Commit: | d5c7cc7 | |
|---|---|---|
| Author: | Alex Haynes | |
added changes from future commits to last passing bmuller commit
| Commit: | f655148 | |
|---|---|---|
| Author: | zixuanzh | |
| Committer: | Stuckinaboot | |
add pubsub proto
| Commit: | f1a20f1 | |
|---|---|---|
| Author: | zixuanzh | |
| Committer: | Stuckinaboot | |
update from to from_id in proto
| Commit: | 0d7b8c3 | |
|---|---|---|
| Author: | Alex Haynes | |
| Committer: | Stuckinaboot | |
added rpc.proto from go repo
| Commit: | 2b41818 | |
|---|---|---|
| Author: | zixuanzh | |
| Committer: | Stuckinaboot | |
update from to from_id in proto
| Commit: | 2aa7c4a | |
|---|---|---|
| Author: | zixuanzh | |
| Committer: | Stuckinaboot | |
add pubsub proto
| Commit: | 1c08e9e | |
|---|---|---|
| Author: | Alex Haynes | |
| Committer: | Stuckinaboot | |
added rpc.proto from go repo
| Commit: | 225bd39 | |
|---|---|---|
| Author: | zixuanzh | |
add source to rpc.proto
| Commit: | 3a52d29 | |
|---|---|---|
| Author: | zixuanzh | |
remove redundant proto file
| Commit: | 9be1214 | |
|---|---|---|
| Author: | Alex Haynes | |
Merge branch 'floodsub-rpc' of https://github.com/libp2p/py-libp2p into floodsub-rpc
| Commit: | 81d121a | |
|---|---|---|
| Author: | zixuanzh | |
update from to from_id in proto
| Commit: | 041e0fb | |
|---|---|---|
| Author: | zixuanzh | |
add pubsub proto
| Commit: | cb6b76d | |
|---|---|---|
| Author: | Alex Haynes | |
added rpc.proto from go repo