paritytech / litep2p

Peer-to-peer networking library
MIT License
68 stars 10 forks source link

kad: Ensure Kademlia Record has TTL #129

Closed lexnv closed 3 months ago

lexnv commented 4 months ago

If the record received by kad::put_value does not have a TTL, use the default 36h expiry.

https://github.com/paritytech/litep2p/blob/467a457c78785819e91ecdb7a5a926b7cd1c3d25/src/protocol/libp2p/kademlia/record.rs#L88-L89

### Tasks
- [ ] https://github.com/paritytech/litep2p/pull/154
- [ ] https://github.com/paritytech/litep2p/pull/162