diff --git a/package.json b/package.json index 988200351a4d..6353104811c3 100644 --- a/package.json +++ b/package.json @@ -75,7 +75,7 @@ "karma-spec-reporter": "^0.0.36", "karma-webpack": "^5.0.0", "lerna": "^6.6.1", - "libp2p": "0.45.9", + "libp2p": "0.46.3", "mocha": "^10.2.0", "node-gyp": "^9.3.1", "npm-run-all": "^4.1.5", diff --git a/packages/beacon-node/package.json b/packages/beacon-node/package.json index da184d384ee8..eddd66fce7a0 100644 --- a/packages/beacon-node/package.json +++ b/packages/beacon-node/package.json @@ -100,8 +100,8 @@ "@chainsafe/bls": "7.1.1", "@chainsafe/blst": "^0.2.9", "@chainsafe/discv5": "^5.0.0", - "@chainsafe/libp2p-gossipsub": "^9.1.0", - "@chainsafe/libp2p-noise": "^12.0.1", + "@chainsafe/libp2p-gossipsub": "^10.0.0", + "@chainsafe/libp2p-noise": "^13.0.0", "@chainsafe/persistent-merkle-tree": "^0.5.0", "@chainsafe/prometheus-gc-stats": "^1.0.0", "@chainsafe/ssz": "^0.10.2", @@ -109,18 +109,14 @@ "@ethersproject/abi": "^5.7.0", "@fastify/bearer-auth": "^9.0.0", "@fastify/cors": "^8.2.1", - "@libp2p/bootstrap": "^8.0.0", - "@libp2p/interface-connection": "^5.1.0", - "@libp2p/interface-connection-manager": "^3.0.1", - "@libp2p/interface-peer-id": "^2.0.2", - "@libp2p/interface-pubsub": "^4.0.1", - "@libp2p/interface-registrar": "^2.0.12", - "@libp2p/mdns": "^8.0.0", - "@libp2p/mplex": "^8.0.3", - "@libp2p/peer-id": "^2.0.3", - "@libp2p/peer-id-factory": "^2.0.3", - "@libp2p/prometheus-metrics": "^1.1.4", - "@libp2p/tcp": "7.0.1", + "@libp2p/bootstrap": "^9.0.2", + "@libp2p/interface": "^0.1.1", + "@libp2p/mdns": "^9.0.2", + "@libp2p/mplex": "^9.0.2", + "@libp2p/peer-id": "^3.0.1", + "@libp2p/peer-id-factory": "^3.0.2", + "@libp2p/prometheus-metrics": "^2.0.2", + "@libp2p/tcp": "8.0.2", "@lodestar/api": "^1.10.0", "@lodestar/config": "^1.10.0", "@lodestar/db": "^1.10.0", @@ -145,7 +141,7 @@ "it-all": "^3.0.2", "it-pipe": "^3.0.1", "jwt-simple": "0.5.6", - "libp2p": "0.45.9", + "libp2p": "0.46.3", "multiformats": "^11.0.1", "prom-client": "^14.2.0", "qs": "^6.11.1", diff --git a/packages/beacon-node/src/api/impl/node/utils.ts b/packages/beacon-node/src/api/impl/node/utils.ts index 3059297e66e8..7e13053e7df0 100644 --- a/packages/beacon-node/src/api/impl/node/utils.ts +++ b/packages/beacon-node/src/api/impl/node/utils.ts @@ -1,6 +1,5 @@ -import {Connection} from "@libp2p/interface-connection"; +import {Connection, StreamStatus} from "@libp2p/interface/connection"; import {routes} from "@lodestar/api"; -import {PeerStatus} from "../../../network/index.js"; /** * Format a list of connections from libp2p connections manager into the API's format NodePeer @@ -13,8 +12,8 @@ export function formatNodePeer(peerIdStr: string, connections: Connection[]): ro // TODO: figure out how to get enr of peer enr: "", lastSeenP2pAddress: conn ? conn.remoteAddr.toString() : "", - direction: conn ? (conn.stat.direction as routes.node.PeerDirection) : null, - state: conn ? getPeerState(conn.stat.status) : "disconnected", + direction: conn ? (conn.direction as routes.node.PeerDirection) : null, + state: conn ? getPeerState(conn.status) : "disconnected", }; } @@ -25,26 +24,26 @@ export function formatNodePeer(peerIdStr: string, connections: Connection[]): ro * - Otherwise, the first closed connection */ export function getRelevantConnection(connections: Connection[]): Connection | null { - const byStatus = new Map(); + const byStatus = new Map(); for (const conn of connections) { - if (conn.stat.status === "OPEN") return conn; - if (!byStatus.has(conn.stat.status)) byStatus.set(conn.stat.status, conn); + if (conn.status === "open") return conn; + if (!byStatus.has(conn.status)) byStatus.set(conn.status, conn); } - return byStatus.get("OPEN") || byStatus.get("CLOSING") || byStatus.get("CLOSED") || null; + return byStatus.get("open") || byStatus.get("closing") || byStatus.get("closed") || null; } /** * Map libp2p connection status to the API's peer state notation * @param status */ -function getPeerState(status: PeerStatus): routes.node.PeerState { +function getPeerState(status: StreamStatus): routes.node.PeerState { switch (status) { - case "OPEN": + case "open": return "connected"; - case "CLOSING": + case "closing": return "disconnecting"; - case "CLOSED": + case "closed": default: return "disconnected"; } diff --git a/packages/beacon-node/src/network/core/networkCore.ts b/packages/beacon-node/src/network/core/networkCore.ts index d2545a4e758c..ea44d4948a39 100644 --- a/packages/beacon-node/src/network/core/networkCore.ts +++ b/packages/beacon-node/src/network/core/networkCore.ts @@ -1,6 +1,6 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {multiaddr} from "@multiformats/multiaddr"; -import {Connection} from "@libp2p/interface-connection"; +import {Connection} from "@libp2p/interface/connection"; import {PublishOpts} from "@chainsafe/libp2p-gossipsub/types"; import {PeerScoreStatsDump} from "@chainsafe/libp2p-gossipsub/dist/src/score/peer-score.js"; import {fromHexString} from "@chainsafe/ssz"; diff --git a/packages/beacon-node/src/network/core/networkCoreWorkerHandler.ts b/packages/beacon-node/src/network/core/networkCoreWorkerHandler.ts index 8b7a09202c17..f615458ddd12 100644 --- a/packages/beacon-node/src/network/core/networkCoreWorkerHandler.ts +++ b/packages/beacon-node/src/network/core/networkCoreWorkerHandler.ts @@ -1,6 +1,6 @@ import worker_threads from "node:worker_threads"; import {exportToProtobuf} from "@libp2p/peer-id-factory"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {PeerScoreStatsDump} from "@chainsafe/libp2p-gossipsub/dist/src/score/peer-score.js"; import {PublishOpts} from "@chainsafe/libp2p-gossipsub/types"; import {spawn, Thread, Worker} from "@chainsafe/threads"; diff --git a/packages/beacon-node/src/network/discv5/index.ts b/packages/beacon-node/src/network/discv5/index.ts index 089e8813f5eb..d5bc9bb0dffd 100644 --- a/packages/beacon-node/src/network/discv5/index.ts +++ b/packages/beacon-node/src/network/discv5/index.ts @@ -1,5 +1,5 @@ import EventEmitter from "events"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import StrictEventEmitter from "strict-event-emitter-types"; import {exportToProtobuf} from "@libp2p/peer-id-factory"; import {createKeypairFromPeerId, ENR, ENRData, IKeypair, SignableENR} from "@chainsafe/discv5"; diff --git a/packages/beacon-node/src/network/events.ts b/packages/beacon-node/src/network/events.ts index db45ea6b1ac2..815efda7d9b8 100644 --- a/packages/beacon-node/src/network/events.ts +++ b/packages/beacon-node/src/network/events.ts @@ -1,6 +1,6 @@ import {EventEmitter} from "events"; -import {PeerId} from "@libp2p/interface-peer-id"; -import {TopicValidatorResult} from "@libp2p/interface-pubsub"; +import {PeerId} from "@libp2p/interface/peer-id"; +import {TopicValidatorResult} from "@libp2p/interface/pubsub"; import {phase0, RootHex} from "@lodestar/types"; import {BlockInput} from "../chain/blocks/types.js"; import {StrictEventEmitterSingleArg} from "../util/strictEvents.js"; diff --git a/packages/beacon-node/src/network/gossip/encoding.ts b/packages/beacon-node/src/network/gossip/encoding.ts index c4ba0011bd00..5c39dd96cec9 100644 --- a/packages/beacon-node/src/network/gossip/encoding.ts +++ b/packages/beacon-node/src/network/gossip/encoding.ts @@ -1,6 +1,6 @@ import {compress, uncompress} from "snappyjs"; import xxhashFactory from "xxhash-wasm"; -import {Message} from "@libp2p/interface-pubsub"; +import {Message} from "@libp2p/interface/pubsub"; import {digest} from "@chainsafe/as-sha256"; import {RPC} from "@chainsafe/libp2p-gossipsub/message"; import {intToBytes, toHex} from "@lodestar/utils"; diff --git a/packages/beacon-node/src/network/gossip/interface.ts b/packages/beacon-node/src/network/gossip/interface.ts index 6f1365a77c9c..58961bd6db2f 100644 --- a/packages/beacon-node/src/network/gossip/interface.ts +++ b/packages/beacon-node/src/network/gossip/interface.ts @@ -1,5 +1,5 @@ import {Libp2p} from "libp2p"; -import {Message, TopicValidatorResult} from "@libp2p/interface-pubsub"; +import {Message, TopicValidatorResult} from "@libp2p/interface/pubsub"; import {PeerIdStr} from "@chainsafe/libp2p-gossipsub/types"; import {ForkName} from "@lodestar/params"; import {allForks, altair, capella, deneb, phase0, Slot} from "@lodestar/types"; diff --git a/packages/beacon-node/src/network/interface.ts b/packages/beacon-node/src/network/interface.ts index 9ef305c02d8f..b9ca9e002116 100644 --- a/packages/beacon-node/src/network/interface.ts +++ b/packages/beacon-node/src/network/interface.ts @@ -1,5 +1,4 @@ import {Libp2p as ILibp2p} from "libp2p"; -import {Connection} from "@libp2p/interface-connection"; import {Components} from "libp2p/components"; import {Slot, SlotRootHex, allForks, altair, capella, deneb, phase0} from "@lodestar/types"; import {PeerIdStr} from "../util/peerId.js"; @@ -62,9 +61,6 @@ export interface INetwork extends INetworkCorePublic { writeNetworkThreadProfile(durationMs?: number, dirpath?: string): Promise; } -export type PeerDirection = Connection["stat"]["direction"]; -export type PeerStatus = Connection["stat"]["status"]; - export type LodestarComponents = Pick< Components, | "peerId" diff --git a/packages/beacon-node/src/network/libp2p/index.ts b/packages/beacon-node/src/network/libp2p/index.ts index bd96de0e6bbf..cdbb3fb16224 100644 --- a/packages/beacon-node/src/network/libp2p/index.ts +++ b/packages/beacon-node/src/network/libp2p/index.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {Registry} from "prom-client"; import {ENR} from "@chainsafe/discv5"; import type {Components} from "libp2p/components"; diff --git a/packages/beacon-node/src/network/libp2p/noise.ts b/packages/beacon-node/src/network/libp2p/noise.ts index 14e91c86613b..fcd4f3c9354f 100644 --- a/packages/beacon-node/src/network/libp2p/noise.ts +++ b/packages/beacon-node/src/network/libp2p/noise.ts @@ -1,4 +1,4 @@ -import type {ConnectionEncrypter} from "@libp2p/interface-connection-encrypter"; +import type {ConnectionEncrypter} from "@libp2p/interface/connection-encrypter"; import {newInstance, ChaCha20Poly1305} from "@chainsafe/as-chacha20poly1305"; import {ICryptoInterface, noise, pureJsCrypto} from "@chainsafe/libp2p-noise"; import {digest} from "@chainsafe/as-sha256"; diff --git a/packages/beacon-node/src/network/network.ts b/packages/beacon-node/src/network/network.ts index 5e91499fd10b..4453a0e92145 100644 --- a/packages/beacon-node/src/network/network.ts +++ b/packages/beacon-node/src/network/network.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {PublishOpts} from "@chainsafe/libp2p-gossipsub/types"; import {PeerScoreStatsDump} from "@chainsafe/libp2p-gossipsub/score"; import {BeaconConfig} from "@lodestar/config"; diff --git a/packages/beacon-node/src/network/peers/discover.ts b/packages/beacon-node/src/network/peers/discover.ts index 84baf67ebbd4..2090e8bedab6 100644 --- a/packages/beacon-node/src/network/peers/discover.ts +++ b/packages/beacon-node/src/network/peers/discover.ts @@ -1,6 +1,6 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {Multiaddr} from "@multiformats/multiaddr"; -import type {PeerInfo} from "@libp2p/interface-peer-info"; +import type {PeerInfo} from "@libp2p/interface/peer-info"; import {ENR} from "@chainsafe/discv5"; import {BeaconConfig} from "@lodestar/config"; import {pruneSetToMax, sleep} from "@lodestar/utils"; @@ -465,7 +465,7 @@ export class PeerDiscovery { /** Check if there is 1+ open connection with this peer */ private isPeerConnected(peerIdStr: PeerIdStr): boolean { const connections = getConnectionsMap(this.libp2p).get(peerIdStr); - return Boolean(connections && connections.some((connection) => connection.stat.status === "OPEN")); + return Boolean(connections && connections.some((connection) => connection.status === "open")); } } diff --git a/packages/beacon-node/src/network/peers/peerManager.ts b/packages/beacon-node/src/network/peers/peerManager.ts index 4b572f425c16..0ce3fdbb107c 100644 --- a/packages/beacon-node/src/network/peers/peerManager.ts +++ b/packages/beacon-node/src/network/peers/peerManager.ts @@ -1,5 +1,5 @@ -import {Connection} from "@libp2p/interface-connection"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {Connection} from "@libp2p/interface/connection"; +import {PeerId} from "@libp2p/interface/peer-id"; import {BitArray} from "@chainsafe/ssz"; import {SYNC_COMMITTEE_SUBNET_COUNT} from "@lodestar/params"; import {BeaconConfig} from "@lodestar/config"; @@ -324,7 +324,7 @@ export class PeerManager { this.metrics?.peerGoodbyeReceived.inc({reason}); const conn = getConnection(this.libp2p, peer.toString()); - if (conn && Date.now() - conn.stat.timeline.open > LONG_PEER_CONNECTION_MS) { + if (conn && Date.now() - conn.timeline.open > LONG_PEER_CONNECTION_MS) { this.metrics?.peerLongConnectionDisconnect.inc({reason}); } @@ -570,15 +570,13 @@ export class PeerManager { * dialed or connecting to us. */ private onLibp2pPeerConnect = async (evt: CustomEvent): Promise => { - const libp2pConnection = evt.detail; - const {direction, status} = libp2pConnection.stat; - const peer = libp2pConnection.remotePeer; - this.logger.verbose("peer connected", {peer: prettyPrintPeerId(peer), direction, status}); + const {direction, status, remotePeer} = evt.detail; + this.logger.verbose("peer connected", {peer: prettyPrintPeerId(remotePeer), direction, status}); // NOTE: The peerConnect event is not emitted here here, but after asserting peer relevance this.metrics?.peerConnectedEvent.inc({direction, status}); // libp2p may emit closed connection, we don't want to handle it // see https://github.com/libp2p/js-libp2p/issues/1565 - if (this.connectedPeers.has(peer.toString()) || status !== "OPEN") { + if (this.connectedPeers.has(remotePeer.toString()) || status !== "open") { return; } @@ -595,18 +593,18 @@ export class PeerManager { connectedUnixTsMs: now, relevantStatus: RelevantPeerStatus.Unknown, direction, - peerId: peer, + peerId: remotePeer, metadata: null, agentVersion: null, agentClient: null, encodingPreference: null, }; - this.connectedPeers.set(peer.toString(), peerData); + this.connectedPeers.set(remotePeer.toString(), peerData); if (direction === "outbound") { //this.pingAndStatusTimeouts(); - void this.requestPing(peer); - void this.requestStatus(peer, this.statusCache.get()); + void this.requestPing(remotePeer); + void this.requestStatus(remotePeer, this.statusCache.get()); } // AgentVersion was set in libp2p IdentifyService, 'peer:connect' event handler @@ -626,19 +624,17 @@ export class PeerManager { * The libp2p Upgrader has ended a connection */ private onLibp2pPeerDisconnect = (evt: CustomEvent): void => { - const libp2pConnection = evt.detail; - const {direction, status} = libp2pConnection.stat; - const peer = libp2pConnection.remotePeer; + const {direction, status, remotePeer} = evt.detail; // remove the ping and status timer for the peer - this.connectedPeers.delete(peer.toString()); + this.connectedPeers.delete(remotePeer.toString()); - this.logger.verbose("peer disconnected", {peer: prettyPrintPeerId(peer), direction, status}); - this.networkEventBus.emit(NetworkEvent.peerDisconnected, {peer: peer.toString()}); + this.logger.verbose("peer disconnected", {peer: prettyPrintPeerId(remotePeer), direction, status}); + this.networkEventBus.emit(NetworkEvent.peerDisconnected, {peer: remotePeer.toString()}); this.metrics?.peerDisconnectedEvent.inc({direction}); this.libp2p.peerStore - .merge(peer, {tags: {[PEER_RELEVANT_TAG]: undefined}}) - .catch((e) => this.logger.verbose("cannot untag peer", {peerId: peer.toString()}, e as Error)); + .merge(remotePeer, {tags: {[PEER_RELEVANT_TAG]: undefined}}) + .catch((e) => this.logger.verbose("cannot untag peer", {peerId: remotePeer.toString()}, e as Error)); }; private async disconnect(peer: PeerId): Promise { @@ -655,7 +651,7 @@ export class PeerManager { this.metrics?.peerGoodbyeSent.inc({reason}); const conn = getConnection(this.libp2p, peer.toString()); - if (conn && Date.now() - conn.stat.timeline.open > LONG_PEER_CONNECTION_MS) { + if (conn && Date.now() - conn.timeline.open > LONG_PEER_CONNECTION_MS) { this.metrics?.peerLongConnectionDisconnect.inc({reason}); } @@ -688,9 +684,9 @@ export class PeerManager { } for (const connections of getConnectionsMap(this.libp2p).values()) { - const openCnx = connections.find((cnx) => cnx.stat.status === "OPEN"); + const openCnx = connections.find((cnx) => cnx.status === "open"); if (openCnx) { - const direction = openCnx.stat.direction; + const direction = openCnx.direction; peersByDirection.set(direction, 1 + (peersByDirection.get(direction) ?? 0)); const peerId = openCnx.remotePeer; const peerData = this.connectedPeers.get(peerId.toString()); @@ -703,7 +699,7 @@ export class PeerManager { metrics.peerLongLivedAttnets.observe(attnets ? attnets.getTrueBitIndexes().length : 0); metrics.peerScoreByClient.observe({client}, this.peerRpcScores.getScore(peerId)); metrics.peerGossipScoreByClient.observe({client}, this.peerRpcScores.getGossipScore(peerId)); - metrics.peerConnectionLength.observe((now - openCnx.stat.timeline.open) / 1000); + metrics.peerConnectionLength.observe((now - openCnx.timeline.open) / 1000); total++; } } diff --git a/packages/beacon-node/src/network/peers/peersData.ts b/packages/beacon-node/src/network/peers/peersData.ts index 1a8fbb577295..9b27bafaa682 100644 --- a/packages/beacon-node/src/network/peers/peersData.ts +++ b/packages/beacon-node/src/network/peers/peersData.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {altair} from "@lodestar/types"; import {Encoding} from "@lodestar/reqresp"; import {ClientKind} from "./client.js"; diff --git a/packages/beacon-node/src/network/peers/score/interface.ts b/packages/beacon-node/src/network/peers/score/interface.ts index 3d6c00f38009..ba52c512d3c6 100644 --- a/packages/beacon-node/src/network/peers/score/interface.ts +++ b/packages/beacon-node/src/network/peers/score/interface.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {NetworkCoreMetrics} from "../../core/metrics.js"; export type PeerIdStr = string; diff --git a/packages/beacon-node/src/network/peers/score/store.ts b/packages/beacon-node/src/network/peers/score/store.ts index fe86e258baf8..f03064053039 100644 --- a/packages/beacon-node/src/network/peers/score/store.ts +++ b/packages/beacon-node/src/network/peers/score/store.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {MapDef, pruneSetToMax} from "@lodestar/utils"; import {NetworkCoreMetrics} from "../../core/metrics.js"; import {DEFAULT_SCORE, MAX_ENTRIES, MAX_SCORE, MIN_SCORE, SCORE_THRESHOLD} from "./constants.js"; diff --git a/packages/beacon-node/src/network/peers/utils/getConnectedPeerIds.ts b/packages/beacon-node/src/network/peers/utils/getConnectedPeerIds.ts index 11bc7acaee3a..77a61eb3c0b9 100644 --- a/packages/beacon-node/src/network/peers/utils/getConnectedPeerIds.ts +++ b/packages/beacon-node/src/network/peers/utils/getConnectedPeerIds.ts @@ -1,5 +1,5 @@ -import {Connection} from "@libp2p/interface-connection"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {Connection} from "@libp2p/interface/connection"; +import {PeerId} from "@libp2p/interface/peer-id"; import {Libp2p} from "../../interface.js"; import {getConnectionsMap} from "../../util.js"; @@ -30,5 +30,5 @@ export function hasSomeConnectedPeer(libp2p: Libp2p): boolean { } function isConnectionOpen(connection: Connection): boolean { - return connection.stat.status === "OPEN"; + return connection.status === "open"; } diff --git a/packages/beacon-node/src/network/peers/utils/prioritizePeers.ts b/packages/beacon-node/src/network/peers/utils/prioritizePeers.ts index afe43976b63e..5c486a79a48b 100644 --- a/packages/beacon-node/src/network/peers/utils/prioritizePeers.ts +++ b/packages/beacon-node/src/network/peers/utils/prioritizePeers.ts @@ -1,5 +1,5 @@ -import {PeerId} from "@libp2p/interface-peer-id"; -import {Direction} from "@libp2p/interface-connection"; +import {PeerId} from "@libp2p/interface/peer-id"; +import {Direction} from "@libp2p/interface/connection"; import {BitArray} from "@chainsafe/ssz"; import {altair, phase0} from "@lodestar/types"; import {ATTESTATION_SUBNET_COUNT, SYNC_COMMITTEE_SUBNET_COUNT} from "@lodestar/params"; diff --git a/packages/beacon-node/src/network/processor/gossipValidatorFn.ts b/packages/beacon-node/src/network/processor/gossipValidatorFn.ts index 504c833f3acd..a3f4a4aa25b4 100644 --- a/packages/beacon-node/src/network/processor/gossipValidatorFn.ts +++ b/packages/beacon-node/src/network/processor/gossipValidatorFn.ts @@ -1,4 +1,4 @@ -import {TopicValidatorResult} from "@libp2p/interface-pubsub"; +import {TopicValidatorResult} from "@libp2p/interface/pubsub"; import {ChainForkConfig} from "@lodestar/config"; import {Logger} from "@lodestar/utils"; import {Metrics} from "../../metrics/index.js"; diff --git a/packages/beacon-node/src/network/processor/types.ts b/packages/beacon-node/src/network/processor/types.ts index e3d9ea858b4e..fcb3fd90b366 100644 --- a/packages/beacon-node/src/network/processor/types.ts +++ b/packages/beacon-node/src/network/processor/types.ts @@ -1,4 +1,4 @@ -import {Message} from "@libp2p/interface-pubsub"; +import {Message} from "@libp2p/interface/pubsub"; import {Slot, SlotOptionalRoot} from "@lodestar/types"; import {GossipTopic, GossipType} from "../gossip/index.js"; import {PeerIdStr} from "../../util/peerId.js"; diff --git a/packages/beacon-node/src/network/reqresp/ReqRespBeaconNode.ts b/packages/beacon-node/src/network/reqresp/ReqRespBeaconNode.ts index bf45c1239bf6..994be87833d6 100644 --- a/packages/beacon-node/src/network/reqresp/ReqRespBeaconNode.ts +++ b/packages/beacon-node/src/network/reqresp/ReqRespBeaconNode.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {Libp2p} from "libp2p"; import {BeaconConfig} from "@lodestar/config"; import {ForkName, ForkSeq} from "@lodestar/params"; diff --git a/packages/beacon-node/src/network/reqresp/interface.ts b/packages/beacon-node/src/network/reqresp/interface.ts index 4aab7414f5c1..972e12329b68 100644 --- a/packages/beacon-node/src/network/reqresp/interface.ts +++ b/packages/beacon-node/src/network/reqresp/interface.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; /** * Rate limiter interface for inbound and outbound requests. diff --git a/packages/beacon-node/src/network/util.ts b/packages/beacon-node/src/network/util.ts index 05d170627f46..59a333c3d74d 100644 --- a/packages/beacon-node/src/network/util.ts +++ b/packages/beacon-node/src/network/util.ts @@ -1,5 +1,5 @@ -import type {PeerId} from "@libp2p/interface-peer-id"; -import type {Connection} from "@libp2p/interface-connection"; +import type {PeerId} from "@libp2p/interface/peer-id"; +import type {Connection} from "@libp2p/interface/connection"; import type {DefaultConnectionManager} from "libp2p/connection-manager/index.js"; import type {PeerIdStr} from "../util/peerId.js"; import type {Libp2p} from "./interface.js"; diff --git a/packages/beacon-node/src/node/nodejs.ts b/packages/beacon-node/src/node/nodejs.ts index e0b71c36aa94..ce2a8d530b4b 100644 --- a/packages/beacon-node/src/node/nodejs.ts +++ b/packages/beacon-node/src/node/nodejs.ts @@ -1,7 +1,7 @@ import {setMaxListeners} from "node:events"; import {Registry} from "prom-client"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {BeaconConfig} from "@lodestar/config"; import {phase0} from "@lodestar/types"; import {sleep} from "@lodestar/utils"; diff --git a/packages/beacon-node/src/sync/backfill/errors.ts b/packages/beacon-node/src/sync/backfill/errors.ts index ba86d0bbd01d..2cec1dc487ad 100644 --- a/packages/beacon-node/src/sync/backfill/errors.ts +++ b/packages/beacon-node/src/sync/backfill/errors.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {LodestarError} from "@lodestar/utils"; import {Root} from "@lodestar/types"; diff --git a/packages/beacon-node/src/util/peerId.ts b/packages/beacon-node/src/util/peerId.ts index 134a4e856f52..fa653ee8e3ee 100644 --- a/packages/beacon-node/src/util/peerId.ts +++ b/packages/beacon-node/src/util/peerId.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {base58btc} from "multiformats/bases/base58"; import {peerIdFromString} from "@libp2p/peer-id"; diff --git a/packages/beacon-node/test/e2e/network/mdns.test.ts b/packages/beacon-node/test/e2e/network/mdns.test.ts index 0b71ce47fb44..f08e57a25045 100644 --- a/packages/beacon-node/test/e2e/network/mdns.test.ts +++ b/packages/beacon-node/test/e2e/network/mdns.test.ts @@ -1,7 +1,7 @@ import sinon from "sinon"; import {expect} from "chai"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {multiaddr} from "@multiformats/multiaddr"; import {createSecp256k1PeerId} from "@libp2p/peer-id-factory"; import {SignableENR} from "@chainsafe/discv5"; diff --git a/packages/beacon-node/test/e2e/network/network.test.ts b/packages/beacon-node/test/e2e/network/network.test.ts index 13cdd6c20d71..7610bedca162 100644 --- a/packages/beacon-node/test/e2e/network/network.test.ts +++ b/packages/beacon-node/test/e2e/network/network.test.ts @@ -1,6 +1,6 @@ import sinon from "sinon"; import {expect} from "chai"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {config} from "@lodestar/config/default"; import {phase0} from "@lodestar/types"; import {sleep} from "@lodestar/utils"; diff --git a/packages/beacon-node/test/e2e/network/onWorker/dataSerialization.test.ts b/packages/beacon-node/test/e2e/network/onWorker/dataSerialization.test.ts index 552f1cfd5ae2..12841953372e 100644 --- a/packages/beacon-node/test/e2e/network/onWorker/dataSerialization.test.ts +++ b/packages/beacon-node/test/e2e/network/onWorker/dataSerialization.test.ts @@ -1,5 +1,5 @@ import {expect} from "chai"; -import {TopicValidatorResult} from "@libp2p/interface-pubsub"; +import {TopicValidatorResult} from "@libp2p/interface/pubsub"; import {BitArray} from "@chainsafe/ssz"; import {ssz} from "@lodestar/types"; import {routes} from "@lodestar/api"; diff --git a/packages/beacon-node/test/e2e/network/peers/peerManager.test.ts b/packages/beacon-node/test/e2e/network/peers/peerManager.test.ts index c714183be502..9f60ea50f065 100644 --- a/packages/beacon-node/test/e2e/network/peers/peerManager.test.ts +++ b/packages/beacon-node/test/e2e/network/peers/peerManager.test.ts @@ -1,4 +1,4 @@ -import {Connection} from "@libp2p/interface-connection"; +import {Connection} from "@libp2p/interface/connection"; import {CustomEvent} from "@libp2p/interfaces/events"; import sinon from "sinon"; import {expect} from "chai"; @@ -111,7 +111,8 @@ describe("network / peers / PeerManager", function () { await peerManager["onLibp2pPeerConnect"]( new CustomEvent("evt", { detail: { - stat: {direction: "inbound", status: "OPEN"}, + direction: "inbound", + status: "open", remotePeer: peerId1, } as Connection, }) @@ -146,7 +147,8 @@ describe("network / peers / PeerManager", function () { }); const libp2pConnectionOutboud = { - stat: {direction: "outbound", status: "OPEN"}, + direction: "outbound", + status: "open", remotePeer: peerId1, } as Connection; diff --git a/packages/beacon-node/test/perf/network/peers/util/prioritizePeers.test.ts b/packages/beacon-node/test/perf/network/peers/util/prioritizePeers.test.ts index c7d0be5d0892..b58199ea8e71 100644 --- a/packages/beacon-node/test/perf/network/peers/util/prioritizePeers.test.ts +++ b/packages/beacon-node/test/perf/network/peers/util/prioritizePeers.test.ts @@ -1,5 +1,5 @@ import {itBench} from "@dapplion/benchmark"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {createSecp256k1PeerId} from "@libp2p/peer-id-factory"; import {ATTESTATION_SUBNET_COUNT, SYNC_COMMITTEE_SUBNET_COUNT} from "@lodestar/params"; import {altair, phase0} from "@lodestar/types"; diff --git a/packages/beacon-node/test/unit/network/peers/priorization.test.ts b/packages/beacon-node/test/unit/network/peers/priorization.test.ts index d32f488b6671..48a08456204b 100644 --- a/packages/beacon-node/test/unit/network/peers/priorization.test.ts +++ b/packages/beacon-node/test/unit/network/peers/priorization.test.ts @@ -1,5 +1,5 @@ import {expect} from "chai"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {createSecp256k1PeerId} from "@libp2p/peer-id-factory"; import {BitArray} from "@chainsafe/ssz"; import {ATTESTATION_SUBNET_COUNT} from "@lodestar/params"; diff --git a/packages/beacon-node/test/unit/network/reqresp/utils.ts b/packages/beacon-node/test/unit/network/reqresp/utils.ts index d0e9b86832c4..46e729ea6256 100644 --- a/packages/beacon-node/test/unit/network/reqresp/utils.ts +++ b/packages/beacon-node/test/unit/network/reqresp/utils.ts @@ -1,5 +1,5 @@ import {expect} from "chai"; -import {Stream, StreamStat} from "@libp2p/interface-connection"; +import {Direction, ReadStatus, Stream, StreamStatus, WriteStatus} from "@libp2p/interface/connection"; import {Uint8ArrayList} from "uint8arraylist"; import {toHexString} from "@chainsafe/ssz"; import {Root} from "@lodestar/types"; @@ -35,12 +35,13 @@ export function expectEqualByteChunks(chunks: Uint8Array[], expectedChunks: Uint */ export class MockLibP2pStream implements Stream { id = "mock"; - stat = { - direction: "inbound", - timeline: { - open: Date.now(), - }, - } as StreamStat; + direction: Direction = "inbound"; + timeline = { + open: Date.now(), + }; + status: StreamStatus = "open"; + readStatus: ReadStatus = "ready"; + writeStatus: WriteStatus = "ready"; metadata = {}; source: Stream["source"]; resultChunks: Uint8Array[] = []; @@ -54,11 +55,10 @@ export class MockLibP2pStream implements Stream { } }; // eslint-disable-next-line @typescript-eslint/no-empty-function - close: Stream["close"] = () => {}; + close: Stream["close"] = async () => {}; // eslint-disable-next-line @typescript-eslint/no-empty-function - closeRead = (): void => {}; + closeRead = async (): Promise => {}; // eslint-disable-next-line @typescript-eslint/no-empty-function - closeWrite = (): void => {}; - reset: Stream["reset"] = () => this.close(); + closeWrite = async (): Promise => {}; abort: Stream["abort"] = () => this.close(); } diff --git a/packages/beacon-node/test/utils/network.ts b/packages/beacon-node/test/utils/network.ts index 89b175c3afaa..367f49d59ed0 100644 --- a/packages/beacon-node/test/utils/network.ts +++ b/packages/beacon-node/test/utils/network.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {createSecp256k1PeerId} from "@libp2p/peer-id-factory"; import {BitArray} from "@chainsafe/ssz"; import {ATTESTATION_SUBNET_COUNT, SYNC_COMMITTEE_SUBNET_COUNT} from "@lodestar/params"; diff --git a/packages/beacon-node/test/utils/node/beacon.ts b/packages/beacon-node/test/utils/node/beacon.ts index 6c62e22939d3..92b09f0e02b6 100644 --- a/packages/beacon-node/test/utils/node/beacon.ts +++ b/packages/beacon-node/test/utils/node/beacon.ts @@ -1,6 +1,6 @@ import deepmerge from "deepmerge"; import tmp from "tmp"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {createSecp256k1PeerId} from "@libp2p/peer-id-factory"; import {config as minimalConfig} from "@lodestar/config/default"; import {createBeaconConfig, createChainForkConfig, ChainConfig} from "@lodestar/config"; diff --git a/packages/beacon-node/test/utils/node/p2p.ts b/packages/beacon-node/test/utils/node/p2p.ts index 18c1495dba11..40ddfc3c5a85 100644 --- a/packages/beacon-node/test/utils/node/p2p.ts +++ b/packages/beacon-node/test/utils/node/p2p.ts @@ -1,11 +1,11 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; +import {Direction} from "@libp2p/interface/connection"; import {routes} from "@lodestar/api"; -import {PeerDirection} from "../../../src/network/index.js"; export function lodestarNodePeer( peer: PeerId, state: routes.node.PeerState, - direction: PeerDirection | null + direction: Direction | null ): routes.lodestar.LodestarNodePeer { return { peerId: peer.toString(), diff --git a/packages/beacon-node/test/utils/peer.ts b/packages/beacon-node/test/utils/peer.ts index a1e676a5fb8d..aae9df41e51a 100644 --- a/packages/beacon-node/test/utils/peer.ts +++ b/packages/beacon-node/test/utils/peer.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {createSecp256k1PeerId} from "@libp2p/peer-id-factory"; import {peerIdFromBytes} from "@libp2p/peer-id"; import {peerIdToString} from "../../src/util/peerId.js"; diff --git a/packages/cli/package.json b/packages/cli/package.json index e861f48749f8..77176fe0ff99 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -60,9 +60,9 @@ "@chainsafe/discv5": "^5.0.0", "@chainsafe/ssz": "^0.10.2", "@chainsafe/threads": "^1.11.1", - "@libp2p/crypto": "^1.0.0", - "@libp2p/peer-id": "^2.0.3", - "@libp2p/peer-id-factory": "^2.0.3", + "@libp2p/crypto": "^2.0.2", + "@libp2p/peer-id": "^3.0.1", + "@libp2p/peer-id-factory": "^3.0.2", "@lodestar/api": "^1.10.0", "@lodestar/beacon-node": "^1.10.0", "@lodestar/config": "^1.10.0", diff --git a/packages/cli/src/cmds/beacon/initPeerIdAndEnr.ts b/packages/cli/src/cmds/beacon/initPeerIdAndEnr.ts index 9313b1f47f88..1bc6f8e5fd00 100644 --- a/packages/cli/src/cmds/beacon/initPeerIdAndEnr.ts +++ b/packages/cli/src/cmds/beacon/initPeerIdAndEnr.ts @@ -1,7 +1,7 @@ import fs from "node:fs"; import path from "node:path"; import os from "node:os"; -import type {PeerId} from "@libp2p/interface-peer-id"; +import type {PeerId} from "@libp2p/interface/peer-id"; import {createSecp256k1PeerId} from "@libp2p/peer-id-factory"; import {Multiaddr} from "@multiformats/multiaddr"; import {createKeypairFromPeerId, SignableENR} from "@chainsafe/discv5"; diff --git a/packages/cli/src/config/peerId.ts b/packages/cli/src/config/peerId.ts index bc47f8583831..9ddd26460846 100644 --- a/packages/cli/src/config/peerId.ts +++ b/packages/cli/src/config/peerId.ts @@ -1,4 +1,4 @@ -import type {PeerId} from "@libp2p/interface-peer-id"; +import type {PeerId} from "@libp2p/interface/peer-id"; import {peerIdFromBytes} from "@libp2p/peer-id"; import {createFromPrivKey, createFromPubKey} from "@libp2p/peer-id-factory"; import {unmarshalPrivateKey, unmarshalPublicKey} from "@libp2p/crypto/keys"; diff --git a/packages/reqresp/package.json b/packages/reqresp/package.json index cee3e12d90ec..8307b98df520 100644 --- a/packages/reqresp/package.json +++ b/packages/reqresp/package.json @@ -55,8 +55,7 @@ }, "dependencies": { "@chainsafe/fast-crc32c": "^4.1.1", - "@libp2p/interface-connection": "^5.1.0", - "@libp2p/interface-peer-id": "^2.0.2", + "@libp2p/interface": "^0.1.1", "@lodestar/config": "^1.10.0", "@lodestar/params": "^1.10.0", "@lodestar/utils": "^1.10.0", @@ -70,10 +69,10 @@ "devDependencies": { "@lodestar/logger": "^1.10.0", "@lodestar/types": "^1.10.0", - "libp2p": "0.45.9" + "libp2p": "0.46.3" }, "peerDependencies": { - "libp2p": "~0.45.0" + "libp2p": "~0.46.3" }, "keywords": [ "ethereum", diff --git a/packages/reqresp/src/ReqResp.ts b/packages/reqresp/src/ReqResp.ts index b2e1d34ef502..e79b5737bc91 100644 --- a/packages/reqresp/src/ReqResp.ts +++ b/packages/reqresp/src/ReqResp.ts @@ -1,6 +1,6 @@ import {setMaxListeners} from "node:events"; -import {Connection, Stream} from "@libp2p/interface-connection"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {Connection, Stream} from "@libp2p/interface/connection"; +import {PeerId} from "@libp2p/interface/peer-id"; import type {Libp2p} from "libp2p"; import {Logger} from "@lodestar/utils"; import {getMetrics, Metrics, MetricsRegister} from "./metrics.js"; diff --git a/packages/reqresp/src/rate_limiter/ReqRespRateLimiter.ts b/packages/reqresp/src/rate_limiter/ReqRespRateLimiter.ts index 1df396a1f8f8..36bbe7df5ff2 100644 --- a/packages/reqresp/src/rate_limiter/ReqRespRateLimiter.ts +++ b/packages/reqresp/src/rate_limiter/ReqRespRateLimiter.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {InboundRateLimitQuota, ReqRespRateLimiterOpts} from "../types.js"; import {RateLimiterGRCA} from "./rateLimiterGRCA.js"; diff --git a/packages/reqresp/src/request/index.ts b/packages/reqresp/src/request/index.ts index 966dfb2b254a..e1923c8856b4 100644 --- a/packages/reqresp/src/request/index.ts +++ b/packages/reqresp/src/request/index.ts @@ -1,5 +1,5 @@ import {pipe} from "it-pipe"; -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import type {Libp2p} from "libp2p"; import {Uint8ArrayList} from "uint8arraylist"; import {ErrorAborted, Logger, withTimeout, TimeoutError} from "@lodestar/utils"; @@ -116,7 +116,7 @@ export async function* sendRequest( const timerTTFB = metrics?.outgoingResponseTTFB.startTimer({method}); // Parse protocol selected by the responder - const protocolId = stream.stat.protocol ?? "unknown"; + const protocolId = stream.protocol ?? "unknown"; const protocol = protocolsMap.get(protocolId); if (!protocol) throw Error(`dialProtocol selected unknown protocolId ${protocolId}`); @@ -203,7 +203,7 @@ export async function* sendRequest( // Necessary to call `stream.close()` since collectResponses() may break out of the source before exhausting it // `stream.close()` libp2p-mplex will .end() the source (it-pushable instance) // If collectResponses() exhausts the source, it-pushable.end() can be safely called multiple times - stream.close(); + await stream.close(); } } catch (e) { logger.verbose("Req error", logCtx, e as Error); diff --git a/packages/reqresp/src/response/index.ts b/packages/reqresp/src/response/index.ts index 0d1948c4a983..288111c12093 100644 --- a/packages/reqresp/src/response/index.ts +++ b/packages/reqresp/src/response/index.ts @@ -1,6 +1,6 @@ import {pipe} from "it-pipe"; -import {PeerId} from "@libp2p/interface-peer-id"; -import {Stream} from "@libp2p/interface-connection"; +import {PeerId} from "@libp2p/interface/peer-id"; +import {Stream} from "@libp2p/interface/connection"; import {Uint8ArrayList} from "uint8arraylist"; import {Logger, TimeoutError, withTimeout} from "@lodestar/utils"; import {prettyPrintPeerId} from "../utils/index.js"; @@ -124,7 +124,7 @@ export async function handleRequest({ // If streak.sink throws, libp2p-mplex will close stream.source // If `requestDecode()` throws the stream.source must be closed manually // To ensure the stream.source it-pushable instance is always closed, stream.close() is called always - stream.close(); + await stream.close(); // TODO: It may happen that stream.sink returns before returning stream.source first, // so you never see "Resp received request" in the logs and the response ends without diff --git a/packages/reqresp/src/types.ts b/packages/reqresp/src/types.ts index 679c5f557160..a9fff1d70252 100644 --- a/packages/reqresp/src/types.ts +++ b/packages/reqresp/src/types.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {BeaconConfig, ForkDigestContext} from "@lodestar/config"; import {ForkName} from "@lodestar/params"; import {LodestarError} from "@lodestar/utils"; diff --git a/packages/reqresp/src/utils/peerId.ts b/packages/reqresp/src/utils/peerId.ts index db37b718c94a..7f62ebd2171f 100644 --- a/packages/reqresp/src/utils/peerId.ts +++ b/packages/reqresp/src/utils/peerId.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; export function prettyPrintPeerId(peerId: PeerId): string { const id = peerId.toString(); diff --git a/packages/reqresp/test/unit/request/index.test.ts b/packages/reqresp/test/unit/request/index.test.ts index 3a992f81d644..a056d8055668 100644 --- a/packages/reqresp/test/unit/request/index.test.ts +++ b/packages/reqresp/test/unit/request/index.test.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import all from "it-all"; import {pipe} from "it-pipe"; import {expect} from "chai"; diff --git a/packages/reqresp/test/unit/response/index.test.ts b/packages/reqresp/test/unit/response/index.test.ts index 28d6a71b54b0..7298a21dccbd 100644 --- a/packages/reqresp/test/unit/response/index.test.ts +++ b/packages/reqresp/test/unit/response/index.test.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {expect} from "chai"; import {LodestarError, fromHex} from "@lodestar/utils"; import {getEmptyLogger} from "@lodestar/logger/empty"; diff --git a/packages/reqresp/test/utils/index.ts b/packages/reqresp/test/utils/index.ts index aae6e5fdcf3c..8ad11bbd30b2 100644 --- a/packages/reqresp/test/utils/index.ts +++ b/packages/reqresp/test/utils/index.ts @@ -1,4 +1,4 @@ -import {Stream, StreamStat} from "@libp2p/interface-connection"; +import {Direction, ReadStatus, Stream, StreamStatus, WriteStatus} from "@libp2p/interface/connection"; import {expect} from "chai"; import {Uint8ArrayList} from "uint8arraylist"; import {toHexString} from "@chainsafe/ssz"; @@ -35,13 +35,15 @@ export function expectInEqualByteChunks(chunks: Uint8Array[], expectedChunks: Ui * and capture the response with a sink accessible via `this.resultChunks` */ export class MockLibP2pStream implements Stream { + protocol: string; id = "mock"; - stat = { - direction: "inbound", - timeline: { - open: Date.now(), - }, - } as StreamStat; + direction: Direction = "inbound"; + status: StreamStatus = "open"; + readStatus: ReadStatus = "ready"; + writeStatus: WriteStatus = "ready"; + timeline = { + open: Date.now(), + }; metadata = {}; source: Stream["source"]; resultChunks: Uint8Array[] = []; @@ -50,7 +52,7 @@ export class MockLibP2pStream implements Stream { this.source = Array.isArray(requestChunks) ? arrToSource(requestChunks) : (requestChunks as AsyncGenerator); - this.stat.protocol = protocol ?? "mock"; + this.protocol = protocol ?? "mock"; } sink: Stream["sink"] = async (source) => { @@ -60,12 +62,11 @@ export class MockLibP2pStream implements Stream { }; // eslint-disable-next-line @typescript-eslint/no-empty-function - close: Stream["close"] = () => {}; + close: Stream["close"] = async () => {}; // eslint-disable-next-line @typescript-eslint/no-empty-function - closeRead = (): void => {}; + closeRead = async (): Promise => {}; // eslint-disable-next-line @typescript-eslint/no-empty-function - closeWrite = (): void => {}; - reset: Stream["reset"] = () => this.close(); + closeWrite = async (): Promise => {}; abort: Stream["abort"] = () => this.close(); } diff --git a/packages/reqresp/test/utils/peer.ts b/packages/reqresp/test/utils/peer.ts index 863551d0ee21..34af7d2a9317 100644 --- a/packages/reqresp/test/utils/peer.ts +++ b/packages/reqresp/test/utils/peer.ts @@ -1,4 +1,4 @@ -import {PeerId} from "@libp2p/interface-peer-id"; +import {PeerId} from "@libp2p/interface/peer-id"; import {peerIdFromBytes} from "@libp2p/peer-id"; /** diff --git a/yarn.lock b/yarn.lock index 824945c70371..090b220a6ad8 100644 --- a/yarn.lock +++ b/yarn.lock @@ -562,59 +562,49 @@ resolved "https://registry.yarnpkg.com/@chainsafe/is-ip/-/is-ip-2.0.1.tgz#62cb285669d91f88fd9fa285048dde3882f0993b" integrity sha512-nqSJ8u2a1Rv9FYbyI8qpDhTYujaKEyLknNrTejLYoSWmdeg+2WB7R6BZqPZYfrJzDxVi3rl6ZQuoaEvpKRZWgQ== -"@chainsafe/libp2p-gossipsub@^9.1.0": - version "9.1.0" - resolved "https://registry.yarnpkg.com/@chainsafe/libp2p-gossipsub/-/libp2p-gossipsub-9.1.0.tgz#0aee7960426e323f1da5774e16742b0ba9a015e6" - integrity sha512-zc1Jx0DcVNH0iAncDlyd0/rAN9mWCpIxrmrw8eC6/gvHDmi24y8orDH8Npj2Naydh/ukeDhG9Iqx4Dnoe8V51w== - dependencies: - "@libp2p/crypto" "^1.0.3" - "@libp2p/interface-connection" "^5.0.1" - "@libp2p/interface-connection-manager" "^3.0.1" - "@libp2p/interface-keys" "^1.0.3" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interface-peer-store" "^2.0.3" - "@libp2p/interface-pubsub" "^4.0.0" - "@libp2p/interface-registrar" "^2.0.3" - "@libp2p/interfaces" "^3.2.0" - "@libp2p/logger" "^2.0.0" - "@libp2p/peer-id" "^2.0.0" - "@libp2p/peer-record" "^5.0.0" - "@libp2p/pubsub" "^7.0.1" - "@libp2p/topology" "^4.0.0" - "@multiformats/multiaddr" "^12.0.0" +"@chainsafe/libp2p-gossipsub@^10.0.0": + version "10.0.0" + resolved "https://registry.yarnpkg.com/@chainsafe/libp2p-gossipsub/-/libp2p-gossipsub-10.0.0.tgz#581ea3f4248567a20b53c9b81f8ae414311b96fb" + integrity sha512-ha4Sb78h3agTPlwl1gKLYUfGH41kEO9L50Ag3bj9D2tbsImhG4r/ahA4CD+21lbhSLxbkNirSZb955dg1HO65g== + dependencies: + "@libp2p/crypto" "^2.0.0" + "@libp2p/interface" "^0.1.0" + "@libp2p/interface-internal" "^0.1.0" + "@libp2p/logger" "^3.0.0" + "@libp2p/peer-id" "^3.0.0" + "@libp2p/pubsub" "^8.0.0" + "@multiformats/multiaddr" "^12.1.3" abortable-iterator "^5.0.1" - denque "^1.5.0" + denque "^2.1.0" it-length-prefixed "^9.0.1" it-pipe "^3.0.1" - it-pushable "^3.1.0" - multiformats "^11.0.0" - protobufjs "^6.11.2" - uint8arraylist "^2.3.2" - uint8arrays "^4.0.2" - -"@chainsafe/libp2p-noise@^12.0.1": - version "12.0.1" - resolved "https://registry.yarnpkg.com/@chainsafe/libp2p-noise/-/libp2p-noise-12.0.1.tgz#140a4c2e6976fe60e6ccb391a9493b83a28430dc" - integrity sha512-VYuc5a3raIcCmv4F+LOfez7/9rmMgfjNo9h66cspLJKHuWgpzzIRRL9srVth6VC5DMjftExHM0aZv47Tf5govQ== - dependencies: - "@libp2p/crypto" "^1.0.11" - "@libp2p/interface-connection-encrypter" "^4.0.0" - "@libp2p/interface-keys" "^1.0.6" - "@libp2p/interface-metrics" "^4.0.4" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/logger" "^2.0.5" - "@libp2p/peer-id" "^2.0.0" - "@noble/hashes" "^1.3.0" - "@stablelib/chacha20poly1305" "^1.0.1" - "@stablelib/x25519" "^1.0.3" + it-pushable "^3.2.0" + multiformats "^12.0.1" + protobufjs "^7.2.4" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" + +"@chainsafe/libp2p-noise@^13.0.0": + version "13.0.0" + resolved "https://registry.yarnpkg.com/@chainsafe/libp2p-noise/-/libp2p-noise-13.0.0.tgz#6fa9352945d5dee79d33051ee4095e6ee65969c1" + integrity sha512-+kRW5GSTGYB42WjFa1f7Wc/1+VWLffOhwChi+CbPceidMHM5pbOQNb+xQM2/aqLre+A+WnBOKEopME7dnoqLNQ== + dependencies: + "@libp2p/crypto" "^2.0.0" + "@libp2p/interface" "^0.1.0" + "@libp2p/logger" "^3.0.0" + "@libp2p/peer-id" "^3.0.0" + "@noble/ciphers" "^0.1.4" + "@noble/curves" "^1.1.0" + "@noble/hashes" "^1.3.1" + it-byte-stream "^1.0.0" it-length-prefixed "^9.0.1" - it-pair "^2.0.2" - it-pb-stream "^4.0.1" + it-length-prefixed-stream "^1.0.0" + it-pair "^2.0.6" it-pipe "^3.0.1" it-stream-types "^2.0.1" protons-runtime "^5.0.0" - uint8arraylist "^2.3.2" - uint8arrays "^4.0.2" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" "@chainsafe/netmask@^2.0.0": version "2.0.0" @@ -1468,21 +1458,18 @@ write-pkg "4.0.0" yargs "16.2.0" -"@libp2p/bootstrap@^8.0.0": - version "8.0.0" - resolved "https://registry.yarnpkg.com/@libp2p/bootstrap/-/bootstrap-8.0.0.tgz#dc9fc3f0367953b69c7b726a205ba5d17a8eac50" - integrity sha512-xbaJ+ybx1FGsi8FeGl9g1Wk6P2zf5/Thdk9Fe1qXV0O0xIW0xRWrefOYG5Dvt+BV54C/zlnQ4CG+Xs+Rr7wsbA== +"@libp2p/bootstrap@^9.0.2": + version "9.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/bootstrap/-/bootstrap-9.0.2.tgz#a9c4374e715f3dda41653a293ee8936c34732fda" + integrity sha512-G16viuLQr+AHVnXtA1p9XQqJHo3I1mlScARroDfSG32uU5PgZpQRB2c7YoUy5vVTDzeIf82sq70HIOmwrr9ZTw== dependencies: - "@libp2p/interface-peer-discovery" "^2.0.0" - "@libp2p/interface-peer-info" "^1.0.7" - "@libp2p/interface-peer-store" "^2.0.0" - "@libp2p/interfaces" "^3.0.3" - "@libp2p/logger" "^2.0.1" - "@libp2p/peer-id" "^2.0.0" - "@multiformats/mafmt" "^12.0.0" - "@multiformats/multiaddr" "^12.0.0" + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + "@libp2p/peer-id" "^3.0.1" + "@multiformats/mafmt" "^12.1.2" + "@multiformats/multiaddr" "^12.1.3" -"@libp2p/crypto@^1.0.0", "@libp2p/crypto@^1.0.11", "@libp2p/crypto@^1.0.17", "@libp2p/crypto@^1.0.3": +"@libp2p/crypto@^1.0.0": version "1.0.17" resolved "https://registry.yarnpkg.com/@libp2p/crypto/-/crypto-1.0.17.tgz#e64043328c0c866bf7f4cc8560b4f483e9c745dc" integrity sha512-Oeg0Eb/EvAho0gVkOgemXEgrVxWaT3x/DpFgkBdZ9qGxwq75w/E/oPc7souqBz+l1swfz37GWnwV7bIb4Xv5Ag== @@ -1497,99 +1484,35 @@ uint8arraylist "^2.4.3" uint8arrays "^4.0.2" -"@libp2p/interface-address-manager@^3.0.0": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-address-manager/-/interface-address-manager-3.0.1.tgz#050701e904c03ee5f2c974b734cbaab1f5b7ac59" - integrity sha512-8N1nfOtZ/CnZ/cL0Bnj59fhcSs7orI4evmNVsv2DM1VaNHXqc9tPy8JmQE2HRjrUXeUPwtzzG2eoP7l0ZYdC0g== - dependencies: - "@multiformats/multiaddr" "^12.0.0" - -"@libp2p/interface-connection-encrypter@^4.0.0": - version "4.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-connection-encrypter/-/interface-connection-encrypter-4.0.1.tgz#8eea0889fb5a7bafaf331ab0e6f2d341e0734c56" - integrity sha512-fOtZpaFL2f5vID/RaBpVMAR9OKx5DmDT/yMEFTCarNc6Bb37fWwClI4WNCtoVbDQwcnr4H4ZIo0+9yCxjEIjjQ== - dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - it-stream-types "^2.0.1" - -"@libp2p/interface-connection-gater@^3.0.0": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-connection-gater/-/interface-connection-gater-3.0.1.tgz#073080a7703d7525e0ea6d64bb3f951e0a7728a9" - integrity sha512-3a+EmcKFIdYVM6tmmIKZt/4fREPApA/Z/PZHOEa4lqJA9c/BHO1HTq0YzEoYsptudYTcdhQLgpYzh8FVhfZGDg== - dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-peer-id" "^2.0.0" - "@multiformats/multiaddr" "^12.0.0" - -"@libp2p/interface-connection-manager@^3.0.0", "@libp2p/interface-connection-manager@^3.0.1": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-connection-manager/-/interface-connection-manager-3.0.1.tgz#2181e28e62f15e33323a293147f3da85b537939d" - integrity sha512-7ZAvzOWfHs3BtaoZoWsT+Ks1bo6HjyRMq1SJdFWDJ+ZkYEzrf6sdtQwsX8eXhwRDO6PuzpUDqLZ9TNQ2GVKEEw== - dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interfaces" "^3.0.0" - "@libp2p/peer-collections" "^3.0.1" - "@multiformats/multiaddr" "^12.0.0" - -"@libp2p/interface-connection@^5.0.0", "@libp2p/interface-connection@^5.0.1", "@libp2p/interface-connection@^5.0.2", "@libp2p/interface-connection@^5.1.0", "@libp2p/interface-connection@^5.1.1": - version "5.1.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-connection/-/interface-connection-5.1.1.tgz#da0572c76da43629d52b8bec6cd092143fae421d" - integrity sha512-ytknMbuuNW72LYMmTP7wFGP5ZTaUSGBCmV9f+uQ55XPcFHtKXLtKWVU/HE8IqPmwtyU8AO7veGoJ/qStMHNRVA== +"@libp2p/crypto@^2.0.0", "@libp2p/crypto@^2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/crypto/-/crypto-2.0.2.tgz#c1c950e452c7a417631bf5b2b6bda96292bf35ee" + integrity sha512-CmKYBUpU/WKeLSGtqCtsPubwL7wS50toyO1wDNZsbstFDEXZB5YrAnSwPiSzXG33rgeoGW5VNsUShJvFylVPcw== dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interfaces" "^3.0.0" - "@multiformats/multiaddr" "^12.0.0" - it-stream-types "^2.0.1" + "@libp2p/interface" "^0.1.1" + "@noble/ed25519" "^1.6.0" + "@noble/secp256k1" "^1.5.4" + multiformats "^12.0.1" + node-forge "^1.1.0" + protons-runtime "^5.0.0" uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" -"@libp2p/interface-content-routing@^2.0.0", "@libp2p/interface-content-routing@^2.1.0": - version "2.1.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-content-routing/-/interface-content-routing-2.1.1.tgz#7c56acad48f59feb9f0c6dd637e73d0e4eebd510" - integrity sha512-nRPOUWgq1K1fDr3FKW93Tip7aH8AFefCw3nJygL4crepxWTSGw95s1GyDpC7t0RJkWTRNHsqZvsFsJ9FkHExKw== - dependencies: - "@libp2p/interface-peer-info" "^1.0.0" - "@libp2p/interfaces" "^3.0.0" - multiformats "^11.0.0" - -"@libp2p/interface-keychain@^2.0.0", "@libp2p/interface-keychain@^2.0.3", "@libp2p/interface-keychain@^2.0.4": - version "2.0.5" - resolved "https://registry.yarnpkg.com/@libp2p/interface-keychain/-/interface-keychain-2.0.5.tgz#6ce104f38cf07ad72c9dfbe471a689f4ea4b4687" - integrity sha512-mb7QNgn9fIvC7CaJCi06GJ+a6DN6RVT9TmEi0NmedZGATeCArPeWWG7r7IfxNVXb9cVOOE1RzV1swK0ZxEJF9Q== +"@libp2p/interface-internal@^0.1.0", "@libp2p/interface-internal@^0.1.2": + version "0.1.2" + resolved "https://registry.yarnpkg.com/@libp2p/interface-internal/-/interface-internal-0.1.2.tgz#790ff22961eed335bf803b3650e35ad299be5ab8" + integrity sha512-Ehz3+ry3VfzamoWwMyx/ltnTP4tM4OdQItRj7C6BPMd7V93H4EFqXL9zrXrNHV/ZGnayx3sIiuqb3pCDIoU5bQ== dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - multiformats "^11.0.0" + "@libp2p/interface" "^0.1.1" + "@libp2p/peer-collections" "^4.0.2" + "@multiformats/multiaddr" "^12.1.3" + uint8arraylist "^2.4.3" -"@libp2p/interface-keys@^1.0.2", "@libp2p/interface-keys@^1.0.3", "@libp2p/interface-keys@^1.0.6": +"@libp2p/interface-keys@^1.0.2": version "1.0.8" resolved "https://registry.yarnpkg.com/@libp2p/interface-keys/-/interface-keys-1.0.8.tgz#2c6b55136113ae7cf78133d3c459cdf0455b29ae" integrity sha512-CJ1SlrwuoHMquhEEWS77E+4vv7hwB7XORkqzGQrPQmA9MRdIEZRS64bA4JqCLUDa4ltH0l+U1vp0oZHLT67NEA== -"@libp2p/interface-libp2p@^3.1.0", "@libp2p/interface-libp2p@^3.2.0": - version "3.2.0" - resolved "https://registry.yarnpkg.com/@libp2p/interface-libp2p/-/interface-libp2p-3.2.0.tgz#875df729edcb43aee7f8b91191b7fc16d83cb912" - integrity sha512-Vow6xNdjpQ0M/Kt3EDz1qE/Os5OZUyhFt0YTPU5Fp3/kXw/6ocsxYq/Bzird/96gjUjU5/i+Vukn4WgctJf55Q== - dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-content-routing" "^2.0.0" - "@libp2p/interface-keychain" "^2.0.0" - "@libp2p/interface-metrics" "^4.0.0" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interface-peer-info" "^1.0.0" - "@libp2p/interface-peer-routing" "^1.0.0" - "@libp2p/interface-peer-store" "^2.0.0" - "@libp2p/interface-registrar" "^2.0.0" - "@libp2p/interface-transport" "^4.0.0" - "@libp2p/interfaces" "^3.0.0" - "@multiformats/multiaddr" "^12.0.0" - -"@libp2p/interface-metrics@^4.0.0", "@libp2p/interface-metrics@^4.0.2", "@libp2p/interface-metrics@^4.0.4": - version "4.0.8" - resolved "https://registry.yarnpkg.com/@libp2p/interface-metrics/-/interface-metrics-4.0.8.tgz#06eb45588737d72f074c70df8d1ef067a2d7cf71" - integrity sha512-1b9HjYyJH0m35kvPHipuoz2EtYCxyq34NUhuV8VK1VNtrouMpA3uCKp5FI7yHCA6V6+ux1R3UriKgNFOSGbIXQ== - dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-peer-discovery@^2.0.0": version "2.0.0" resolved "https://registry.yarnpkg.com/@libp2p/interface-peer-discovery/-/interface-peer-discovery-2.0.0.tgz#90f176cfd202f5a362912386199e64f8b1e0fc53" @@ -1605,7 +1528,7 @@ dependencies: multiformats "^11.0.0" -"@libp2p/interface-peer-info@^1.0.0", "@libp2p/interface-peer-info@^1.0.1", "@libp2p/interface-peer-info@^1.0.3", "@libp2p/interface-peer-info@^1.0.7", "@libp2p/interface-peer-info@^1.0.8": +"@libp2p/interface-peer-info@^1.0.0", "@libp2p/interface-peer-info@^1.0.1": version "1.0.10" resolved "https://registry.yarnpkg.com/@libp2p/interface-peer-info/-/interface-peer-info-1.0.10.tgz#566026de95a0817b9e853c982b313541b7960c0b" integrity sha512-HQlo8NwQjMyamCHJrnILEZz+YwEOXCB2sIIw3slIrhVUYeYlTaia1R6d9umaAeLHa255Zmdm4qGH8rJLRqhCcg== @@ -1613,97 +1536,39 @@ "@libp2p/interface-peer-id" "^2.0.0" "@multiformats/multiaddr" "^12.0.0" -"@libp2p/interface-peer-routing@^1.0.0", "@libp2p/interface-peer-routing@^1.1.0": - version "1.1.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-peer-routing/-/interface-peer-routing-1.1.1.tgz#b4d3f51d996ce0ea19773db45aff4684e247e6fb" - integrity sha512-/XEhwob9qXjdmI8PBcc+qFin32xmtyoC58nRpq8RliqHY5uOVWiHfZoNtdOXIsNvzVvq5FqlHOWt71ofxXTtlg== - dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interface-peer-info" "^1.0.0" - "@libp2p/interfaces" "^3.0.0" - -"@libp2p/interface-peer-store@^2.0.0", "@libp2p/interface-peer-store@^2.0.3", "@libp2p/interface-peer-store@^2.0.4": - version "2.0.4" - resolved "https://registry.yarnpkg.com/@libp2p/interface-peer-store/-/interface-peer-store-2.0.4.tgz#5e9961b37094341216301285edf6fd73f3e796aa" - integrity sha512-jNvBK3O1JPJqSiDN2vkb+PV8bTPnYdP54nxsLtut1BWukNm610lwzwleV7CetFI4bJCn6g+BgBvvq8fdADy0tA== - dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - "@multiformats/multiaddr" "^12.0.0" - -"@libp2p/interface-pubsub@^4.0.0", "@libp2p/interface-pubsub@^4.0.1": - version "4.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/interface-pubsub/-/interface-pubsub-4.0.1.tgz#27f85b43ced13cf3382629a38f309f7fc7b45bec" - integrity sha512-PIc5V/J98Yr1ZTHh8lQshP7GdVUh+pKNIqj6wGaDmXs8oQLB40qKCjcpHQNlAnv2e1Bh9mEH2GXv5sGZOA651A== - dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interfaces" "^3.0.0" - it-pushable "^3.1.3" - uint8arraylist "^2.4.3" - -"@libp2p/interface-record@^2.0.1", "@libp2p/interface-record@^2.0.6": - version "2.0.7" - resolved "https://registry.yarnpkg.com/@libp2p/interface-record/-/interface-record-2.0.7.tgz#d083776e465cfa66d10e1d3c8e015677a9fc7635" - integrity sha512-AFPytZWI+p8FJWP0xuK5zbSjalLAOIMzEed2lBKdRWvdGBQUHt9ENLTkfkI9G7p/Pp3hlhVzzBXdIErKd+0GxQ== - dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - uint8arraylist "^2.4.3" - -"@libp2p/interface-registrar@^2.0.0", "@libp2p/interface-registrar@^2.0.11", "@libp2p/interface-registrar@^2.0.12", "@libp2p/interface-registrar@^2.0.3": - version "2.0.12" - resolved "https://registry.yarnpkg.com/@libp2p/interface-registrar/-/interface-registrar-2.0.12.tgz#a74b59df7b6c345d8bb45d310469b2d5f923e9bf" - integrity sha512-EyCi2bycC2rn3oPB4Swr7EqBsvcaWd6RcqR6zsImNIG9BKc4/R1gl6iaF861JaELYgYmzBMS31x1rQpVz5UekQ== - dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-peer-id" "^2.0.0" - -"@libp2p/interface-stream-muxer@^4.0.0", "@libp2p/interface-stream-muxer@^4.1.2": - version "4.1.2" - resolved "https://registry.yarnpkg.com/@libp2p/interface-stream-muxer/-/interface-stream-muxer-4.1.2.tgz#f0a5edb906ec784d991b9421a024f0f21ebdaab4" - integrity sha512-dQJcn67UaAa8YQFRJDhbo4uT453z/2lCzD/ZwTk1YOqJxATXbXgVcB8dXDQFEUiUX3ZjVQ1IBu+NlQd+IZ++zw== +"@libp2p/interface@^0.1.0", "@libp2p/interface@^0.1.1": + version "0.1.1" + resolved "https://registry.yarnpkg.com/@libp2p/interface/-/interface-0.1.1.tgz#c1853bfe86bcd5a4b209891e501d6d208a065b77" + integrity sha512-Uk+4YnEShx4gfzweYdJCHdLxcA1gAnTiZ8vlvr5DnSHJrg8yUN6VYkk96W3iJQ7H7hqV/ULIoIRQLHjLtDDCkw== dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interfaces" "^3.0.0" - "@libp2p/logger" "^2.0.7" + "@multiformats/multiaddr" "^12.1.3" abortable-iterator "^5.0.1" - any-signal "^4.1.1" - it-pushable "^3.1.3" + it-pushable "^3.2.0" it-stream-types "^2.0.1" + multiformats "^12.0.1" + p-defer "^4.0.0" uint8arraylist "^2.4.3" -"@libp2p/interface-transport@^4.0.0": - version "4.0.3" - resolved "https://registry.yarnpkg.com/@libp2p/interface-transport/-/interface-transport-4.0.3.tgz#8cc63bb4863ece507cbc54bff167fc7588fd3a85" - integrity sha512-jXFQ3blhFMEyQbFw/U8Glo3F/fUO5LEaX5HIdeqNpCliK+XnwTfpkcaG+WsJrcApWK4FFyUHc+GGqiWR0hAFFg== - dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-stream-muxer" "^4.0.0" - "@libp2p/interfaces" "^3.0.0" - "@multiformats/multiaddr" "^12.0.0" - it-stream-types "^2.0.1" - -"@libp2p/interfaces@^3.0.0", "@libp2p/interfaces@^3.0.2", "@libp2p/interfaces@^3.0.3", "@libp2p/interfaces@^3.2.0", "@libp2p/interfaces@^3.3.1": +"@libp2p/interfaces@^3.0.0", "@libp2p/interfaces@^3.0.2", "@libp2p/interfaces@^3.2.0", "@libp2p/interfaces@^3.3.1": version "3.3.1" resolved "https://registry.yarnpkg.com/@libp2p/interfaces/-/interfaces-3.3.1.tgz#519c77c030b10d776250bbebf65990af53ccb2ee" integrity sha512-3N+goQt74SmaVOjwpwMPKLNgh1uDQGw8GD12c40Kc86WOq0qvpm3NfACW+H8Su2X6KmWjCSMzk9JWs9+8FtUfg== -"@libp2p/keychain@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@libp2p/keychain/-/keychain-2.0.0.tgz#8776233e9cccabc197963a8e54d10fb014b35120" - integrity sha512-BJMqZCR6Bt3snxOeszKr/3+Y35pb3hZkuiaVP7vXfC5ID9RuFRGqAHdGzz+FVqow1XZSuUTNrL/NydF1TvJHRw== +"@libp2p/keychain@^3.0.2": + version "3.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/keychain/-/keychain-3.0.2.tgz#e4b6dd31c504b3246209c7bf3538adbf3e54bb44" + integrity sha512-pAw/Te1q2F5HYQk+fJl64XOzOf1MTIptdYI0BIGKrx28d96zOe78fPEGqvj6rLvrHnKGa7PRj/BsLcmRS9OF8Q== dependencies: - "@libp2p/crypto" "^1.0.11" - "@libp2p/interface-keychain" "^2.0.3" - "@libp2p/interface-peer-id" "^2.0.1" - "@libp2p/interfaces" "^3.3.1" - "@libp2p/logger" "^2.0.5" - "@libp2p/peer-id" "^2.0.1" - interface-datastore "^8.0.0" + "@libp2p/crypto" "^2.0.2" + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + "@libp2p/peer-id" "^3.0.1" + interface-datastore "^8.2.0" merge-options "^3.0.4" sanitize-filename "^1.6.3" - uint8arrays "^4.0.3" + uint8arrays "^4.0.4" -"@libp2p/logger@^2.0.0", "@libp2p/logger@^2.0.1", "@libp2p/logger@^2.0.2", "@libp2p/logger@^2.0.5", "@libp2p/logger@^2.0.7", "@libp2p/logger@^2.1.1": +"@libp2p/logger@^2.0.0": version "2.1.1" resolved "https://registry.yarnpkg.com/@libp2p/logger/-/logger-2.1.1.tgz#e12e6c320ea64252af954bcec996895098d1cd36" integrity sha512-2UbzDPctg3cPupF6jrv6abQnAUTrbLybNOj0rmmrdGm1cN2HJ1o/hBu0sXuq4KF9P1h/eVRn1HIRbVIEKnEJrA== @@ -1714,83 +1579,88 @@ interface-datastore "^8.2.0" multiformats "^11.0.2" -"@libp2p/mdns@^8.0.0": - version "8.0.0" - resolved "https://registry.yarnpkg.com/@libp2p/mdns/-/mdns-8.0.0.tgz#250e498bb0b5d3a4b253460ef310598033b4b2c0" - integrity sha512-/q2qDWGzZpv2/LmvlwsImoEwjOhmaO9H7HDFloEs2D1+rT0dRFuQpXHAm7/sCLwx9PtmSUZp/sNj0ppnGGwK5A== +"@libp2p/logger@^3.0.0", "@libp2p/logger@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@libp2p/logger/-/logger-3.0.1.tgz#e89332c691a1652e1abefde7e03886ca1765b4bf" + integrity sha512-sm2ewSZ1f0xnhYDcdUWsakD/mLS5SpyZwWOhgIb02TGJqb79lXVrxYTzOnzK4mCeVmqvv2u6g/ifFZyrt4O0cg== dependencies: - "@libp2p/interface-peer-discovery" "^2.0.0" - "@libp2p/interface-peer-info" "^1.0.8" - "@libp2p/interfaces" "^3.3.1" - "@libp2p/logger" "^2.0.5" - "@libp2p/peer-id" "^2.0.1" - "@multiformats/multiaddr" "^12.0.0" + "@libp2p/interface" "^0.1.1" + "@multiformats/multiaddr" "^12.1.3" + debug "^4.3.4" + interface-datastore "^8.2.0" + multiformats "^12.0.1" + +"@libp2p/mdns@^9.0.2": + version "9.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/mdns/-/mdns-9.0.2.tgz#ed307c88edb988f67cd57678cc80bec75196a4b3" + integrity sha512-3CB5cddx+rrb5gxQlZYy6qgRes8Z4gzEUxCs4F3si3zXsf5XyqaNXsnNHWfMEqh0kFa41sgr4kUAWDYAydfa3A== + dependencies: + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + "@libp2p/peer-id" "^3.0.1" + "@multiformats/multiaddr" "^12.1.3" "@types/multicast-dns" "^7.2.1" dns-packet "^5.4.0" multicast-dns "^7.2.5" -"@libp2p/mplex@^8.0.3": - version "8.0.3" - resolved "https://registry.yarnpkg.com/@libp2p/mplex/-/mplex-8.0.3.tgz#cd191866a5bc4c2870f6b446d40f0d0396639352" - integrity sha512-qMaMHmjYxkInQKRgBx1bsJB9T4FPqbvkwU9oItARl134Xila0ZqGaiRdy7m4aBVY0jmd0Jfq0F1ysy6KUCXxFA== +"@libp2p/mplex@^9.0.2": + version "9.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/mplex/-/mplex-9.0.2.tgz#139dc566dac49bcaf7b0edd8c9cf5d9a2448fc85" + integrity sha512-2vLLlMCDP2TNRD+lJlFQUDp8Q/HzPUB22R8qaJ8jZF+aVac05VAsImsTW2oQ7Oq5zhOXWbGDZyvbk2JBmfsteQ== dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-stream-muxer" "^4.1.2" - "@libp2p/interfaces" "^3.2.0" - "@libp2p/logger" "^2.0.0" - abortable-iterator "^5.0.0" - any-signal "^4.0.1" + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + abortable-iterator "^5.0.1" benchmark "^2.1.4" it-batched-bytes "^2.0.2" - it-pushable "^3.1.0" + it-pushable "^3.2.0" it-stream-types "^2.0.1" - rate-limiter-flexible "^2.3.9" - uint8arraylist "^2.1.1" - uint8arrays "^4.0.2" + rate-limiter-flexible "^2.3.11" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" varint "^6.0.0" -"@libp2p/multistream-select@^3.1.8": - version "3.1.9" - resolved "https://registry.yarnpkg.com/@libp2p/multistream-select/-/multistream-select-3.1.9.tgz#60b12503bab879a2ebb97d69f4670a10e67c35c8" - integrity sha512-iSNqr8jXvOrkNTyA43h/ARs4wd0Rd55/D6oFRndLcV4yQSUMmfjl7dUcbC5MAw+5/sgskfDx9TMawSwNq47Qwg== +"@libp2p/multistream-select@^4.0.1": + version "4.0.1" + resolved "https://registry.yarnpkg.com/@libp2p/multistream-select/-/multistream-select-4.0.1.tgz#5563693362b36e5574e6da123012cafcad4bbfd1" + integrity sha512-0GDpEdV5cdS+3G6WfA+63E9wDIWJqHru5THU8f6+ybJ6wamXLRlUzqCm2giqQXsvMdWDCXocAgzhf5eJjIxRnQ== dependencies: - "@libp2p/interfaces" "^3.2.0" - "@libp2p/logger" "^2.0.0" - abortable-iterator "^5.0.0" + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + abortable-iterator "^5.0.1" it-first "^3.0.1" it-handshake "^4.1.3" - it-length-prefixed "^9.0.0" + it-length-prefixed "^9.0.1" it-merge "^3.0.0" - it-pipe "^3.0.0" - it-pushable "^3.1.0" + it-pipe "^3.0.1" + it-pushable "^3.2.0" it-reader "^6.0.1" it-stream-types "^2.0.1" - uint8arraylist "^2.3.1" - uint8arrays "^4.0.2" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" -"@libp2p/peer-collections@^3.0.0", "@libp2p/peer-collections@^3.0.1": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/peer-collections/-/peer-collections-3.0.1.tgz#77080198e6222fcb6d8633aa5a3feeb9afcb3196" - integrity sha512-tJvCjFSKX76VacThVnN0XC4jnUeufYD2u9TxWJllSYnmmos/Lwhl4kdtEyZkKNlJKam+cBoUmODXzasdoPZgVg== +"@libp2p/peer-collections@^4.0.2": + version "4.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/peer-collections/-/peer-collections-4.0.2.tgz#46efc5b3730493c08cc5b837a07f5a3aa3314eeb" + integrity sha512-vk3jra8S9ifRdP4M5GDndwhvVZTdhgt0KAqlU5Vw7PH2Ex8t0OvNXBRy+ZDqGeCkkK+SytYlrRrVSMW2/mR2Cw== dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/peer-id" "^2.0.0" + "@libp2p/interface" "^0.1.1" + "@libp2p/peer-id" "^3.0.1" -"@libp2p/peer-id-factory@^2.0.0", "@libp2p/peer-id-factory@^2.0.3": - version "2.0.3" - resolved "https://registry.yarnpkg.com/@libp2p/peer-id-factory/-/peer-id-factory-2.0.3.tgz#d841989494c4900e01f6e3929ef06b8cc4e56f8f" - integrity sha512-9pwVbfghiKuiC76Pue/+tI4PD7gnw1jGVcxYD+nhcRs8ABE7NLaB7nCm99cCtvmMNRnl2JqaGgZJXt8mnvAEuQ== +"@libp2p/peer-id-factory@^3.0.2": + version "3.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/peer-id-factory/-/peer-id-factory-3.0.2.tgz#6f3c374fbe0f86c753d57e262421da7ff610d950" + integrity sha512-M/3rmJeJxO1HtdYBpODisyFL4r6o5KVI13/fPyNr3V0bzVxMGvY7SqZPgyfjOx1ak5fS9NPsTR2D0i7HL0YQRA== dependencies: - "@libp2p/crypto" "^1.0.0" - "@libp2p/interface-keys" "^1.0.2" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/peer-id" "^2.0.0" - multiformats "^11.0.0" + "@libp2p/crypto" "^2.0.2" + "@libp2p/interface" "^0.1.1" + "@libp2p/peer-id" "^3.0.1" + multiformats "^12.0.1" protons-runtime "^5.0.0" - uint8arraylist "^2.0.0" - uint8arrays "^4.0.2" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" -"@libp2p/peer-id@^2.0.0", "@libp2p/peer-id@^2.0.1", "@libp2p/peer-id@^2.0.3": +"@libp2p/peer-id@^2.0.1": version "2.0.3" resolved "https://registry.yarnpkg.com/@libp2p/peer-id/-/peer-id-2.0.3.tgz#7299d74eae7b2526123d941bdb2d08462704c79a" integrity sha512-eZX+5ByUAzh8DrfjCan0spZGpvF7SxEBz4tOPoBMBCuKJJLr+8EokBO/5E3ceIw04f5+lAcD3CO3bccuKomp3Q== @@ -1800,134 +1670,112 @@ multiformats "^11.0.0" uint8arrays "^4.0.2" -"@libp2p/peer-record@^5.0.0", "@libp2p/peer-record@^5.0.3": - version "5.0.3" - resolved "https://registry.yarnpkg.com/@libp2p/peer-record/-/peer-record-5.0.3.tgz#eceb3ed6419e0cade035542540115fb5c14f647b" - integrity sha512-KnQR/NteL0xGKXd9rZo/W3ZT9kajmNy98/BOOlnMktkAL7jCfHy2z/laDU+rSttTy1TYZ15zPzXtnm3813ECmg== +"@libp2p/peer-id@^3.0.0", "@libp2p/peer-id@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@libp2p/peer-id/-/peer-id-3.0.1.tgz#4f27c04f34cc189f14c82aabc74cbd4a91f8eef2" + integrity sha512-iR4lP9nEnIl1fW7beuB55A262lW78sOdH6r/57XcyMtsE/mCZiRhUVhGfvcM4GgLWm26vyla/UV3FVr7hIpMIQ== dependencies: - "@libp2p/crypto" "^1.0.11" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interface-record" "^2.0.1" - "@libp2p/interfaces" "^3.2.0" - "@libp2p/peer-id" "^2.0.0" - "@libp2p/utils" "^3.0.0" - "@multiformats/multiaddr" "^12.0.0" - protons-runtime "^5.0.0" - uint8-varint "^1.0.2" - uint8arraylist "^2.1.0" - uint8arrays "^4.0.2" + "@libp2p/interface" "^0.1.1" + multiformats "^12.0.1" + uint8arrays "^4.0.4" -"@libp2p/peer-store@^8.2.0": - version "8.2.0" - resolved "https://registry.yarnpkg.com/@libp2p/peer-store/-/peer-store-8.2.0.tgz#b2faa4fdff91669a983e30b81128ee33195c6550" - integrity sha512-6QVT16ThxVmGHxTRmT5vKF8d2zVkG+ioxLO51Z+NrFMi/UgqTffx0qozWOcJ3CFqxPOS7MLR+wFecej2eGu2/w== +"@libp2p/peer-record@^6.0.2": + version "6.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/peer-record/-/peer-record-6.0.2.tgz#a047c9319eb9bf6586a30ecc8d55501effb38cfd" + integrity sha512-iOBTmQdryKp8GMwQ2YoHe/u1POuUPvyXq4r1wlqwVsxILgBO+lWlsHuASRhHqESH2x6wOF8mh3k+hHs3WWJcyA== dependencies: - "@libp2p/interface-libp2p" "^3.1.0" - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interface-peer-store" "^2.0.4" - "@libp2p/interfaces" "^3.2.0" - "@libp2p/logger" "^2.0.7" - "@libp2p/peer-collections" "^3.0.1" - "@libp2p/peer-id" "^2.0.0" - "@libp2p/peer-id-factory" "^2.0.0" - "@libp2p/peer-record" "^5.0.3" - "@multiformats/multiaddr" "^12.0.0" - interface-datastore "^8.0.0" + "@libp2p/crypto" "^2.0.2" + "@libp2p/interface" "^0.1.1" + "@libp2p/peer-id" "^3.0.1" + "@libp2p/utils" "^4.0.1" + "@multiformats/multiaddr" "^12.1.3" + protons-runtime "^5.0.0" + uint8-varint "^1.0.2" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" + +"@libp2p/peer-store@^9.0.2": + version "9.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/peer-store/-/peer-store-9.0.2.tgz#230b6451a4c44102f294a027f78396011e6d6144" + integrity sha512-hADoXpCWXgA2kIJXaVO+vpI8erZp0MZQWFYfk+0s96gJMgpwmJZl1tOTXWWvUXgo5M+MlAwRGoxdL1CF2/g9/A== + dependencies: + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + "@libp2p/peer-collections" "^4.0.2" + "@libp2p/peer-id" "^3.0.1" + "@libp2p/peer-id-factory" "^3.0.2" + "@libp2p/peer-record" "^6.0.2" + "@multiformats/multiaddr" "^12.1.3" + interface-datastore "^8.2.0" it-all "^3.0.2" mortice "^3.0.1" - multiformats "^11.0.0" + multiformats "^12.0.1" protons-runtime "^5.0.0" - uint8arraylist "^2.1.1" - uint8arrays "^4.0.2" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" -"@libp2p/prometheus-metrics@^1.1.4": - version "1.1.4" - resolved "https://registry.yarnpkg.com/@libp2p/prometheus-metrics/-/prometheus-metrics-1.1.4.tgz#ad490f0bfb63f2db7cadc65cf7f8a999c7396af2" - integrity sha512-PeszZJQKliGGLLjni7QP3OiOKY0qNbAIo1ySBSFjkg4HL9UYK/12kYQRR7tbsjOhnjDffNzOs4oYli9s0j9/7g== +"@libp2p/prometheus-metrics@^2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/prometheus-metrics/-/prometheus-metrics-2.0.2.tgz#b303ee58e6ff1a45c9a7d53285afc3a1f0dc0fbe" + integrity sha512-jDZxg8338KU9Ptfc26f+dblIqNDMT+Np2Rx0WgMXodbBQeIvprEgIAzX1M0RUzVoxTrPRpSAND960hHjiU8xdQ== dependencies: - "@libp2p/interface-connection" "^5.0.2" - "@libp2p/interface-metrics" "^4.0.2" - "@libp2p/logger" "^2.0.2" + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" it-foreach "^2.0.3" it-stream-types "^2.0.1" + prom-client "^14.1.0" -"@libp2p/pubsub@^7.0.1": - version "7.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/pubsub/-/pubsub-7.0.1.tgz#8b9aa8aff7485ab0e1c451f0e24a898f226bb934" - integrity sha512-CC/d1BwIT/K/lHaubwsGfo5smdWO9enwQROlSK0RdxXwPD8psf9y8YAN+cmxJa+Xls+Qhq2YU1f9bpSrjSkOtA== - dependencies: - "@libp2p/crypto" "^1.0.0" - "@libp2p/interface-connection" "^5.0.1" - "@libp2p/interface-peer-id" "^2.0.1" - "@libp2p/interface-pubsub" "^4.0.0" - "@libp2p/interface-registrar" "^2.0.11" - "@libp2p/interfaces" "^3.3.1" - "@libp2p/logger" "^2.0.7" - "@libp2p/peer-collections" "^3.0.1" - "@libp2p/peer-id" "^2.0.3" - "@libp2p/topology" "^4.0.1" +"@libp2p/pubsub@^8.0.0": + version "8.0.3" + resolved "https://registry.yarnpkg.com/@libp2p/pubsub/-/pubsub-8.0.3.tgz#93c839c89b9f432fc4c18bcb9491c822688db21c" + integrity sha512-NIVM5MjN+Kx9jNoBzNPW44mhc3eedWpNc4IT1Nz2cxurA+QgzI01mz42SiN+GqapQmiZrVrWClnb0Knc4t7TtQ== + dependencies: + "@libp2p/crypto" "^2.0.2" + "@libp2p/interface" "^0.1.1" + "@libp2p/interface-internal" "^0.1.2" + "@libp2p/logger" "^3.0.1" + "@libp2p/peer-collections" "^4.0.2" + "@libp2p/peer-id" "^3.0.1" abortable-iterator "^5.0.1" - it-length-prefixed "^9.0.0" + it-length-prefixed "^9.0.1" it-pipe "^3.0.1" - it-pushable "^3.1.3" - multiformats "^11.0.0" - p-queue "^7.2.0" - uint8arraylist "^2.0.0" - uint8arrays "^4.0.2" + it-pushable "^3.2.0" + multiformats "^12.0.1" + p-queue "^7.3.4" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" -"@libp2p/tcp@7.0.1": - version "7.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/tcp/-/tcp-7.0.1.tgz#116b311deb89e70a04ab31f70c783f2224ef3d48" - integrity sha512-But+0FiTBNjIpFeYMpq5QetSLK0MKQaRjDYsYC0AUIE61TmrWE4tpxnW57rl/hKJprVbYs/9lYxgflL9Mo33Wg== +"@libp2p/tcp@8.0.2": + version "8.0.2" + resolved "https://registry.yarnpkg.com/@libp2p/tcp/-/tcp-8.0.2.tgz#ae656d3dcd8200b4791a0de538090ae316866298" + integrity sha512-bZARZOnX6hRMZPkQ4xMCFnkgNrf24x7d1ifiorivOPPPZ2ulCb73HdnK1PgASHF4T2kJIidtihJD2zIiPOK6vA== dependencies: - "@libp2p/interface-connection" "^5.0.0" - "@libp2p/interface-metrics" "^4.0.0" - "@libp2p/interface-transport" "^4.0.0" - "@libp2p/interfaces" "^3.2.0" - "@libp2p/logger" "^2.0.0" - "@libp2p/utils" "^3.0.2" - "@multiformats/mafmt" "^12.0.0" - "@multiformats/multiaddr" "^12.0.0" + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + "@libp2p/utils" "^4.0.1" + "@multiformats/mafmt" "^12.1.2" + "@multiformats/multiaddr" "^12.1.3" + "@types/sinon" "^10.0.15" stream-to-it "^0.2.2" -"@libp2p/topology@^4.0.0", "@libp2p/topology@^4.0.1": +"@libp2p/utils@^4.0.1": version "4.0.1" - resolved "https://registry.yarnpkg.com/@libp2p/topology/-/topology-4.0.1.tgz#8efab229ed32d30cfa6c4a371e8022011c0ff6f9" - integrity sha512-wcToZU3o55nTPuN+yEpAublGzomGfxEAu8snaGeZS0f6ObzaQXqPgZvD5qpiQ8yOOVjR+IiNEjZJiuqNShHnaA== - dependencies: - "@libp2p/interface-peer-id" "^2.0.0" - "@libp2p/interface-registrar" "^2.0.3" - "@libp2p/logger" "^2.0.1" - it-all "^2.0.0" - -"@libp2p/tracked-map@^3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@libp2p/tracked-map/-/tracked-map-3.0.0.tgz#135e80c4359efc9ed49b2c97c7622b14d58705da" - integrity sha512-IQjluWWbcKzNxZI3A+MgTu+5sITVX8YDOqQYE84toV3SNl6y7FrFEKQz1WlCjOHjvK1GNEB6NgirA6HKcaT23A== - dependencies: - "@libp2p/interface-metrics" "^4.0.0" - -"@libp2p/utils@^3.0.0", "@libp2p/utils@^3.0.10", "@libp2p/utils@^3.0.2": - version "3.0.11" - resolved "https://registry.yarnpkg.com/@libp2p/utils/-/utils-3.0.11.tgz#d1611c3d7836eb32e5fc8bcc19c620e77471f44f" - integrity sha512-d8ZQnu2o78TG7Oy4G6qFy5v/kNBtfgQjy1RpiQAEAB6AOSi1Oq8nLebrgCqSHfrtOIcj6a+G6ImYBaRE4b03CA== + resolved "https://registry.yarnpkg.com/@libp2p/utils/-/utils-4.0.1.tgz#0c31544542b74edee0f2fb51a04c322dff4a6ba6" + integrity sha512-Jo6K+st+F2n/IaJ5PQwDE4GHZW0DWdWhC9YdSuK0M/ZrOBqjLaUfayAoXu3ygqY4lqTLmRkm7mlCza6IWMWZAA== dependencies: "@achingbrain/ip-address" "^8.1.0" - "@libp2p/interface-connection" "^5.0.1" - "@libp2p/interface-peer-store" "^2.0.0" - "@libp2p/interfaces" "^3.2.0" - "@libp2p/logger" "^2.0.0" - "@multiformats/multiaddr" "^12.0.0" - abortable-iterator "^5.0.0" + "@libp2p/interface" "^0.1.1" + "@libp2p/logger" "^3.0.1" + "@multiformats/multiaddr" "^12.1.3" is-loopback-addr "^2.0.1" it-stream-types "^2.0.1" private-ip "^3.0.0" - uint8arraylist "^2.3.2" + uint8arraylist "^2.4.3" -"@multiformats/mafmt@^12.0.0": - version "12.1.0" - resolved "https://registry.yarnpkg.com/@multiformats/mafmt/-/mafmt-12.1.0.tgz#9984f1e5314631a0472ccb91ea1ce12ea1f5059b" - integrity sha512-P3+cKi0EqqYGoF8IMK7dd8PFlanbvzzhem+tkcjrjGAPV5sVam2VfFAFNyzLTOP8dS/5Rf5pQ6LC0k6cO8WF5w== +"@multiformats/mafmt@^12.1.2": + version "12.1.6" + resolved "https://registry.yarnpkg.com/@multiformats/mafmt/-/mafmt-12.1.6.tgz#e7c1831c1e94c94932621826049afc89f3ad43b7" + integrity sha512-tlJRfL21X+AKn9b5i5VnaTD6bNttpSpcqwKVmDmSHLwxoz97fAHaepqFOk/l1fIu94nImIXneNbhsJx/RQNIww== dependencies: "@multiformats/multiaddr" "^12.0.0" @@ -2009,6 +1857,11 @@ resolved "https://registry.yarnpkg.com/@napi-rs/snappy-win32-x64-msvc/-/snappy-win32-x64-msvc-7.2.2.tgz#4f598d3a5d50904d9f72433819f68b21eaec4f7d" integrity sha512-a43cyx1nK0daw6BZxVcvDEXxKMFLSBSDTAhsFD0VqSKcC7MGUBMaqyoWUcMiI7LBSz4bxUmxDWKfCYzpEmeb3w== +"@noble/ciphers@^0.1.4": + version "0.1.4" + resolved "https://registry.yarnpkg.com/@noble/ciphers/-/ciphers-0.1.4.tgz#96327dca147829ed9eee0d96cfdf7c57915765f0" + integrity sha512-d3ZR8vGSpy3v/nllS+bD/OMN5UZqusWiQqkyj7AwzTnhXFH72pF5oB4Ach6DQ50g5kXxC28LdaYBEpsyv9KOUQ== + "@noble/curves@1.0.0", "@noble/curves@~1.0.0": version "1.0.0" resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.0.0.tgz#e40be8c7daf088aaf291887cbc73f43464a92932" @@ -2016,6 +1869,13 @@ dependencies: "@noble/hashes" "1.3.0" +"@noble/curves@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.1.0.tgz#f13fc667c89184bc04cccb9b11e8e7bae27d8c3d" + integrity sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA== + dependencies: + "@noble/hashes" "1.3.1" + "@noble/ed25519@^1.6.0": version "1.6.0" resolved "https://registry.yarnpkg.com/@noble/ed25519/-/ed25519-1.6.0.tgz#b55f7c9e532b478bf1d7c4f609e1f3a37850b583" @@ -2036,6 +1896,11 @@ resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.0.tgz#085fd70f6d7d9d109671090ccae1d3bec62554a1" integrity sha512-ilHEACi9DwqJB0pw7kv+Apvh50jiiSyR/cQ3y4W7lOR5mhvn/50FLUfsnfJz0BDZtl/RR16kXvptiv6q1msYZg== +"@noble/hashes@1.3.1", "@noble/hashes@^1.3.1": + version "1.3.1" + resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.1.tgz#8831ef002114670c603c458ab8b11328406953a9" + integrity sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA== + "@noble/hashes@^1.0.0", "@noble/hashes@~1.0.0": version "1.0.0" resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.0.0.tgz" @@ -2839,90 +2704,6 @@ resolved "https://registry.npmjs.org/@sinonjs/text-encoding/-/text-encoding-0.7.1.tgz" integrity sha512-+iTbntw2IZPb/anVDbypzfQa+ay64MW0Zo8aJ8gZPWMMK6/OubMVb6lUPMagqjOPnmtauXnFCACVl3O7ogjeqQ== -"@stablelib/aead@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/aead/-/aead-1.0.1.tgz" - integrity sha512-q39ik6sxGHewqtO0nP4BuSe3db5G1fEJE8ukvngS2gLkBXyy6E7pLubhbYgnkDFv6V8cWaxcE4Xn0t6LWcJkyg== - -"@stablelib/binary@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/binary/-/binary-1.0.1.tgz" - integrity sha512-ClJWvmL6UBM/wjkvv/7m5VP3GMr9t0osr4yVgLZsLCOz4hGN9gIAFEqnJ0TsSMAN+n840nf2cHZnA5/KFqHC7Q== - dependencies: - "@stablelib/int" "^1.0.1" - -"@stablelib/bytes@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/bytes/-/bytes-1.0.1.tgz" - integrity sha512-Kre4Y4kdwuqL8BR2E9hV/R5sOrUj6NanZaZis0V6lX5yzqC3hBuVSDXUIBqQv/sCpmuWRiHLwqiT1pqqjuBXoQ== - -"@stablelib/chacha20poly1305@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/chacha20poly1305/-/chacha20poly1305-1.0.1.tgz" - integrity sha512-MmViqnqHd1ymwjOQfghRKw2R/jMIGT3wySN7cthjXCBdO+qErNPUBnRzqNpnvIwg7JBCg3LdeCZZO4de/yEhVA== - dependencies: - "@stablelib/aead" "^1.0.1" - "@stablelib/binary" "^1.0.1" - "@stablelib/chacha" "^1.0.1" - "@stablelib/constant-time" "^1.0.1" - "@stablelib/poly1305" "^1.0.1" - "@stablelib/wipe" "^1.0.1" - -"@stablelib/chacha@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/chacha/-/chacha-1.0.1.tgz" - integrity sha512-Pmlrswzr0pBzDofdFuVe1q7KdsHKhhU24e8gkEwnTGOmlC7PADzLVxGdn2PoNVBBabdg0l/IfLKg6sHAbTQugg== - dependencies: - "@stablelib/binary" "^1.0.1" - "@stablelib/wipe" "^1.0.1" - -"@stablelib/constant-time@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/constant-time/-/constant-time-1.0.1.tgz" - integrity sha512-tNOs3uD0vSJcK6z1fvef4Y+buN7DXhzHDPqRLSXUel1UfqMB1PWNsnnAezrKfEwTLpN0cGH2p9NNjs6IqeD0eg== - -"@stablelib/int@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/int/-/int-1.0.1.tgz" - integrity sha512-byr69X/sDtDiIjIV6m4roLVWnNNlRGzsvxw+agj8CIEazqWGOQp2dTYgQhtyVXV9wpO6WyXRQUzLV/JRNumT2w== - -"@stablelib/keyagreement@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/keyagreement/-/keyagreement-1.0.1.tgz" - integrity sha512-VKL6xBwgJnI6l1jKrBAfn265cspaWBPAPEc62VBQrWHLqVgNRE09gQ/AnOEyKUWrrqfD+xSQ3u42gJjLDdMDQg== - dependencies: - "@stablelib/bytes" "^1.0.1" - -"@stablelib/poly1305@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/poly1305/-/poly1305-1.0.1.tgz" - integrity sha512-1HlG3oTSuQDOhSnLwJRKeTRSAdFNVB/1djy2ZbS35rBSJ/PFqx9cf9qatinWghC2UbfOYD8AcrtbUQl8WoxabA== - dependencies: - "@stablelib/constant-time" "^1.0.1" - "@stablelib/wipe" "^1.0.1" - -"@stablelib/random@^1.0.2": - version "1.0.2" - resolved "https://registry.yarnpkg.com/@stablelib/random/-/random-1.0.2.tgz#2dece393636489bf7e19c51229dd7900eddf742c" - integrity sha512-rIsE83Xpb7clHPVRlBj8qNe5L8ISQOzjghYQm/dZ7VaM2KHYwMW5adjQjrzTZCchFnNCNhkwtnOBa9HTMJCI8w== - dependencies: - "@stablelib/binary" "^1.0.1" - "@stablelib/wipe" "^1.0.1" - -"@stablelib/wipe@^1.0.1": - version "1.0.1" - resolved "https://registry.npmjs.org/@stablelib/wipe/-/wipe-1.0.1.tgz" - integrity sha512-WfqfX/eXGiAd3RJe4VU2snh/ZPwtSjLG4ynQ/vYzvghTh7dHFcI1wl+nrkWG6lGhukOxOsUHfv8dUXr58D0ayg== - -"@stablelib/x25519@^1.0.3": - version "1.0.3" - resolved "https://registry.yarnpkg.com/@stablelib/x25519/-/x25519-1.0.3.tgz#13c8174f774ea9f3e5e42213cbf9fc68a3c7b7fd" - integrity sha512-KnTbKmUhPhHavzobclVJQG5kuivH+qDLpe84iRqX3CLrKp881cF160JvXJ+hjn1aMyCwYOKeIZefIH/P5cJoRw== - dependencies: - "@stablelib/keyagreement" "^1.0.1" - "@stablelib/random" "^1.0.2" - "@stablelib/wipe" "^1.0.1" - "@szmarczak/http-timer@^1.1.2": version "1.1.2" resolved "https://registry.yarnpkg.com/@szmarczak/http-timer/-/http-timer-1.1.2.tgz#b1665e2c461a2cd92f4c1bbf50d5454de0d4b421" @@ -3376,6 +3157,13 @@ dependencies: "@types/sinonjs__fake-timers" "*" +"@types/sinon@^10.0.15": + version "10.0.16" + resolved "https://registry.yarnpkg.com/@types/sinon/-/sinon-10.0.16.tgz#4bf10313bd9aa8eef1e50ec9f4decd3dd455b4d3" + integrity sha512-j2Du5SYpXZjJVJtXBokASpPRj+e2z+VUhCPHmM6WMfe3dpHu6iVKJMU6AiBcMp/XTAYnEj6Wc1trJUWwZ0QaAQ== + dependencies: + "@types/sinonjs__fake-timers" "*" + "@types/sinonjs__fake-timers@*": version "6.0.2" resolved "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-6.0.2.tgz" @@ -3767,7 +3555,7 @@ abort-controller@^3.0.0: dependencies: event-target-shim "^5.0.0" -abortable-iterator@^5.0.0, abortable-iterator@^5.0.1: +abortable-iterator@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/abortable-iterator/-/abortable-iterator-5.0.1.tgz#5d93eba6fa8287a973a9ea090c64ca08b3777780" integrity sha512-hlZ5Z8UwqrKsJcelVPEqDduZowJPBQJ9ZhBC2FXpja3lXy8X6MoI5uMzIgmrA8+3jcVnp8TF/tx+IBBqYJNUrg== @@ -4007,7 +3795,7 @@ any-signal@3.0.1: resolved "https://registry.yarnpkg.com/any-signal/-/any-signal-3.0.1.tgz#49cae34368187a3472e31de28fb5cb1430caa9a6" integrity sha512-xgZgJtKEa9YmDqXodIgl7Fl1C8yNXr8w6gXjqK3LW4GcEiYT+6AQfJSE/8SPsEpLLmcvbv8YU+qet94UewHxqg== -any-signal@^4.0.1, any-signal@^4.1.1: +any-signal@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/any-signal/-/any-signal-4.1.1.tgz#928416c355c66899e6b2a91cad4488f0324bae03" integrity sha512-iADenERppdC+A2YKbOXXB2WUeABLaM6qnpZ70kZbPZ1cZMMJ7eF+3CaYm+/PhBizgkzlvssC7QuHS30oOiQYWA== @@ -5686,6 +5474,25 @@ datastore-core@^9.0.0, datastore-core@^9.1.1: it-take "^3.0.1" uint8arrays "^4.0.2" +datastore-core@^9.0.1: + version "9.2.2" + resolved "https://registry.yarnpkg.com/datastore-core/-/datastore-core-9.2.2.tgz#92b0efbc5a0b6362ecce3506ccc285b0691a834b" + integrity sha512-WFB1wVlD3Tr2yBZpJutPedBc18A4t0HvLOSksokYr/2nHBapplgnwkg2esI6xxctma+76FghhXx7G26khx2Uxg== + dependencies: + "@libp2p/logger" "^3.0.0" + err-code "^3.0.1" + interface-store "^5.0.0" + it-all "^3.0.1" + it-drain "^3.0.1" + it-filter "^3.0.0" + it-map "^3.0.1" + it-merge "^3.0.0" + it-pipe "^3.0.0" + it-pushable "^3.0.0" + it-sort "^3.0.1" + it-take "^3.0.1" + uint8arrays "^4.0.2" + datastore-level@*, datastore-level@^10.1.1: version "10.1.1" resolved "https://registry.yarnpkg.com/datastore-level/-/datastore-level-10.1.1.tgz#390dc6ca17dc691947a3e81c984b4b6064812e81" @@ -5882,10 +5689,10 @@ delegates@^1.0.0: resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" integrity sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ== -denque@^1.5.0: - version "1.5.1" - resolved "https://registry.npmjs.org/denque/-/denque-1.5.1.tgz" - integrity sha512-XwE+iZ4D6ZUB7mfYRMb5wByE8L74HCn30FBN7sWnXksWc1LO1bPDl67pBR9o/kC4z/xSNAwkMYcGgqDV3BE3Hw== +denque@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/denque/-/denque-2.1.0.tgz#e93e1a6569fb5e66f16a3c2a2964617d349d6ab1" + integrity sha512-HVQE3AAb/pxF8fQAoiqpvg9i3evqug3hoiwakOyZAwJm+6vZehbkYXZ0l4JxS+I3QxM97v5aaRNhj8v5oBhekw== depd@2.0.0: version "2.0.0" @@ -8712,11 +8519,6 @@ istanbul-reports@^3.1.4: html-escaper "^2.0.0" istanbul-lib-report "^3.0.0" -it-all@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/it-all/-/it-all-2.0.0.tgz#6f4e5cdb71af02793072822a90bc44de901a92c3" - integrity sha512-I/yi9ogTY59lFxtfsDSlI9w9QZtC/5KJt6g7CPPBJJh2xql2ZS7Ghcp9hoqDDbc4QfwQvtx8Loy0zlKQ8H5gFg== - it-all@^3.0.0, it-all@^3.0.1, it-all@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/it-all/-/it-all-3.0.2.tgz#620b82c702c9c6d1c4caddb6407dba4a4baa970b" @@ -8730,7 +8532,16 @@ it-batched-bytes@^2.0.2: p-defer "^4.0.0" uint8arraylist "^2.4.1" -it-drain@^3.0.1: +it-byte-stream@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/it-byte-stream/-/it-byte-stream-1.0.0.tgz#07645e1c94444760bc7abecebf187b83777b0351" + integrity sha512-zQjgsP5kWTnMrchFOMAiiA9FcO9xSdkTdpBvdsvuqwwSNCZ8eVeyHGlc9lE3gUUSeZzzwk5OSd/18y2A4GaREg== + dependencies: + it-pushable "^3.2.0" + it-stream-types "^2.0.1" + uint8arraylist "^2.4.1" + +it-drain@^3.0.1, it-drain@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/it-drain/-/it-drain-3.0.2.tgz#4fb2ab30119072268c68a895fa5b9f2037942c44" integrity sha512-0hJvS/4Ktt9wT/bktmovjjMAY8r6FCsXqpL3zjqBBNwoL21VgQfguEnwbLSGuCip9Zq1vfU43cbHkmaRZdBfOg== @@ -8765,7 +8576,18 @@ it-handshake@^4.1.3: p-defer "^4.0.0" uint8arraylist "^2.0.0" -it-length-prefixed@^9.0.0, it-length-prefixed@^9.0.1: +it-length-prefixed-stream@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/it-length-prefixed-stream/-/it-length-prefixed-stream-1.0.0.tgz#78b0f398f93a6c52e797e03e982d2ef0bd393ed9" + integrity sha512-d+WJC2AkQRENrWr0XoZ0Tm+NBFpMiC/hQ1ZhhBhpq/L8/zFh4XNBv/28ticXVdgA2u33N69k43zJ+ZbAophNyg== + dependencies: + it-byte-stream "^1.0.0" + it-length-prefixed "^9.0.1" + it-stream-types "^2.0.1" + uint8-varint "^1.0.6" + uint8arraylist "^2.4.1" + +it-length-prefixed@^9.0.1: version "9.0.1" resolved "https://registry.yarnpkg.com/it-length-prefixed/-/it-length-prefixed-9.0.1.tgz#12b7f8a283251bf74102c1c92d61b33985089e7c" integrity sha512-ZBD8ZFLERj8d1q9CeBtk0eJ4EpeI3qwnkmWtemBSm3ZI2dM8PUweNVk5haZ2vw3EIq2uYQiabV9YwNm6EASM4A== @@ -8776,7 +8598,7 @@ it-length-prefixed@^9.0.0, it-length-prefixed@^9.0.1: uint8arraylist "^2.0.0" uint8arrays "^4.0.2" -it-map@^3.0.1, it-map@^3.0.2: +it-map@^3.0.1, it-map@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/it-map/-/it-map-3.0.3.tgz#42be39fc68dc9b0d70cfd8ac4b8311d4b5cd7f22" integrity sha512-Yf89GJYeYUZb2NZzWkvFHm3IBXlxro74i2vGRmpf8BYau3BhlaS37ieDenJEdYzkTGJhL/EbM1jPPw/KGVVVIw== @@ -8790,7 +8612,7 @@ it-merge@^3.0.0: dependencies: it-pushable "^3.1.0" -it-pair@^2.0.2: +it-pair@^2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/it-pair/-/it-pair-2.0.6.tgz#072defa6b96f611af34e0b0c84573107ddb9f28f" integrity sha512-5M0t5RAcYEQYNG5BV7d7cqbdwbCAp5yLdzvkxsZmkuZsLbTdZzah6MQySYfaAQjNDCq6PUnDt0hqBZ4NwMfW6g== @@ -8805,19 +8627,6 @@ it-parallel@^3.0.0: dependencies: p-defer "^4.0.0" -it-pb-stream@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/it-pb-stream/-/it-pb-stream-4.0.1.tgz#28825106d0dcb99576d8c78d21236053b9e0f7e7" - integrity sha512-xFYnnChsx4imzxI5eBP31bJ+2+vFYS9akHQNMM8suFd+DKWOqMlxiJvcqZEkciBXCB3Wj8HF8Wyx5baSxn31gg== - dependencies: - err-code "^3.0.1" - it-length-prefixed "^9.0.0" - it-pushable "^3.1.2" - it-stream-types "^2.0.1" - protons-runtime "^5.0.0" - uint8-varint "^1.0.6" - uint8arraylist "^2.0.0" - it-peekable@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/it-peekable/-/it-peekable-3.0.1.tgz#530953f735359c10503e961c059602f8a366a1a5" @@ -8832,11 +8641,29 @@ it-pipe@^3.0.0, it-pipe@^3.0.1: it-pushable "^3.1.2" it-stream-types "^2.0.1" -it-pushable@^3.0.0, it-pushable@^3.1.0, it-pushable@^3.1.2, it-pushable@^3.1.3: +it-protobuf-stream@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/it-protobuf-stream/-/it-protobuf-stream-1.0.0.tgz#229bc90881779bb8701ffa56fe6a53438e376103" + integrity sha512-y3FfOQ+u2xY3DLs5FH8xXz1YH/50WJx40a9zWEk73DhNSpaLaLHjZqEiTyHa5mKjP0NaYgum+Ne6wo8yFPeoNw== + dependencies: + it-length-prefixed-stream "^1.0.0" + it-stream-types "^2.0.1" + protons-runtime "^5.0.0" + uint8-varint "^1.0.6" + uint8arraylist "^2.4.1" + +it-pushable@^3.0.0, it-pushable@^3.1.0, it-pushable@^3.1.2: version "3.1.3" resolved "https://registry.yarnpkg.com/it-pushable/-/it-pushable-3.1.3.tgz#b6f4a1e0236502f12b5661b40468b629799baf0e" integrity sha512-f50iQ85HISS6DaWCyrqf9QJ6G/kQtKIMf9xZkgZgyOvxEQDfn8OfYcLXXquCqgoLboxQtAW1ZFZyFIAsLHDtJw== +it-pushable@^3.2.0: + version "3.2.1" + resolved "https://registry.yarnpkg.com/it-pushable/-/it-pushable-3.2.1.tgz#72d7ccf7e7c0ccecf8cbaf74064f7be56e775c59" + integrity sha512-sLFz2Q0oyDCJpTciZog7ipP4vSftfPy3e6JnH6YyztRa1XqkpGQaafK3Jw/JlfEBtCXfnX9uVfcpu3xpSAqCVQ== + dependencies: + p-defer "^4.0.0" + it-reader@^6.0.1: version "6.0.4" resolved "https://registry.yarnpkg.com/it-reader/-/it-reader-6.0.4.tgz#439cb88225dcd15116be0ffde9e846a928c3871a" @@ -9341,74 +9168,54 @@ libnpmpublish@6.0.4: semver "^7.3.7" ssri "^9.0.0" -libp2p@0.45.9: - version "0.45.9" - resolved "https://registry.yarnpkg.com/libp2p/-/libp2p-0.45.9.tgz#cabc2ec8c90ff7fbf07fc0bef2380ff72a2a65c3" - integrity sha512-cf2dCf8naZqQoDw3xxSEZ6rKgQ8BBne5iWgtIKHAYrCvL+ulshz72jNgeAG0FQ/jjRD3yzmUuwoMaLHj6gf7Bw== +libp2p@0.46.3: + version "0.46.3" + resolved "https://registry.yarnpkg.com/libp2p/-/libp2p-0.46.3.tgz#32de7b8106795ded5c1deaf11ca1dca774166f57" + integrity sha512-fnw2ub5HSSACa0Op/8XtCiLothB8NecYfq8vEnL+eZiLkdDmg4abUBps3cINxSw4YD7H7ljA8rofPKUo/EKYQA== dependencies: "@achingbrain/nat-port-mapper" "^1.0.9" - "@libp2p/crypto" "^1.0.17" - "@libp2p/interface-address-manager" "^3.0.0" - "@libp2p/interface-connection" "^5.1.1" - "@libp2p/interface-connection-encrypter" "^4.0.0" - "@libp2p/interface-connection-gater" "^3.0.0" - "@libp2p/interface-connection-manager" "^3.0.0" - "@libp2p/interface-content-routing" "^2.1.0" - "@libp2p/interface-keychain" "^2.0.4" - "@libp2p/interface-libp2p" "^3.2.0" - "@libp2p/interface-metrics" "^4.0.0" - "@libp2p/interface-peer-discovery" "^2.0.0" - "@libp2p/interface-peer-id" "^2.0.1" - "@libp2p/interface-peer-info" "^1.0.3" - "@libp2p/interface-peer-routing" "^1.1.0" - "@libp2p/interface-peer-store" "^2.0.4" - "@libp2p/interface-pubsub" "^4.0.0" - "@libp2p/interface-record" "^2.0.6" - "@libp2p/interface-registrar" "^2.0.3" - "@libp2p/interface-stream-muxer" "^4.0.0" - "@libp2p/interface-transport" "^4.0.0" - "@libp2p/interfaces" "^3.2.0" - "@libp2p/keychain" "^2.0.0" - "@libp2p/logger" "^2.1.1" - "@libp2p/multistream-select" "^3.1.8" - "@libp2p/peer-collections" "^3.0.0" - "@libp2p/peer-id" "^2.0.0" - "@libp2p/peer-id-factory" "^2.0.0" - "@libp2p/peer-record" "^5.0.0" - "@libp2p/peer-store" "^8.2.0" - "@libp2p/topology" "^4.0.1" - "@libp2p/tracked-map" "^3.0.0" - "@libp2p/utils" "^3.0.10" - "@multiformats/mafmt" "^12.0.0" - "@multiformats/multiaddr" "^12.0.0" + "@libp2p/crypto" "^2.0.2" + "@libp2p/interface" "^0.1.1" + "@libp2p/interface-internal" "^0.1.2" + "@libp2p/keychain" "^3.0.2" + "@libp2p/logger" "^3.0.1" + "@libp2p/multistream-select" "^4.0.1" + "@libp2p/peer-collections" "^4.0.2" + "@libp2p/peer-id" "^3.0.1" + "@libp2p/peer-id-factory" "^3.0.2" + "@libp2p/peer-record" "^6.0.2" + "@libp2p/peer-store" "^9.0.2" + "@libp2p/utils" "^4.0.1" + "@multiformats/mafmt" "^12.1.2" + "@multiformats/multiaddr" "^12.1.3" abortable-iterator "^5.0.1" any-signal "^4.1.1" - datastore-core "^9.0.0" - interface-datastore "^8.0.0" - it-all "^3.0.1" - it-drain "^3.0.1" + datastore-core "^9.0.1" + interface-datastore "^8.2.0" + it-all "^3.0.2" + it-drain "^3.0.2" it-filter "^3.0.1" it-first "^3.0.1" it-handshake "^4.1.3" it-length-prefixed "^9.0.1" - it-map "^3.0.2" + it-map "^3.0.3" it-merge "^3.0.0" - it-pair "^2.0.2" + it-pair "^2.0.6" it-parallel "^3.0.0" - it-pb-stream "^4.0.1" it-pipe "^3.0.1" + it-protobuf-stream "^1.0.0" it-stream-types "^2.0.1" merge-options "^3.0.4" - multiformats "^11.0.0" + multiformats "^12.0.1" p-defer "^4.0.0" p-queue "^7.3.4" p-retry "^5.0.0" private-ip "^3.0.0" protons-runtime "^5.0.0" rate-limiter-flexible "^2.3.11" - uint8arraylist "^2.3.2" - uint8arrays "^4.0.2" - wherearewe "^2.0.0" + uint8arraylist "^2.4.3" + uint8arrays "^4.0.4" + wherearewe "^2.0.1" xsalsa20 "^1.1.0" light-my-request@^5.9.1: @@ -9615,11 +9422,6 @@ logform@^2.3.2, logform@^2.4.0: safe-stable-stringify "^2.3.1" triple-beam "^1.3.0" -long@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/long/-/long-4.0.0.tgz#9a7b71cfb7d361a194ea555241c92f7468d5bf28" - integrity sha512-XsP+KhQif4bjX1kbuSiySJFNAehNxgLb6hPRGJ9QsUr8ajHkuXGdrHmFUTUUXhDwVX2R5bY4JNZEwbUiMhV+MA== - long@^5.0.0: version "5.2.0" resolved "https://registry.yarnpkg.com/long/-/long-5.2.0.tgz#2696dadf4b4da2ce3f6f6b89186085d94d52fd61" @@ -11648,7 +11450,7 @@ progress@^2.0.3: resolved "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz" integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== -prom-client@^14.2.0: +prom-client@^14.1.0, prom-client@^14.2.0: version "14.2.0" resolved "https://registry.yarnpkg.com/prom-client/-/prom-client-14.2.0.tgz#ca94504e64156f6506574c25fb1c34df7812cf11" integrity sha512-sF308EhTenb/pDRPakm+WgiN+VdM/T1RaHj1x+MvAuT8UiQP8JmOEbxVqtkbfR4LrvOg5n7ic01kRBDGXjYikA== @@ -11697,10 +11499,10 @@ proto-list@~1.2.1: resolved "https://registry.yarnpkg.com/proto-list/-/proto-list-1.2.4.tgz#212d5bfe1318306a420f6402b8e26ff39647a849" integrity sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA== -protobufjs@^6.11.2: - version "6.11.3" - resolved "https://registry.yarnpkg.com/protobufjs/-/protobufjs-6.11.3.tgz#637a527205a35caa4f3e2a9a4a13ddffe0e7af74" - integrity sha512-xL96WDdCZYdU7Slin569tFX712BxsxslWwAfAhCYjQKGTq7dAU91Lomy6nLLhh/dyGhk/YH4TwTSRxTzhuHyZg== +protobufjs@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/protobufjs/-/protobufjs-7.0.0.tgz#8c678e1351fd926178fce5a4213913e8d990974f" + integrity sha512-ffNIEm+quOcYtQvHdW406v1NQmZSuqVklxsXk076BtuFnlYZfigLU+JOMrTD8TUOyqHYbRI/fSVNvgd25YeN3w== dependencies: "@protobufjs/aspromise" "^1.1.2" "@protobufjs/base64" "^1.1.2" @@ -11714,12 +11516,12 @@ protobufjs@^6.11.2: "@protobufjs/utf8" "^1.1.0" "@types/long" "^4.0.1" "@types/node" ">=13.7.0" - long "^4.0.0" + long "^5.0.0" -protobufjs@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/protobufjs/-/protobufjs-7.0.0.tgz#8c678e1351fd926178fce5a4213913e8d990974f" - integrity sha512-ffNIEm+quOcYtQvHdW406v1NQmZSuqVklxsXk076BtuFnlYZfigLU+JOMrTD8TUOyqHYbRI/fSVNvgd25YeN3w== +protobufjs@^7.2.4: + version "7.2.4" + resolved "https://registry.yarnpkg.com/protobufjs/-/protobufjs-7.2.4.tgz#3fc1ec0cdc89dd91aef9ba6037ba07408485c3ae" + integrity sha512-AT+RJgD2sH8phPmCf7OUZR8xGdcJRga4+1cOaXJ64hvcSkVhNcRHOwIxUatPH15+nj59WAGTDv3LSGZPEQbJaQ== dependencies: "@protobufjs/aspromise" "^1.1.2" "@protobufjs/base64" "^1.1.2" @@ -11731,7 +11533,6 @@ protobufjs@^7.0.0: "@protobufjs/path" "^1.1.2" "@protobufjs/pool" "^1.1.0" "@protobufjs/utf8" "^1.1.0" - "@types/long" "^4.0.1" "@types/node" ">=13.7.0" long "^5.0.0" @@ -11890,11 +11691,6 @@ rate-limiter-flexible@^2.3.11: resolved "https://registry.yarnpkg.com/rate-limiter-flexible/-/rate-limiter-flexible-2.4.1.tgz#c74cfe36ac2cbfe56f68ded9a3b4b2fde1963c41" integrity sha512-dgH4T44TzKVO9CLArNto62hJOwlWJMLUjVVr/ii0uUzZXEXthDNr7/yefW5z/1vvHAfycc1tnuiYyNJ8CTRB3g== -rate-limiter-flexible@^2.3.9: - version "2.3.11" - resolved "https://registry.yarnpkg.com/rate-limiter-flexible/-/rate-limiter-flexible-2.3.11.tgz#558cf388a3785f286ae7e1c345d719c04c43b8ca" - integrity sha512-MFLtfs1llUNBkJxeTkSZD7oAxVg1nZ79bevE2TmqQMbmKGoi8DBua3VAZFz5bsjEr0A6Mbr9AJuf5lvYSCok2Q== - raw-body@2.5.1: version "2.5.1" resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.1.tgz#fe1b1628b181b700215e5fd42389f98b71392857" @@ -13712,7 +13508,7 @@ uint8-varint@^1.0.6: uint8arraylist "^2.0.0" uint8arrays "^4.0.2" -uint8arraylist@^2.0.0, uint8arraylist@^2.1.0, uint8arraylist@^2.1.1, uint8arraylist@^2.3.1, uint8arraylist@^2.3.2, uint8arraylist@^2.4.1, uint8arraylist@^2.4.3: +uint8arraylist@^2.0.0, uint8arraylist@^2.4.1, uint8arraylist@^2.4.3: version "2.4.3" resolved "https://registry.yarnpkg.com/uint8arraylist/-/uint8arraylist-2.4.3.tgz#1148aa979b407d382e4eb8d9c8f2b4bf3f5910d5" integrity sha512-oEVZr4/GrH87K0kjNce6z8pSCzLEPqHNLNR5sj8cJOySrTP8Vb/pMIbZKLJGhQKxm1TiZ31atNrpn820Pyqpow== @@ -13733,6 +13529,13 @@ uint8arrays@^4.0.3: dependencies: multiformats "^11.0.0" +uint8arrays@^4.0.4: + version "4.0.6" + resolved "https://registry.yarnpkg.com/uint8arrays/-/uint8arrays-4.0.6.tgz#bae68b536c2e87147045b95d73d29e503e45ecab" + integrity sha512-4ZesjQhqOU2Ip6GPReIwN60wRxIupavL8T0Iy36BBHr2qyMrNxsPJvr7vpS4eFt8F8kSguWUPad6ZM9izs/vyw== + dependencies: + multiformats "^12.0.1" + unbox-primitive@^1.0.0, unbox-primitive@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/unbox-primitive/-/unbox-primitive-1.0.2.tgz#29032021057d5e6cdbd08c5129c226dff8ed6f9e" @@ -14303,7 +14106,7 @@ whatwg-url@^5.0.0: tr46 "~0.0.3" webidl-conversions "^3.0.0" -wherearewe@^2.0.0: +wherearewe@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/wherearewe/-/wherearewe-2.0.1.tgz#37c97a7bf112dca8db34bfefb2f6c997af312bb8" integrity sha512-XUguZbDxCA2wBn2LoFtcEhXL6AXo+hVjGonwhSTTTU9SzbWG8Xu3onNIpzf9j/mYUcJQ0f+m37SzG77G851uFw==