Skip to content

handle adding separate peerIds as providers #19

Closed

Description

@tabcat

from https://github.com/libp2p/specs/tree/master/kad-dht#content-provider-advertisement:

Each peer that receives the ADD_PROVIDER RPC should validate that the received PeerInfo matches the sender's peerID, and if it does, that peer should store the PeerInfo in its datastore.

and from js-libp2p-kad-dht:

https://github.com/libp2p/js-libp2p-kad-dht/blob/508023db253d3544d90b241ca8e1f6176fc25a2d/src/rpc/handlers/add-provider.ts#L44

This means that DHT servers check that the PeerId of the node adding the Provider Record matches the PeerId in the Provider Record. This is a road bump for this use-case but should just require connecting to the dht servers using a different PeerId.

Activity

  1. changed the title [-]find suitable way to handle adding separate peerIds as providers[/-] [+]handle adding separate peerIds as providers[/+] on May 6, 2023
  2. tabcat commented on May 6, 2023

    @tabcat
    OwnerAuthor

    Going to make a simple solution which just creates an ephemeral libp2p instance inside of the collaborate method. Will see about optimizing it later. Overhead is fine for now, not called often.

  3. added a commit that references this issue on May 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions