diff --git a/doc/CONFIGURATION.md b/doc/CONFIGURATION.md index 1a39381a..7af18d8b 100644 --- a/doc/CONFIGURATION.md +++ b/doc/CONFIGURATION.md @@ -322,6 +322,8 @@ const MPLEX = require('libp2p-mplex') const { NOISE } = require('libp2p-noise') const GossipSub = require('libp2p-gossipsub') +const { SignaturePolicy } = require('libp2p-interfaces/src/pubsub/signature-policy') + const node = await Libp2p.create({ modules: { transport: [TCP], @@ -332,9 +334,8 @@ const node = await Libp2p.create({ config: { pubsub: { // The pubsub options (and defaults) can be found in the pubsub router documentation enabled: true, - emitSelf: true, // whether the node should emit to self on publish - signMessages: true, // if messages should be signed - strictSigning: true // if message signing should be required + emitSelf: false, // whether the node should emit to self on publish + globalSignaturePolicy: SignaturePolicy.StrictSign // message signing policy } } }) diff --git a/package.json b/package.json index 2c9b6a27..0c3e7c73 100644 --- a/package.json +++ b/package.json @@ -60,7 +60,7 @@ "it-pipe": "^1.1.0", "it-protocol-buffers": "^0.2.0", "libp2p-crypto": "^0.18.0", - "libp2p-interfaces": "^0.5.1", + "libp2p-interfaces": "^0.7.2", "libp2p-utils": "^0.2.1", "mafmt": "^8.0.0", "merge-options": "^2.0.0", @@ -99,8 +99,8 @@ "libp2p-bootstrap": "^0.12.0", "libp2p-delegated-content-routing": "^0.7.0", "libp2p-delegated-peer-routing": "^0.7.0", - "libp2p-floodsub": "^0.23.0", - "libp2p-gossipsub": "^0.6.0", + "libp2p-floodsub": "^0.24.0", + "libp2p-gossipsub": "^0.7.0", "libp2p-kad-dht": "^0.20.0", "libp2p-mdns": "^0.15.0", "libp2p-mplex": "^0.10.1", diff --git a/src/config.js b/src/config.js index 4c9bc549..c95b1b15 100644 --- a/src/config.js +++ b/src/config.js @@ -54,10 +54,7 @@ const DefaultConfig = { autoDial: true }, pubsub: { - enabled: true, - emitSelf: true, - signMessages: true, - strictSigning: true + enabled: true }, relay: { enabled: true,