@waku/message-encryption 0.0.9 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +46 -1
- package/bundle/ecies.js +1 -1
- package/bundle/index-a56f7af2.js +8260 -0
- package/bundle/index.js +1 -1
- package/bundle/symmetric.js +1 -1
- package/dist/.tsbuildinfo +1 -0
- package/dist/crypto/ecies.js +1 -1
- package/dist/crypto/ecies.js.map +1 -1
- package/dist/crypto/index.js +1 -1
- package/dist/crypto/index.js.map +1 -1
- package/dist/decoded_message.d.ts +9 -0
- package/dist/decoded_message.js +13 -0
- package/dist/decoded_message.js.map +1 -0
- package/dist/ecies.d.ts +18 -14
- package/dist/ecies.js +18 -24
- package/dist/ecies.js.map +1 -1
- package/dist/index.d.ts +3 -10
- package/dist/index.js +0 -12
- package/dist/index.js.map +1 -1
- package/dist/symmetric.d.ts +17 -13
- package/dist/symmetric.js +18 -23
- package/dist/symmetric.js.map +1 -1
- package/dist/waku_payload.js +1 -1
- package/dist/waku_payload.js.map +1 -1
- package/package.json +41 -25
- package/src/crypto/ecies.ts +1 -1
- package/src/crypto/index.ts +1 -1
- package/src/decoded_message.ts +27 -0
- package/src/ecies.ts +41 -27
- package/src/index.ts +2 -27
- package/src/symmetric.ts +37 -31
- package/src/waku_payload.ts +1 -1
- package/bundle/index-fb7e6ca5.js +0 -15285
package/bundle/index.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
export {
|
1
|
+
export { O as OneMillion, V as Version, h as ecies, g as generatePrivateKey, d as generateSymmetricKey, a as getPublicKey, s as symmetric } from './index-a56f7af2.js';
|
package/bundle/symmetric.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
export {
|
1
|
+
export { f as createDecoder, e as createEncoder, d as generateSymmetricKey } from './index-a56f7af2.js';
|
@@ -0,0 +1 @@
|
|
1
|
+
{"program":{"fileNames":["../../../node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/typescript/lib/lib.es2019.d.ts","../../../node_modules/typescript/lib/lib.es2020.d.ts","../../../node_modules/typescript/lib/lib.dom.d.ts","../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2019.intl.d.ts","../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../node_modules/typescript/lib/lib.es2020.date.d.ts","../../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../node_modules/typescript/lib/lib.es2020.number.d.ts","../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../src/constants.ts","../../../node_modules/multiformats/dist/types/src/hashes/interface.d.ts","../../../node_modules/multiformats/dist/types/src/bases/interface.d.ts","../../../node_modules/multiformats/dist/types/src/block/interface.d.ts","../../../node_modules/multiformats/dist/types/src/link/interface.d.ts","../../../node_modules/multiformats/dist/types/src/cid.d.ts","../../../node_modules/@libp2p/interface-peer-id/dist/src/index.d.ts","../../../node_modules/@multiformats/multiaddr/dist/src/protocols-table.d.ts","../../../node_modules/@multiformats/multiaddr/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-peer-info/dist/src/index.d.ts","../../interfaces/dist/enr.d.ts","../../interfaces/dist/message.d.ts","../../../node_modules/@libp2p/interfaces/dist/src/events.d.ts","../../../node_modules/uint8arraylist/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-record/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-peer-store/dist/src/index.d.ts","../../../node_modules/@libp2p/interfaces/dist/src/index.d.ts","../../../node_modules/it-stream-types/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-connection/dist/src/status.d.ts","../../../node_modules/@libp2p/interface-connection/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-stream-muxer/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-transport/dist/src/index.d.ts","../../../node_modules/@libp2p/interfaces/dist/src/startable.d.ts","../../../node_modules/@libp2p/interface-metrics/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-address-manager/dist/src/index.d.ts","../../../node_modules/libp2p/dist/src/transport-manager.d.ts","../../../node_modules/protons-runtime/dist/src/codec.d.ts","../../../node_modules/protons-runtime/dist/src/decode.d.ts","../../../node_modules/protons-runtime/dist/src/encode.d.ts","../../../node_modules/protons-runtime/dist/src/codecs/enum.d.ts","../../../node_modules/protons-runtime/dist/src/codecs/message.d.ts","../../../node_modules/protons-runtime/dist/src/utils.d.ts","../../../node_modules/protons-runtime/dist/src/index.d.ts","../../../node_modules/libp2p/dist/src/identify/pb/message.d.ts","../../../node_modules/@libp2p/interface-registrar/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-connection-manager/dist/src/index.d.ts","../../../node_modules/libp2p/dist/src/identify/index.d.ts","../../../node_modules/@libp2p/interface-peer-discovery/dist/src/index.d.ts","../../../node_modules/libp2p/node_modules/@libp2p/interface-dht/dist/src/index.d.ts","../../../node_modules/interface-store/dist/src/index.d.ts","../../../node_modules/multiformats/dist/types/src/codecs/interface.d.ts","../../../node_modules/multiformats/dist/types/src/interface.d.ts","../../../node_modules/multiformats/dist/types/src/hashes/digest.d.ts","../../../node_modules/multiformats/dist/types/src/hashes/hasher.d.ts","../../../node_modules/multiformats/dist/types/src/varint.d.ts","../../../node_modules/multiformats/dist/types/src/bytes.d.ts","../../../node_modules/multiformats/dist/types/src/index.d.ts","../../../node_modules/multiformats/dist/types/src/codecs/raw.d.ts","../../../node_modules/multiformats/dist/types/src/codecs/json.d.ts","../../../node_modules/multiformats/dist/types/src/bases/base.d.ts","../../../node_modules/multiformats/dist/types/src/basics.d.ts","../../../node_modules/uint8arrays/dist/src/util/bases.d.ts","../../../node_modules/uint8arrays/dist/src/to-string.d.ts","../../../node_modules/interface-datastore/dist/src/key.d.ts","../../../node_modules/interface-datastore/dist/src/index.d.ts","../../../node_modules/libp2p/node_modules/@libp2p/interface-content-routing/dist/src/index.d.ts","../../../node_modules/libp2p/dist/src/circuit/index.d.ts","../../../node_modules/@libp2p/interface-connection-encrypter/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-peer-routing/dist/src/index.d.ts","../../../node_modules/it-pushable/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-pubsub/dist/src/index.d.ts","../../../node_modules/libp2p/dist/src/ping/index.d.ts","../../../node_modules/libp2p/dist/src/fetch/index.d.ts","../../../node_modules/libp2p/dist/src/components.d.ts","../../../node_modules/@libp2p/interface-libp2p/node_modules/@libp2p/interface-dht/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-libp2p/node_modules/@libp2p/interface-content-routing/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-keychain/dist/src/index.d.ts","../../../node_modules/@libp2p/interface-libp2p/dist/src/index.d.ts","../../../node_modules/libp2p/dist/src/keychain/cms.d.ts","../../../node_modules/@libp2p/crypto/node_modules/protons-runtime/dist/src/codec.d.ts","../../../node_modules/@libp2p/crypto/node_modules/protons-runtime/dist/src/decode.d.ts","../../../node_modules/@libp2p/crypto/node_modules/protons-runtime/dist/src/encode.d.ts","../../../node_modules/@libp2p/crypto/node_modules/protons-runtime/dist/src/codecs/enum.d.ts","../../../node_modules/@libp2p/crypto/node_modules/protons-runtime/dist/src/codecs/message.d.ts","../../../node_modules/@libp2p/crypto/node_modules/protons-runtime/dist/src/utils.d.ts","../../../node_modules/@libp2p/crypto/node_modules/protons-runtime/dist/src/index.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/keys.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/interface.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/key-stretcher.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/ecdh.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/ephemeral-keys.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/rsa-class.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/ed25519-class.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/secp256k1-class.d.ts","../../../node_modules/@libp2p/interface-keys/dist/src/index.d.ts","../../../node_modules/@libp2p/crypto/dist/src/keys/index.d.ts","../../../node_modules/libp2p/dist/src/keychain/index.d.ts","../../../node_modules/@achingbrain/nat-port-mapper/dist/src/index.d.ts","../../../node_modules/libp2p/dist/src/nat-manager.d.ts","../../../node_modules/libp2p/dist/src/address-manager/index.d.ts","../../../node_modules/libp2p/dist/src/peer-routing.d.ts","../../../node_modules/libp2p/dist/src/connection-manager/latency-monitor.d.ts","../../../node_modules/libp2p/dist/src/connection-manager/index.d.ts","../../../node_modules/libp2p/dist/src/index.d.ts","../../interfaces/dist/protocols.d.ts","../../interfaces/dist/filter.d.ts","../../interfaces/dist/light_push.d.ts","../../interfaces/dist/peer_exchange.d.ts","../../../node_modules/protobufjs/index.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/message/rpc.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/types.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/message-cache.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/score/peer-score-params.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/score/peer-score-thresholds.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/score/peer-stats.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/score/compute-score.d.ts","../../../node_modules/denque/index.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/score/message-deliveries.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/metrics.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/utils/set.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/score/peer-score.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/score/index.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/tracer.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/config.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/stream.d.ts","../../../node_modules/protobufjs/minimal.d.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/message/decoderpc.ts","../../../node_modules/@chainsafe/libp2p-gossipsub/dist/src/index.d.ts","../../interfaces/dist/relay.d.ts","../../interfaces/dist/store.d.ts","../../interfaces/dist/waku.d.ts","../../interfaces/dist/connection_manager.d.ts","../../interfaces/dist/index.d.ts","../../proto/node_modules/protons-runtime/dist/src/index.d.ts","../../proto/dist/lib/message.d.ts","../../proto/dist/lib/filter.d.ts","../../proto/dist/lib/topic_only_message.d.ts","../../proto/dist/lib/light_push.d.ts","../../proto/dist/lib/store.d.ts","../../proto/dist/lib/peer_exchange.d.ts","../../proto/dist/index.d.ts","../../core/dist/lib/message/version_0.d.ts","../src/decoded_message.ts","../../../node_modules/@types/ms/index.d.ts","../../../node_modules/@types/debug/index.d.ts","../../../node_modules/@noble/secp256k1/lib/index.d.ts","../../utils/dist/bytes/index.d.ts","../../../node_modules/js-sha3/index.d.ts","../src/crypto/index.ts","../src/crypto/ecies.ts","../src/crypto/symmetric.ts","../src/symmetric.ts","../src/index.ts","../src/waku_payload.ts","../src/ecies.ts","../../../node_modules/@types/node/assert.d.ts","../../../node_modules/@types/node/assert/strict.d.ts","../../../node_modules/@types/node/globals.d.ts","../../../node_modules/@types/node/async_hooks.d.ts","../../../node_modules/@types/node/buffer.d.ts","../../../node_modules/@types/node/child_process.d.ts","../../../node_modules/@types/node/cluster.d.ts","../../../node_modules/@types/node/console.d.ts","../../../node_modules/@types/node/constants.d.ts","../../../node_modules/@types/node/crypto.d.ts","../../../node_modules/@types/node/dgram.d.ts","../../../node_modules/@types/node/diagnostics_channel.d.ts","../../../node_modules/@types/node/dns.d.ts","../../../node_modules/@types/node/dns/promises.d.ts","../../../node_modules/@types/node/domain.d.ts","../../../node_modules/@types/node/dom-events.d.ts","../../../node_modules/@types/node/events.d.ts","../../../node_modules/@types/node/fs.d.ts","../../../node_modules/@types/node/fs/promises.d.ts","../../../node_modules/@types/node/http.d.ts","../../../node_modules/@types/node/http2.d.ts","../../../node_modules/@types/node/https.d.ts","../../../node_modules/@types/node/inspector.d.ts","../../../node_modules/@types/node/module.d.ts","../../../node_modules/@types/node/net.d.ts","../../../node_modules/@types/node/os.d.ts","../../../node_modules/@types/node/path.d.ts","../../../node_modules/@types/node/perf_hooks.d.ts","../../../node_modules/@types/node/process.d.ts","../../../node_modules/@types/node/punycode.d.ts","../../../node_modules/@types/node/querystring.d.ts","../../../node_modules/@types/node/readline.d.ts","../../../node_modules/@types/node/readline/promises.d.ts","../../../node_modules/@types/node/repl.d.ts","../../../node_modules/@types/node/stream.d.ts","../../../node_modules/@types/node/stream/promises.d.ts","../../../node_modules/@types/node/stream/consumers.d.ts","../../../node_modules/@types/node/stream/web.d.ts","../../../node_modules/@types/node/string_decoder.d.ts","../../../node_modules/@types/node/test.d.ts","../../../node_modules/@types/node/timers.d.ts","../../../node_modules/@types/node/timers/promises.d.ts","../../../node_modules/@types/node/tls.d.ts","../../../node_modules/@types/node/trace_events.d.ts","../../../node_modules/@types/node/tty.d.ts","../../../node_modules/@types/node/url.d.ts","../../../node_modules/@types/node/util.d.ts","../../../node_modules/@types/node/v8.d.ts","../../../node_modules/@types/node/vm.d.ts","../../../node_modules/@types/node/wasi.d.ts","../../../node_modules/@types/node/worker_threads.d.ts","../../../node_modules/@types/node/zlib.d.ts","../../../node_modules/@types/node/globals.global.d.ts","../../../node_modules/@types/node/index.d.ts","../../../node_modules/@types/mocha/index.d.ts"],"fileInfos":[{"version":"8730f4bf322026ff5229336391a18bcaa1f94d4f82416c8b2f3954e2ccaae2ba","affectsGlobalScope":true,"impliedFormat":1},{"version":"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","impliedFormat":1},{"version":"7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","impliedFormat":1},{"version":"8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","impliedFormat":1},{"version":"5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","impliedFormat":1},{"version":"4b421cbfb3a38a27c279dec1e9112c3d1da296f77a1a85ddadf7e7a425d45d18","impliedFormat":1},{"version":"1fc5ab7a764205c68fa10d381b08417795fc73111d6dd16b5b1ed36badb743d9","impliedFormat":1},{"version":"3aafcb693fe5b5c3bd277bd4c3a617b53db474fe498fc5df067c5603b1eebde7","affectsGlobalScope":true,"impliedFormat":1},{"version":"adb996790133eb33b33aadb9c09f15c2c575e71fb57a62de8bf74dbf59ec7dfb","affectsGlobalScope":true,"impliedFormat":1},{"version":"8cc8c5a3bac513368b0157f3d8b31cfdcfe78b56d3724f30f80ed9715e404af8","affectsGlobalScope":true,"impliedFormat":1},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true,"impliedFormat":1},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true,"impliedFormat":1},{"version":"5f406584aef28a331c36523df688ca3650288d14f39c5d2e555c95f0d2ff8f6f","affectsGlobalScope":true,"impliedFormat":1},{"version":"22f230e544b35349cfb3bd9110b6ef37b41c6d6c43c3314a31bd0d9652fcec72","affectsGlobalScope":true,"impliedFormat":1},{"version":"7ea0b55f6b315cf9ac2ad622b0a7813315bb6e97bf4bb3fbf8f8affbca7dc695","affectsGlobalScope":true,"impliedFormat":1},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true,"impliedFormat":1},{"version":"eb26de841c52236d8222f87e9e6a235332e0788af8c87a71e9e210314300410a","affectsGlobalScope":true,"impliedFormat":1},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true,"impliedFormat":1},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true,"impliedFormat":1},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true,"impliedFormat":1},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true,"impliedFormat":1},{"version":"81cac4cbc92c0c839c70f8ffb94eb61e2d32dc1c3cf6d95844ca099463cf37ea","affectsGlobalScope":true,"impliedFormat":1},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true,"impliedFormat":1},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true,"impliedFormat":1},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true,"impliedFormat":1},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true,"impliedFormat":1},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true,"impliedFormat":1},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true,"impliedFormat":1},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true,"impliedFormat":1},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true,"impliedFormat":1},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true,"impliedFormat":1},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true,"impliedFormat":1},{"version":"5e5e095c4470c8bab227dbbc61374878ecead104c74ab9960d3adcccfee23205","affectsGlobalScope":true,"impliedFormat":1},{"version":"09aa50414b80c023553090e2f53827f007a301bc34b0495bfb2c3c08ab9ad1eb","affectsGlobalScope":true,"impliedFormat":1},{"version":"d7f680a43f8cd12a6b6122c07c54ba40952b0c8aa140dcfcf32eb9e6cb028596","affectsGlobalScope":true,"impliedFormat":1},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true,"impliedFormat":1},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true,"impliedFormat":1},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true,"impliedFormat":1},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true,"impliedFormat":1},{"version":"2768ef564cfc0689a1b76106c421a2909bdff0acbe87da010785adab80efdd5c","affectsGlobalScope":true,"impliedFormat":1},{"version":"b248e32ca52e8f5571390a4142558ae4f203ae2f94d5bac38a3084d529ef4e58","affectsGlobalScope":true,"impliedFormat":1},{"version":"52d1bb7ab7a3306fd0375c8bff560feed26ed676a5b0457fa8027b563aecb9a4","affectsGlobalScope":true,"impliedFormat":1},{"version":"f551b213aa991a566433a10dd54ee0bfc47f7c1756b5f13c878e2b6c73787443","signature":"d7cb663688b9de85afbb2d4f087308f722c44d0e4f24495000b9ae417acf2fce","impliedFormat":99},{"version":"65da6f0b8f50b27e05ebf35c88a8757eb4308751cdf2b1064a0e310a2a485895","impliedFormat":99},{"version":"2e3dc1d28f2467b2af0c931a3b0d2c595746a2f21818fc3c7b5d050996ace788","impliedFormat":99},{"version":"237be372eeb9a7ce07c6b2a21358f22772cde924614d67de175a4ac0ba3eb486","impliedFormat":99},{"version":"862eacc247d6c92524d7879feac6da363f55428cc78270bce7b14f2d3d0b0cef","impliedFormat":99},{"version":"f55f3ab9485b5fd1a3ba3a5a53e680cb8d3acc3552816a5d58a1fa26324262d0","impliedFormat":99},{"version":"ee93f3313289b31afd1544da65086607942df227eb61aedf488b7c072aa1128f","impliedFormat":99},{"version":"5d055d8b54e2dec3fe4aa417f5f664658b78123e83e8735047285f99a1d24065","impliedFormat":99},{"version":"1b03f8d19b753269d85e2e50ec2a2866bf349fb4f6e72aef6559e94c64511dee","impliedFormat":99},{"version":"edb50eace77052203c3bc6eb251fe31f44ab0107e2b6d949ec983a918726aaf4","impliedFormat":99},{"version":"a5419b108da7e4c0241d74ab53bf2041c62e77815965d24605c2407415f11c5d","impliedFormat":99},{"version":"c9ca50a4faff709bceadf9a51c7e4743d5dff717459a044e3b24193f3988b658","impliedFormat":99},{"version":"4a5612eb59f581a5b8e05d22e668b4199787751266a0291e3e07113fc52abf2a","impliedFormat":99},{"version":"ea86fe238f679714f2b3662d9d932bc3b47a0500894985718243167043f2bda8","impliedFormat":99},{"version":"866f0c4f16380a56653adc6cbeac08c58c626dabb431f0fa6cc2ba07874836d8","impliedFormat":99},{"version":"e8c5b68c1182684e8cfc177430b80fef003976d1dbde326087c28f5125fe4b5d","impliedFormat":99},{"version":"a807c0a82557d68f6f0464d6af0a6566d1ef708f57c7d1d7dd8dde28879635bc","impliedFormat":99},{"version":"a2023e18c62b1109f17241fb1f90a84e75fffcb3ee9265d2e9bc0fa40b6ede42","impliedFormat":99},{"version":"6666d48a46dbfd565490e7f8789093e2392c5bdcc3a380dfdd91c77237e43101","impliedFormat":99},{"version":"6377354dd753557d479933e0bec6ca6836f839c87394ecb071e85f062b708058","impliedFormat":99},{"version":"4c5e54a2d502770a63859a00fbf77e8b91ce76b18080278f62866e7cdb582798","impliedFormat":99},{"version":"71dfda7df8d05d2d54627963af1c3c675ef99363d421b7ff42ae237d038db4ce","impliedFormat":99},{"version":"16c594cd8a44be9f5398d3fc7dbc9575f0b67d91a6553f35bd3576136862b32b","impliedFormat":99},{"version":"0fc1e0effc8ea83ceca9a1ff36c2696489fefea040d33fc5cbe244111333fcd4","impliedFormat":99},{"version":"0dd67171a4a3fa82044faec51befa11ab96f9205fd8cc96be09de275b65d36ab","impliedFormat":99},{"version":"42570779c28480ae0d1fa0695974a888305ee2b2efd37bacdeb57204dec843db","impliedFormat":99},{"version":"20e85d1b2ce7381a938a25a725a90f8610e68862c5a661acfeffaacd6513d392","impliedFormat":99},{"version":"667c9ac7c2f61c4a36220c2fa02f848a170aa96d3a58be32a5831aad86330da2","impliedFormat":99},{"version":"eb15dfd1f8b6da5f546fe29a6a0f0de4ae6dbd4a5577af4eba4c8a54548ef0a2","impliedFormat":99},{"version":"01443e5da049881a99f223c72617d4bb1d8854930d03deceb628e4be83df1e4a","impliedFormat":99},{"version":"76513b0c51c81a929f4f90694edf4dcc85f71bb46121b4192b5530e0601f9d81","impliedFormat":99},{"version":"a0263cc045540023e72c993a26fd1bef3adf8674b9719272009134c56ecfc336","impliedFormat":99},{"version":"df162b6f89985144d8aedccc36dfc366ab5e562ba8615125b2bfa25273f3006b","impliedFormat":99},{"version":"0820608ae5bf3995d77eedf0fa7f987c0d5c7c9592fdc0bcb391fb742d5067a0","impliedFormat":99},{"version":"14b8a1dd226271e6b045d91262602b15820ff871b3dab24510a15e6989d05a5d","impliedFormat":99},{"version":"5fe19747d9189572ddeeac452f5dcda8fa60fcd0f7b423f0f079bdec3cddbafe","impliedFormat":99},{"version":"274b714a925cc417f249f430b9c5c3ec80986044d8322d41e40fd39a7d154fa8","impliedFormat":99},{"version":"70cbb43b1e838bb77b16e1085115494c8b6925a954edf7fbdd494ad56a88adb8","impliedFormat":99},{"version":"ad716342f559ff88871c01a351dbf89fe72c8313f329cd2a714f09f532c50eab","impliedFormat":99},{"version":"6adc54eb855f3fda2603173a431be81830172099df37ddda11b6730c1c8d9147","impliedFormat":1},{"version":"8ad13afb5324460426b210f7c5040d3d19375accd24e22bb52a534c728aca73e","impliedFormat":99},{"version":"e1fe04ff1ffecfb18420f0895d0cd2652f98a27def5c33aae5ef328f186c905b","impliedFormat":99},{"version":"635e7c978a30ab2013a37c4d05d0d081e58e4ad867db46a009412ad24ee426d7","impliedFormat":99},{"version":"b27c2a28daf3e502ae6b631cbf51881247fffd3e0163520bc5904604f9e48096","impliedFormat":99},{"version":"87b44430497cae7542bbd5ac2fb6663df6a465dea7a46be58a49cd9416530439","impliedFormat":99},{"version":"32b67d761db3999f1e482d0add405b695d3ec5607e07ae4c963a96334c331814","impliedFormat":99},{"version":"8747571dae434deca4847b49e09b5421d7068b0956a1df841756812645d4e1ed","impliedFormat":99},{"version":"474ab86e676e0c1b664bfcd21b1e58bed351f3390ba1d892e8da703f371b7a4e","impliedFormat":99},{"version":"fb7a601066e19b5d0c173b564bd46b358cf00c9040e79fb6fd427b7aa223eed1","impliedFormat":99},{"version":"4a8ce4a308482d69bd9032ee59f895a9d91e28ac5324665b31ea3a374b45e686","impliedFormat":99},{"version":"8b097e48fdeabcee00e2aacd4d009dff135c2cd51675a272d74ec25dd853dfee","impliedFormat":99},{"version":"28235440c6b330eb66df3a7badfc11e32cf7e08fbdb17b518a6b775fb269170f","impliedFormat":99},{"version":"247a5bebf668df6d3bb7e0b297ed5a6b6913d9343dcfea5bf77ce4662ab102bf","impliedFormat":99},{"version":"531556008024c69163c0d120823a69e7a6a5be1279ea87fc725a63dc386278b7","impliedFormat":99},{"version":"df99b5b6041e9e37b46c876cd487020e4bc9e02a519fa4a735cbe18f5c4f2f38","impliedFormat":99},{"version":"272cd5e6428b68d973ce707329c3f621ac6b3eb4bf5bd4421b1106299600ddde","impliedFormat":99},{"version":"2202644315d85ab8985d4f72fe136c00e53db91ac06a0646eff7980e55bdacb3","impliedFormat":99},{"version":"cd5ab2f30a27d53001804b7ef51758a79b73e4ccb7716b8e2ab8e17d69a7183b","impliedFormat":99},{"version":"9080b537cd4fa24273477f33faf5f983e5f10aa386c2de8fcb6de837c9cc9763","impliedFormat":99},{"version":"d34a8917095f11006957bed03e1e60dacc0b82906f5d0ddc87b959e283fbb5cc","impliedFormat":99},{"version":"bffe8a5db9410d2f3320df7016f83e9de47328e377aa78b9aaed1fe6d5db9d66","impliedFormat":99},{"version":"a9dc4418352bc4a8d1e9314aba1e29327b17d06c604b397c6140d6488c5b022a","impliedFormat":99},{"version":"6adcf362e079c177ea4730c8b7beb3e9848b3f970ef08b497a641e034b0a0ece","impliedFormat":99},{"version":"114ef8adba09ab579b6bd6d16b2c83ddea02c1f5ff598f3144f2c3853ef3eb7d","impliedFormat":99},{"version":"ad716342f559ff88871c01a351dbf89fe72c8313f329cd2a714f09f532c50eab","impliedFormat":99},{"version":"272cd5e6428b68d973ce707329c3f621ac6b3eb4bf5bd4421b1106299600ddde","impliedFormat":99},{"version":"1217c84b164e559b2371aea1b8c11eea9f95e123dab98942c8a5a4aacc2ad252","impliedFormat":99},{"version":"ff7cac2918f2366662638f93e820f2ec9fd86e5786eb494e6757b707f8a10216","impliedFormat":99},{"version":"995a3938e28f1a7e359847f83b43951c05727b6ca42398982778adc8b9a58609","impliedFormat":99},{"version":"77411d10dad0e74a86ce28dd0f720cce2947421e42f3fb5d1849bc14520f9b5b","impliedFormat":99},{"version":"667c9ac7c2f61c4a36220c2fa02f848a170aa96d3a58be32a5831aad86330da2","impliedFormat":99},{"version":"eb15dfd1f8b6da5f546fe29a6a0f0de4ae6dbd4a5577af4eba4c8a54548ef0a2","impliedFormat":99},{"version":"01443e5da049881a99f223c72617d4bb1d8854930d03deceb628e4be83df1e4a","impliedFormat":99},{"version":"a380f922477db0b9b4a17cde7d29585e2280036fd62ac4564814d4844b64717a","impliedFormat":99},{"version":"a0263cc045540023e72c993a26fd1bef3adf8674b9719272009134c56ecfc336","impliedFormat":99},{"version":"df162b6f89985144d8aedccc36dfc366ab5e562ba8615125b2bfa25273f3006b","impliedFormat":99},{"version":"1a57e52e42a8ff2121d47cba8133c73b4e10ede7252881dc131cf514b28f884e","impliedFormat":99},{"version":"cfb5cd87dcce3ac2d6e4e575ae732791e1d77e047c0018bfc5f9e4d1ba355719","impliedFormat":99},{"version":"a979d3d312f1d879a5c77493697380b6caae9333e2fe0f51bb0fb0473dc211ba","impliedFormat":99},{"version":"aaf4673898dca18c059997aae0e8ae725215c8ee0998e9d4a6fd173384276748","impliedFormat":99},{"version":"b90473059128d1a4c028852a710058a3a8944835188672f5846deba05a1e778e","impliedFormat":99},{"version":"216601fa3da32170d99a6cbdea143a00dfd5a7bfddcf231126493c0ab992daf4","impliedFormat":99},{"version":"06245aedbc73b4f39fabd67ab13f451e009489bd66dac614184c8f97034f8016","impliedFormat":99},{"version":"b3bff8270798e03d00349137271e3f11074ec5281a393289dd8f33f37627828b","impliedFormat":99},{"version":"3b65ca51bc8915ae230bb40cb6a9662bcdcde83c402f57d7f8b8c803d497d0af","impliedFormat":99},{"version":"28393110732dca5855c0fd444777dc978d010ecba3204c4c48cfa26ee612bc13","impliedFormat":99},{"version":"01fd310805f9c29fc38a6580e32f75291d5dd3918e7acdfc7d50548ba0c4bf9b","impliedFormat":99},{"version":"f569da0d6f4c6fb153811dd6b7d34afb4511c7d85f5089e30a1db78004975ec1","impliedFormat":99},{"version":"537b1070107a0454a2fe365a633555700fff55a4b3e15d55520633b93dbf96d1","impliedFormat":99},{"version":"6b616e00e177a11c8054c70c821ca2d0c976403d11ad466385dddc89245e7ade","impliedFormat":99},{"version":"8dac050016c78a797699221c95d569c47ea4176e403b47f9f5a2e95afe26cdd6","impliedFormat":99},{"version":"d8a63ecc9188f8ef5fce8c82ea2c691acce9a152b8bd07d75a6531c7d4c07df9","impliedFormat":99},{"version":"4967ab74e79f8d087627020dd95dd6f803b79a14410acb11b4c8a33db61bdcf3","impliedFormat":99},{"version":"41326ccdc0707b973e3a285711e4d4ff37b999745d1539e346800a8f1db8e702","impliedFormat":99},{"version":"b70c5f86a62c2c46fa4913b0b5e26842082247f74b97f31b3e87acef5a72a11e","impliedFormat":99},{"version":"3d17b221e1c790c0c4e3d9b5273441ce37c565401da264d39b68ded63bc2bcb1","impliedFormat":99},{"version":"dd3bbce19d5616301284fe5c4bdbe8891c4cc5f665070e91a7cc91551f3bf3ad","impliedFormat":99},{"version":"e16b8df321e9a03f1fb2ed860f06a44f6630923afac56f008194a7f700c60548","impliedFormat":99},{"version":"1558c642e03689d42843e7b047b9c20e77ee09ab388ff854484db5dcfbed11da","impliedFormat":1},{"version":"925a8770415572378b7b62dcd714e744b7ffed86de59bdbe1d25c68d9d1f7f51","impliedFormat":99},{"version":"95a29532177f932fec5fc4e51577eaae6bd037fd21188fb3060a3e5c9fbc806a","impliedFormat":99},{"version":"53fd58c3edf98bdecd9f4fccab88f8f34b5c7ea3d7411b7c2aeea77419048789","impliedFormat":99},{"version":"831f1ad45e156fa12bf736f4895329cb6e785f1c940fc58043718409d9845a43","impliedFormat":99},{"version":"32ffd3e74601a33cbf6a7596e00338eba67cf598faed2903be4281ba7ec076b5","impliedFormat":99},{"version":"a74df8c2d7267abcce2128511b4260a68eb1a377db38a95ec7e9a58aa98beb02","impliedFormat":99},{"version":"bc78b25c3aaf139ca527952875c53bff67360e6b5812b82a8fa89fdefb720879","impliedFormat":99},{"version":"460f30d6ea494bbf076853e1588d30ec4651efcc26cbfcd2c91362f7efc87e89","impliedFormat":1},{"version":"b96a5c8de20ea0ec0bd266593fdafce71126c8d9f02cb292ed106dccc1bc45b5","impliedFormat":99},{"version":"20c01d0e02f7668253adca2048bf4577071c4fb7ced36f6bc1e4d994c657d54c","impliedFormat":99},{"version":"58e4a27ed43582c3d5322a2460f8016562b709454498c39b1bff15aab648125b","impliedFormat":99},{"version":"4a79e2c6d0d94fcb0f8eff4a518c2b75da5ccf9b9cc67ee80cf2e33e9e0c8aff","impliedFormat":99},{"version":"ce218e7127b5c109cc128316dcafb71146b483c3476cb6e30c4a84e38a4ea7e7","impliedFormat":99},{"version":"989a1bfc460b911efd1e8869871d820b7a75993c8fb39ab71a4d548f1bacf4a8","impliedFormat":99},{"version":"60ca66c2e560e891c4bbac8a6664edeb14a2757c1269bc4a5be91859fe70b14e","impliedFormat":99},{"version":"4554975154067a41dbf852d4d68c887940ad9ff463a9e8415c37c6cf8dc9b10c","impliedFormat":99},{"version":"932cade1c5802123b5831f332ad8a6297f0f7d14d0ee04f5a774408f393e2200","impliedFormat":1},{"version":"1165dc3daad62e737ee6c7016470a4a9a4c751be9f47da494a718a0b428bfe49","impliedFormat":99},{"version":"507246c9be0c2ede6a41b75e144065bf780601d67d2d9816f9b362aeb0e24649","impliedFormat":99},{"version":"062a1440942f6bfb63c776fb8134a0b460bb54a5c7e9a02cfbd9808b6f5be580","impliedFormat":99},{"version":"9baaecd1ece45f7966156fcb69f9d366aed3d1e8e604e58042970de681228929","impliedFormat":99},{"version":"15a6ebf6dc00e8474f7ee0e2c6321b7ad328b4b59d03ee7b103c94a71bbd3a7e","impliedFormat":99},{"version":"3e836ec68dd734248c913405f458ed2c66565c4fa4647aa1d0cb8fe5f35e2d66","impliedFormat":99},{"version":"abbbe08968ef627d1855a78df95d2eb8c22c2e3acb9d49f0592e4eeaa1299c5f","impliedFormat":99},{"version":"df162b6f89985144d8aedccc36dfc366ab5e562ba8615125b2bfa25273f3006b","impliedFormat":99},{"version":"5ec51a1b0934060be2db5ae753a2e87c886d8bd29202e386e879f53d533f667a","impliedFormat":99},{"version":"fc3c4f010e13346075017000672a21f0c38fdd1244d103e52986cf4ba2cb4509","impliedFormat":99},{"version":"6bd10e63915e6df4884eb7a976b62270f725acc75fe4bca1c5bb79a1f5cfe087","impliedFormat":99},{"version":"d131027d5e545d09b3afab4db6ce22be8c86c9566ca728c366124eb599a3d721","impliedFormat":99},{"version":"6049237ebfb9de4aa00842ed2ace9cfa49590ad2031cd5629f945a873bc8597a","impliedFormat":99},{"version":"cbd7b087b10633abe1488613115c681bb1b6345f0a4773b4ccddbfba390042bb","impliedFormat":99},{"version":"4b3e6ba81a1b93b76c86b790e4877531be79d9309a26ec621454d286264e7389","impliedFormat":99},{"version":"e11221c80fc23ede642aec61750b4bd5e11be67fbf1df9e573a061943f5a6557","impliedFormat":99},{"version":"dc312b5972985f777e3af3caf8d401881d6be6decf8a766593a4edcf37cdc3b2","signature":"66defa505f19f50b6f746e6c0694b90f8f0e54a473c098b3f590736423c808b0","impliedFormat":99},{"version":"6a9c5127096b35264eb7cd21b2417bfc1d42cceca9ba4ce2bb0c3410b7816042","impliedFormat":1},{"version":"78828b06c0d3b586954015e9ebde5480b009e166c71244763bda328ec0920f41","impliedFormat":1},{"version":"193f3eeb12d0c70404fddd0d6c6d395a6721320284d0d4d39e0538e47ac6931e","impliedFormat":1},{"version":"f98f7fd5c208374f072a67a46306ab9b3f914554b4ebb673fb805e13a4119b6c","impliedFormat":99},{"version":"f0dbab413bd86c25237078f4219b5cb79099aca5ec2ebf2169513dd669aa8d83","impliedFormat":1},{"version":"c84f72feb0527c318057748a39b75358e8848923818d1e248ba8a28884db685b","signature":"b5035233a800963cca943eb114bdc05b39aaf1fc99518063bbb8ef5142acabbd","impliedFormat":99},{"version":"a8313cd40d71930b7a7ae5ab0a91f37c5119157bdbc72ad89e9172686dbef9e8","signature":"d61070b984349999abf7a48befd4d7591fe96f96519e42b425fde05bc84c33c3","impliedFormat":99},{"version":"c3a74f20b1bcc9b94884e6f60c7e2134d2184633252231e4c38c5da1bc464a09","signature":"bb37f2cc15dd47cc61f9ebd65dfa2c87efd447e882eb91c033c60364f03a5e70","impliedFormat":99},{"version":"d6f77b9f06aa56c048bc4473ba9c107cf6c16395d579878e6f7f7db5aa65db78","signature":"f126e51a1ff8fa8368082397bc13aee595666ee34adcb930f7d08839fc745fc0","impliedFormat":99},{"version":"a9a2304f4911bad076e7034b70976405bc65797386f62a2d25f1da5613fa2c97","signature":"13ddc17f3a84f17717ab7b9f8099b45a89660b25af84ba8df8c687e5a6da4d3e","impliedFormat":99},{"version":"90b7b43efc96f2bbc8f4db6d894c29fb00015bc9acde50fefb3f00eb69dc7cfd","signature":"3d60460e4a67c256de3b49e2827fee9c52fd2d10f2b398916b97d66408f8346e","impliedFormat":99},{"version":"8f29c658daf4d42cc012d4cbc3c02c842ed92369646921c44b3711932baf64a7","signature":"0d79a1e67f0deb8d1ed144f6add7f5dbd7b2fe81eb87bf3cc60920cd43343616","impliedFormat":99},{"version":"7e771891adaa85b690266bc37bd6eb43bc57eecc4b54693ead36467e7369952a","impliedFormat":1},{"version":"a69c09dbea52352f479d3e7ac949fde3d17b195abe90b045d619f747b38d6d1a","impliedFormat":1},{"version":"ca72190df0eb9b09d4b600821c8c7b6c9747b75a1c700c4d57dc0bb72abc074c","affectsGlobalScope":true,"impliedFormat":1},{"version":"11e2d554398d2bd460e7d06b2fa5827a297c8acfbe00b4f894a224ac0862857f","impliedFormat":1},{"version":"e193e634a99c9c1d71f1c6e4e1567a4a73584328d21ea02dd5cddbaad6693f61","affectsGlobalScope":true,"impliedFormat":1},{"version":"374ca798f244e464346f14301dc2a8b4b111af1a83b49fffef5906c338a1f922","impliedFormat":1},{"version":"5a94487653355b56018122d92392beb2e5f4a6c63ba5cef83bbe1c99775ef713","impliedFormat":1},{"version":"d5135ad93b33adcce80b18f8065087934cdc1730d63db58562edcf017e1aad9b","affectsGlobalScope":true,"impliedFormat":1},{"version":"82408ed3e959ddc60d3e9904481b5a8dc16469928257af22a3f7d1a3bc7fd8c4","impliedFormat":1},{"version":"5eb881ed2a0d5b17ea36df5cd4c4be500e460c412f270c3170e906bec65580ac","impliedFormat":1},{"version":"bb9c4ffa5e6290c6980b63c815cdd1625876dadb2efaf77edbe82984be93e55e","impliedFormat":1},{"version":"489532ff54b714f0e0939947a1c560e516d3ae93d51d639ab02e907a0e950114","impliedFormat":1},{"version":"f30bb836526d930a74593f7b0f5c1c46d10856415a8f69e5e2fc3db80371e362","impliedFormat":1},{"version":"14b5aa23c5d0ae1907bc696ac7b6915d88f7d85799cc0dc2dcf98fbce2c5a67c","impliedFormat":1},{"version":"5c439dafdc09abe4d6c260a96b822fa0ba5be7203c71a63ab1f1423cd9e838ea","impliedFormat":1},{"version":"6b526a5ec4a401ca7c26cfe6a48e641d8f30af76673bad3b06a1b4504594a960","affectsGlobalScope":true,"impliedFormat":1},{"version":"816ad2e607a96de5bcac7d437f843f5afd8957f1fa5eefa6bba8e4ed7ca8fd84","affectsGlobalScope":true,"impliedFormat":1},{"version":"80473bd0dd90ca1e166514c2dfead9d5803f9c51418864ca35abbeec6e6847e1","impliedFormat":1},{"version":"1c84b46267610a34028edfd0d035509341751262bac1062857f3c8df7aff7153","impliedFormat":1},{"version":"5eec82ac21f84d83586c59a16b9b8502d34505d1393393556682fe7e7fde9ef2","impliedFormat":1},{"version":"04eb6578a588d6a46f50299b55f30e3a04ef27d0c5a46c57d8fcc211cd530faa","impliedFormat":1},{"version":"8d3c583a07e0c37e876908c2d5da575019f689df8d9fa4c081d99119d53dba22","impliedFormat":1},{"version":"2c828a5405191d006115ab34e191b8474bc6c86ffdc401d1a9864b1b6e088a58","impliedFormat":1},{"version":"e630e5528e899219ae319e83bef54bf3bcb91b01d76861ecf881e8e614b167f0","affectsGlobalScope":true,"impliedFormat":1},{"version":"bcebb922784739bdb34c18ee51095d25a92b560c78ccd2eaacd6bd00f7443d83","impliedFormat":1},{"version":"7ee6ed878c4528215c82b664fe0cfe80e8b4da6c0d4cc80869367868774db8b1","impliedFormat":1},{"version":"b0973c3cbcdc59b37bf477731d468696ecaf442593ec51bab497a613a580fe30","impliedFormat":1},{"version":"4989e92ba5b69b182d2caaea6295af52b7dc73a4f7a2e336a676722884e7139d","affectsGlobalScope":true,"impliedFormat":1},{"version":"b3624aed92dab6da8484280d3cb3e2f4130ec3f4ef3f8201c95144ae9e898bb6","affectsGlobalScope":true,"impliedFormat":1},{"version":"5153a2fd150e46ce57bb3f8db1318d33f6ad3261ed70ceeff92281c0608c74a3","impliedFormat":1},{"version":"210d54cd652ec0fec8c8916e4af59bb341065576ecda039842f9ffb2e908507c","impliedFormat":1},{"version":"36b03690b628eab08703d63f04eaa89c5df202e5f1edf3989f13ad389cd2c091","impliedFormat":1},{"version":"0effadd232a20498b11308058e334d3339cc5bf8c4c858393e38d9d4c0013dcf","impliedFormat":1},{"version":"25846d43937c672bab7e8195f3d881f93495df712ee901860effc109918938cc","impliedFormat":1},{"version":"fd93cee2621ff42dabe57b7be402783fd1aa69ece755bcba1e0290547ae60513","impliedFormat":1},{"version":"1b952304137851e45bc009785de89ada562d9376177c97e37702e39e60c2f1ff","impliedFormat":1},{"version":"69ee23dd0d215b09907ad30d23f88b7790c93329d1faf31d7835552a10cf7cbf","impliedFormat":1},{"version":"44b8b584a338b190a59f4f6929d072431950c7bd92ec2694821c11bce180c8a5","impliedFormat":1},{"version":"23b89798789dffbd437c0c423f5d02d11f9736aea73d6abf16db4f812ff36eda","impliedFormat":1},{"version":"09326ae5f7e3d49be5cd9ea00eb814770e71870a438faa2efd8bdd9b4db21320","impliedFormat":1},{"version":"3c4ba1dd9b12ffa284b565063108f2f031d150ea15b8fafbdc17f5d2a07251f3","affectsGlobalScope":true,"impliedFormat":1},{"version":"e10177274a35a9d07c825615340b2fcde2f610f53f3fb40269fd196b4288dda6","impliedFormat":1},{"version":"c4577fb855ca259bdbf3ea663ca73988ce5f84251a92b4aef80a1f4122b6f98e","impliedFormat":1},{"version":"3c13ef48634e7b5012fcf7e8fce7496352c2d779a7201389ca96a2a81ee4314d","impliedFormat":1},{"version":"5d0a25ec910fa36595f85a67ac992d7a53dd4064a1ba6aea1c9f14ab73a023f2","impliedFormat":1},{"version":"f0900cd5d00fe1263ff41201fb8073dbeb984397e4af3b8002a5c207a30bdc33","affectsGlobalScope":true,"impliedFormat":1},{"version":"ff07a9a03c65732ccc59b3c65bc584173da093bd563a6565411c01f5703bd3cb","affectsGlobalScope":true,"impliedFormat":1},{"version":"06d7c42d256f0ce6afe1b2b6cfbc97ab391f29dadb00dd0ae8e8f23f5bc916c3","impliedFormat":1},{"version":"ec4bd1b200670fb567920db572d6701ed42a9641d09c4ff6869768c8f81b404c","impliedFormat":1},{"version":"e59a892d87e72733e2a9ca21611b9beb52977be2696c7ba4b216cbbb9a48f5aa","impliedFormat":1},{"version":"da26af7362f53d122283bc69fed862b9a9fe27e01bc6a69d1d682e0e5a4df3e6","affectsGlobalScope":true,"impliedFormat":1},{"version":"8a300fa9b698845a1f9c41ecbe2c5966634582a8e2020d51abcace9b55aa959e","impliedFormat":1},{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true,"impliedFormat":1},{"version":"d8d555f3d607ecaa18d55de6995ea8f206342ecc93305919eac945c7c78c78c6","impliedFormat":1},{"version":"677646e2620795c98a539fb12fb531f10331c217cef1492132b2518f894fa92d","affectsGlobalScope":true,"impliedFormat":1}],"options":{"alwaysStrict":true,"declaration":true,"esModuleInterop":true,"module":6,"noFallthroughCasesInSwitch":true,"noImplicitAny":true,"noImplicitReturns":true,"noImplicitThis":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","rootDir":"../src","skipLibCheck":true,"sourceMap":true,"strict":true,"strictFunctionTypes":true,"strictNullChecks":true,"strictPropertyInitialization":true,"target":7,"tsBuildInfoFile":"./.tsbuildinfo"},"fileIdsList":[[234],[49,55,58,77,78,103,142,143,144,151,154,155,156,157,159,234],[142,143,234],[142,158,234],[141,234],[103,142,143,146,234],[145,147,234],[145,146,153,234],[149,234],[143,145,147,148,150,151,152,234],[143,234],[56,62,234],[143,151,234],[49,51,103,127,142,234],[120,234],[89,234],[122,234],[119,121,123,124,125,126,127,234],[56,118,234],[118,234],[112,234],[112,118,234],[56,112,234],[112,113,114,115,116,117,234],[51,55,234],[49,60,234],[49,51,55,59,62,234],[49,51,56,59,60,61,234],[45,49,234],[49,51,52,55,58,59,62,65,66,77,81,98,101,103,109,234],[48,52,59,234],[48,49,52,59,80,234],[62,234],[52,55,234],[44,48,234],[49,51,234],[49,52,59,234],[49,51,52,55,57,234],[49,55,56,62,102,234],[49,56,234],[49,62,234],[59,60,62,234],[51,55,59,60,62,63,234],[50,234],[51,234],[176,234],[188,234],[191,234],[192,197,225,234],[193,204,205,212,222,233,234],[193,194,204,212,234],[195,234],[196,197,205,213,234],[197,222,230,234],[198,200,204,212,234],[199,234],[200,201,234],[204,234],[202,204,234],[204,205,206,222,233,234],[204,205,206,219,222,225,234],[234,238],[200,207,212,222,233,234],[204,205,207,208,212,222,230,233,234],[207,209,222,230,233,234],[188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240],[204,210,234],[211,233,234],[200,204,212,222,234],[213,234],[214,234],[191,215,234],[216,232,234,238],[217,234],[218,234],[204,219,220,234],[219,221,234,236],[192,204,222,223,224,225,234],[192,222,224,234],[222,223,234],[225,234],[226,234],[204,228,229,234],[228,229,234],[197,212,222,230,234],[231,234],[212,232,234],[192,207,218,233,234],[197,234],[222,234,235],[234,236],[234,237],[192,197,204,206,215,222,233,234,236,238],[222,234,239],[82,96,234],[95,234],[49,51,55,64,67,234],[49,58,64,65,77,78,98,234],[49,58,62,64,65,66,67,77,78,81,97,98,101,103,234],[49,51,55,58,59,62,64,65,66,78,134,234],[55,234],[49,59,62,65,77,78,234],[49,51,58,59,62,65,67,76,77,78,234],[56,75,234],[49,52,58,59,62,63,64,66,68,79,80,81,97,98,99,100,101,103,104,105,106,110,129,131,132,133,135,234],[129,234],[49,97,111,128,234],[49,64,65,67,130,234],[49,52,58,59,65,101,234],[49,59,65,77,78,234],[51,55,59,62,64,65,66,67,234],[45,234],[89,90,91,92,234],[47,48,234],[47,234],[46,234],[83,234],[44,234],[44,85,234],[48,84,85,86,87,88,234],[44,45,46,47,83,234],[44,45,46,234],[75,234],[69,234],[69,75,234],[56,69,234],[69,70,71,72,73,74,234],[94,234],[89,93,234],[165,173,234],[49,51,52,234],[54,137,234],[53,54,137,138,139,140,161,162,163,164,234],[49,53,58,78,137,234],[49,54,58,136,234],[54,55,137,160,234],[49,51,62,110,137,138,139,161,162,234],[178,179,181,234],[43,178,179,180,197,234],[43,181,234],[165,174,234],[165,173,174,175,177,185,186,234],[175,181,184,187,234],[43,178,179,181,182,183,185,234],[167,168,169,170,171,172,234],[178],[165,174],[165,174,175,185],[175,181,184,187],[185]],"referencedMap":[[130,1],[156,1],[160,2],[144,3],[159,4],[142,5],[151,6],[148,7],[154,8],[150,9],[145,1],[146,1],[153,10],[147,11],[157,12],[155,13],[143,14],[152,1],[122,15],[125,16],[123,17],[128,18],[120,1],[121,15],[119,19],[124,16],[126,16],[112,20],[115,21],[116,22],[113,23],[114,21],[118,24],[117,20],[67,25],[100,26],[78,27],[62,28],[61,1],[109,29],[127,1],[110,30],[108,31],[107,32],[66,33],[80,34],[49,35],[52,36],[101,37],[58,38],[103,39],[57,40],[77,41],[63,42],[64,43],[55,1],[59,1],[65,1],[51,44],[50,45],[178,1],[177,46],[242,1],[176,1],[188,47],[189,47],[191,48],[192,49],[193,50],[194,51],[195,52],[196,53],[197,54],[198,55],[199,56],[200,57],[201,57],[203,58],[202,59],[204,58],[205,60],[206,61],[190,62],[240,1],[207,63],[208,64],[209,65],[241,66],[210,67],[211,68],[212,69],[213,70],[214,71],[215,72],[216,73],[217,74],[218,75],[219,76],[220,76],[221,77],[222,78],[224,79],[223,80],[225,81],[226,82],[227,1],[228,83],[229,84],[230,85],[231,86],[232,87],[233,88],[234,89],[235,90],[236,91],[237,92],[238,93],[239,94],[149,1],[97,95],[96,96],[82,1],[102,1],[60,1],[180,1],[132,97],[99,98],[106,99],[135,100],[134,101],[105,102],[79,103],[76,104],[136,105],[111,106],[129,107],[131,108],[133,109],[104,110],[68,111],[98,31],[81,32],[92,112],[45,1],[93,113],[46,114],[88,1],[48,115],[83,116],[91,117],[90,117],[85,118],[86,119],[44,1],[89,120],[84,121],[47,122],[87,1],[141,1],[158,5],[69,123],[72,124],[73,125],[70,126],[71,124],[75,127],[74,123],[8,1],[10,1],[9,1],[2,1],[11,1],[12,1],[13,1],[14,1],[15,1],[16,1],[17,1],[18,1],[3,1],[4,1],[22,1],[19,1],[20,1],[21,1],[23,1],[24,1],[25,1],[5,1],[26,1],[27,1],[28,1],[29,1],[6,1],[33,1],[30,1],[31,1],[32,1],[34,1],[7,1],[35,1],[40,1],[41,1],[36,1],[37,1],[38,1],[39,1],[1,1],[42,1],[56,1],[95,128],[94,129],[174,130],[164,1],[53,131],[138,132],[165,133],[139,132],[54,1],[140,134],[137,135],[161,136],[162,132],[163,137],[43,1],[182,138],[181,139],[183,140],[175,141],[187,142],[185,143],[184,142],[186,144],[173,145],[168,19],[170,19],[167,19],[172,19],[171,19],[169,19],[166,24],[179,1]],"exportedModulesMap":[[130,1],[156,1],[160,2],[144,3],[159,4],[142,5],[151,6],[148,7],[154,8],[150,9],[145,1],[146,1],[153,10],[147,11],[157,12],[155,13],[143,14],[152,1],[122,15],[125,16],[123,17],[128,18],[120,1],[121,15],[119,19],[124,16],[126,16],[112,20],[115,21],[116,22],[113,23],[114,21],[118,24],[117,20],[67,25],[100,26],[78,27],[62,28],[61,1],[109,29],[127,1],[110,30],[108,31],[107,32],[66,33],[80,34],[49,35],[52,36],[101,37],[58,38],[103,39],[57,40],[77,41],[63,42],[64,43],[55,1],[59,1],[65,1],[51,44],[50,45],[178,1],[177,46],[242,1],[176,1],[188,47],[189,47],[191,48],[192,49],[193,50],[194,51],[195,52],[196,53],[197,54],[198,55],[199,56],[200,57],[201,57],[203,58],[202,59],[204,58],[205,60],[206,61],[190,62],[240,1],[207,63],[208,64],[209,65],[241,66],[210,67],[211,68],[212,69],[213,70],[214,71],[215,72],[216,73],[217,74],[218,75],[219,76],[220,76],[221,77],[222,78],[224,79],[223,80],[225,81],[226,82],[227,1],[228,83],[229,84],[230,85],[231,86],[232,87],[233,88],[234,89],[235,90],[236,91],[237,92],[238,93],[239,94],[149,1],[97,95],[96,96],[82,1],[102,1],[60,1],[180,1],[132,97],[99,98],[106,99],[135,100],[134,101],[105,102],[79,103],[76,104],[136,105],[111,106],[129,107],[131,108],[133,109],[104,110],[68,111],[98,31],[81,32],[92,112],[45,1],[93,113],[46,114],[88,1],[48,115],[83,116],[91,117],[90,117],[85,118],[86,119],[44,1],[89,120],[84,121],[47,122],[87,1],[141,1],[158,5],[69,123],[72,124],[73,125],[70,126],[71,124],[75,127],[74,123],[8,1],[10,1],[9,1],[2,1],[11,1],[12,1],[13,1],[14,1],[15,1],[16,1],[17,1],[18,1],[3,1],[4,1],[22,1],[19,1],[20,1],[21,1],[23,1],[24,1],[25,1],[5,1],[26,1],[27,1],[28,1],[29,1],[6,1],[33,1],[30,1],[31,1],[32,1],[34,1],[7,1],[35,1],[40,1],[41,1],[36,1],[37,1],[38,1],[39,1],[1,1],[42,1],[56,1],[95,128],[94,129],[174,130],[164,1],[53,131],[138,132],[165,133],[139,132],[54,1],[140,134],[137,135],[161,136],[162,132],[163,137],[181,146],[175,147],[187,148],[185,149],[184,148],[186,150],[173,145],[168,19],[170,19],[167,19],[172,19],[171,19],[169,19],[166,24],[179,1]],"semanticDiagnosticsPerFile":[130,156,160,144,159,142,151,148,154,150,145,146,153,147,157,155,143,152,122,125,123,128,120,121,119,124,126,112,115,116,113,114,118,117,67,100,78,62,61,109,127,110,108,107,66,80,49,52,101,58,103,57,77,63,64,55,59,65,51,50,178,177,242,176,188,189,191,192,193,194,195,196,197,198,199,200,201,203,202,204,205,206,190,240,207,208,209,241,210,211,212,213,214,215,216,217,218,219,220,221,222,224,223,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,149,97,96,82,102,60,180,132,99,106,135,134,105,79,76,136,111,129,131,133,104,68,98,81,92,45,93,46,88,48,83,91,90,85,86,44,89,84,47,87,141,158,69,72,73,70,71,75,74,8,10,9,2,11,12,13,14,15,16,17,18,3,4,22,19,20,21,23,24,25,5,26,27,28,29,6,33,30,31,32,34,7,35,40,41,36,37,38,39,1,42,56,95,94,174,164,53,138,165,139,54,140,137,161,162,163,43,182,181,183,175,187,185,184,186,173,168,170,167,172,171,169,166,179]},"version":"4.9.5"}
|
package/dist/crypto/ecies.js
CHANGED
package/dist/crypto/ecies.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ecies.js","sourceRoot":"","sources":["../../src/crypto/ecies.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,kBAAkB,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,
|
1
|
+
{"version":3,"file":"ecies.js","sourceRoot":"","sources":["../../src/crypto/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E,MAAM,CAAC,CAAC,EAAE;YAC1D,MAAM,IAAI,KAAK,CAAC,eAAe,CAAC,CAAC;SAClC;QAED,OAAO,aAAa,CAAC,EAAE,EAAE,aAAa,EAAE,UAAU,CAAC,CAAC;KACrD;AACH,CAAC"}
|
package/dist/crypto/index.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import nodeCrypto from "crypto";
|
2
2
|
import * as secp from "@noble/secp256k1";
|
3
|
-
import { concat } from "@waku/
|
3
|
+
import { concat } from "@waku/utils/bytes";
|
4
4
|
import sha3 from "js-sha3";
|
5
5
|
import { Asymmetric, Symmetric } from "../constants.js";
|
6
6
|
const crypto = {
|
package/dist/crypto/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/crypto/index.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,QAAQ,CAAC;AAEhC,OAAO,KAAK,IAAI,MAAM,kBAAkB,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,MAAM,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/crypto/index.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,QAAQ,CAAC;AAEhC,OAAO,KAAK,IAAI,MAAM,kBAAkB,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAC3C,OAAO,IAAI,MAAM,SAAS,CAAC;AAE3B,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAGxD,MAAM,MAAM,GAA8B;IACxC,IAAI,EAAE,UAAU;IAChB,GAAG,EAAE,OAAO,IAAI,KAAK,QAAQ,IAAI,QAAQ,IAAI,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;CAC5E,CAAC;AAEF,MAAM,UAAU,SAAS;IACvB,IAAI,MAAM,CAAC,GAAG,EAAE;QACd,OAAO,MAAM,CAAC,G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@waku/core/lib/message/version_0";
|
2
|
+
import type { IDecodedMessage } from "@waku/interfaces";
|
3
|
+
export declare class DecodedMessage extends DecodedMessageV0 implements IDecodedMessage {
|
4
|
+
signature?: Uint8Array | undefined;
|
5
|
+
signaturePublicKey?: Uint8Array | undefined;
|
6
|
+
private readonly _decodedPayload;
|
7
|
+
constructor(pubSubTopic: string, proto: proto.WakuMessage, decodedPayload: Uint8Array, signature?: Uint8Array | undefined, signaturePublicKey?: Uint8Array | undefined);
|
8
|
+
get payload(): Uint8Array;
|
9
|
+
}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import { DecodedMessage as DecodedMessageV0, } from "@waku/core/lib/message/version_0";
|
2
|
+
export class DecodedMessage extends DecodedMessageV0 {
|
3
|
+
constructor(pubSubTopic, proto, decodedPayload, signature, signaturePublicKey) {
|
4
|
+
super(pubSubTopic, proto);
|
5
|
+
this.signature = signature;
|
6
|
+
this.signaturePublicKey = signaturePublicKey;
|
7
|
+
this._decodedPayload = decodedPayload;
|
8
|
+
}
|
9
|
+
get payload() {
|
10
|
+
return this._decodedPayload;
|
11
|
+
}
|
12
|
+
}
|
13
|
+
//# sourceMappingURL=decoded_message.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"decoded_message.js","sourceRoot":"","sources":["../src/decoded_message.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,IAAI,gBAAgB,GAEnC,MAAM,kCAAkC,CAAC;AAG1C,MAAM,OAAO,cACX,SAAQ,gBAAgB;IAKxB,YACE,WAAmB,EACnB,KAAwB,EACxB,cAA0B,EACnB,SAAsB,EACtB,kBAA+B;QAEtC,KAAK,CAAC,WAAW,EAAE,KAAK,CAAC,CAAC;QAHnB,cAAS,GAAT,SAAS,CAAa;QACtB,uBAAkB,GAAlB,kBAAkB,CAAa;QAGtC,IAAI,CAAC,eAAe,GAAG,cAAc,CAAC;IACxC,CAAC;IAED,IAAI,OAAO;QACT,OAAO,IAAI,CAAC,eAAe,CAAC;IAC9B,CAAC;CACF"}
|
package/dist/ecies.d.ts
CHANGED
@@ -1,16 +1,26 @@
|
|
1
1
|
import { Decoder as DecoderV0 } from "@waku/core/lib/message/version_0";
|
2
|
-
import
|
3
|
-
import {
|
4
|
-
|
5
|
-
|
2
|
+
import { IMetaSetter } from "@waku/interfaces";
|
3
|
+
import type { EncoderOptions as BaseEncoderOptions, IDecoder, IEncoder, IMessage, IProtoMessage } from "@waku/interfaces";
|
4
|
+
import { DecodedMessage } from "./decoded_message.js";
|
5
|
+
import { generatePrivateKey, getPublicKey } from "./index.js";
|
6
|
+
export { generatePrivateKey, getPublicKey };
|
7
|
+
export type { Encoder, Decoder, DecodedMessage };
|
8
|
+
declare class Encoder implements IEncoder {
|
6
9
|
contentTopic: string;
|
7
10
|
private publicKey;
|
8
11
|
private sigPrivKey?;
|
9
12
|
ephemeral: boolean;
|
10
|
-
|
13
|
+
metaSetter?: IMetaSetter | undefined;
|
14
|
+
constructor(contentTopic: string, publicKey: Uint8Array, sigPrivKey?: Uint8Array | undefined, ephemeral?: boolean, metaSetter?: IMetaSetter | undefined);
|
11
15
|
toWire(message: IMessage): Promise<Uint8Array | undefined>;
|
12
16
|
toProtoObj(message: IMessage): Promise<IProtoMessage | undefined>;
|
13
17
|
}
|
18
|
+
export interface EncoderOptions extends BaseEncoderOptions {
|
19
|
+
/** The public key to encrypt the payload for. */
|
20
|
+
publicKey: Uint8Array;
|
21
|
+
/** An optional private key to be used to sign the payload before encryption. */
|
22
|
+
sigPrivKey?: Uint8Array;
|
23
|
+
}
|
14
24
|
/**
|
15
25
|
* Creates an encoder that encrypts messages using ECIES for the given public,
|
16
26
|
* as defined in [26/WAKU2-PAYLOAD](https://rfc.vac.dev/spec/26/).
|
@@ -20,20 +30,14 @@ export declare class Encoder implements IEncoder {
|
|
20
30
|
* pass to { @link @waku/interfaces.LightPush.push } or
|
21
31
|
* { @link @waku/interfaces.Relay.send } to automatically encrypt
|
22
32
|
* and encode outgoing messages.
|
23
|
-
*
|
24
33
|
* The payload can optionally be signed with the given private key as defined
|
25
34
|
* in [26/WAKU2-PAYLOAD](https://rfc.vac.dev/spec/26/).
|
26
|
-
*
|
27
|
-
* @param contentTopic The content topic to set on outgoing messages.
|
28
|
-
* @param publicKey The public key to encrypt the payload for.
|
29
|
-
* @param sigPrivKey An optional private key to used to sign the payload before encryption.
|
30
|
-
* @param ephemeral An optional flag to mark message as ephemeral, ie, not to be stored by Waku Store nodes.
|
31
35
|
*/
|
32
|
-
export declare function createEncoder(contentTopic
|
33
|
-
|
36
|
+
export declare function createEncoder({ contentTopic, publicKey, sigPrivKey, ephemeral, metaSetter, }: EncoderOptions): Encoder;
|
37
|
+
declare class Decoder extends DecoderV0 implements IDecoder<DecodedMessage> {
|
34
38
|
private privateKey;
|
35
39
|
constructor(contentTopic: string, privateKey: Uint8Array);
|
36
|
-
fromProtoObj(protoMessage: IProtoMessage): Promise<DecodedMessage | undefined>;
|
40
|
+
fromProtoObj(pubSubTopic: string, protoMessage: IProtoMessage): Promise<DecodedMessage | undefined>;
|
37
41
|
}
|
38
42
|
/**
|
39
43
|
* Creates a decoder that decrypts messages using ECIES, using the given private
|
package/dist/ecies.js
CHANGED
@@ -1,16 +1,18 @@
|
|
1
1
|
import { Decoder as DecoderV0 } from "@waku/core/lib/message/version_0";
|
2
2
|
import { WakuMessage } from "@waku/proto";
|
3
3
|
import debug from "debug";
|
4
|
+
import { DecodedMessage } from "./decoded_message.js";
|
4
5
|
import { decryptAsymmetric, encryptAsymmetric, postCipher, preCipher, } from "./waku_payload.js";
|
5
|
-
import {
|
6
|
-
export {
|
6
|
+
import { generatePrivateKey, getPublicKey, OneMillion, Version, } from "./index.js";
|
7
|
+
export { generatePrivateKey, getPublicKey };
|
7
8
|
const log = debug("waku:message-encryption:ecies");
|
8
|
-
|
9
|
-
constructor(contentTopic, publicKey, sigPrivKey, ephemeral = false) {
|
9
|
+
class Encoder {
|
10
|
+
constructor(contentTopic, publicKey, sigPrivKey, ephemeral = false, metaSetter) {
|
10
11
|
this.contentTopic = contentTopic;
|
11
12
|
this.publicKey = publicKey;
|
12
13
|
this.sigPrivKey = sigPrivKey;
|
13
14
|
this.ephemeral = ephemeral;
|
15
|
+
this.metaSetter = metaSetter;
|
14
16
|
}
|
15
17
|
async toWire(message) {
|
16
18
|
const protoMessage = await this.toProtoObj(message);
|
@@ -20,20 +22,22 @@ export class Encoder {
|
|
20
22
|
}
|
21
23
|
async toProtoObj(message) {
|
22
24
|
const timestamp = message.timestamp ?? new Date();
|
23
|
-
if (!message.payload) {
|
24
|
-
log("No payload to encrypt, skipping: ", message);
|
25
|
-
return;
|
26
|
-
}
|
27
25
|
const preparedPayload = await preCipher(message.payload, this.sigPrivKey);
|
28
26
|
const payload = await encryptAsymmetric(preparedPayload, this.publicKey);
|
29
|
-
|
27
|
+
const protoMessage = {
|
30
28
|
payload,
|
31
29
|
version: Version,
|
32
30
|
contentTopic: this.contentTopic,
|
33
31
|
timestamp: BigInt(timestamp.valueOf()) * OneMillion,
|
32
|
+
meta: undefined,
|
34
33
|
rateLimitProof: message.rateLimitProof,
|
35
34
|
ephemeral: this.ephemeral,
|
36
35
|
};
|
36
|
+
if (this.metaSetter) {
|
37
|
+
const meta = this.metaSetter(protoMessage);
|
38
|
+
return { ...protoMessage, meta };
|
39
|
+
}
|
40
|
+
return protoMessage;
|
37
41
|
}
|
38
42
|
}
|
39
43
|
/**
|
@@ -45,34 +49,24 @@ export class Encoder {
|
|
45
49
|
* pass to { @link @waku/interfaces.LightPush.push } or
|
46
50
|
* { @link @waku/interfaces.Relay.send } to automatically encrypt
|
47
51
|
* and encode outgoing messages.
|
48
|
-
*
|
49
52
|
* The payload can optionally be signed with the given private key as defined
|
50
53
|
* in [26/WAKU2-PAYLOAD](https://rfc.vac.dev/spec/26/).
|
51
|
-
*
|
52
|
-
* @param contentTopic The content topic to set on outgoing messages.
|
53
|
-
* @param publicKey The public key to encrypt the payload for.
|
54
|
-
* @param sigPrivKey An optional private key to used to sign the payload before encryption.
|
55
|
-
* @param ephemeral An optional flag to mark message as ephemeral, ie, not to be stored by Waku Store nodes.
|
56
54
|
*/
|
57
|
-
export function createEncoder(contentTopic, publicKey, sigPrivKey, ephemeral = false) {
|
58
|
-
return new Encoder(contentTopic, publicKey, sigPrivKey, ephemeral);
|
55
|
+
export function createEncoder({ contentTopic, publicKey, sigPrivKey, ephemeral = false, metaSetter, }) {
|
56
|
+
return new Encoder(contentTopic, publicKey, sigPrivKey, ephemeral, metaSetter);
|
59
57
|
}
|
60
|
-
|
58
|
+
class Decoder extends DecoderV0 {
|
61
59
|
constructor(contentTopic, privateKey) {
|
62
60
|
super(contentTopic);
|
63
61
|
this.privateKey = privateKey;
|
64
62
|
}
|
65
|
-
async fromProtoObj(protoMessage) {
|
63
|
+
async fromProtoObj(pubSubTopic, protoMessage) {
|
66
64
|
const cipherPayload = protoMessage.payload;
|
67
65
|
if (protoMessage.version !== Version) {
|
68
66
|
log("Failed to decrypt due to incorrect version, expected:", Version, ", actual:", protoMessage.version);
|
69
67
|
return;
|
70
68
|
}
|
71
69
|
let payload;
|
72
|
-
if (!cipherPayload) {
|
73
|
-
log(`No payload to decrypt for contentTopic ${this.contentTopic}`);
|
74
|
-
return;
|
75
|
-
}
|
76
70
|
try {
|
77
71
|
payload = await decryptAsymmetric(cipherPayload, this.privateKey);
|
78
72
|
}
|
@@ -90,7 +84,7 @@ export class Decoder extends DecoderV0 {
|
|
90
84
|
return;
|
91
85
|
}
|
92
86
|
log("Message decrypted", protoMessage);
|
93
|
-
return new DecodedMessage(protoMessage, res.payload, res.sig?.signature, res.sig?.publicKey);
|
87
|
+
return new DecodedMessage(pubSubTopic, protoMessage, res.payload, res.sig?.signature, res.sig?.publicKey);
|
94
88
|
}
|
95
89
|
}
|
96
90
|
/**
|
package/dist/ecies.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ecies.js","sourceRoot":"","sources":["../src/ecies.ts"],"names":[],"mappings":"AAAA,OAAO,EA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;YACF,OAAO;SACR;QAED,IAAI,OAAO,CAAC;QAEZ,IAAI;YACF,OAAO,GAAG,MAAM,iBAAiB,CAAC,aAAa,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;SACnE;QAAC,OAAO,CAAC,EAAE;YACV,GAAG,CACD,2EAA2E,IAAI,CAAC,YAAY,EAAE,EAC9F,CAAC,CACF,CAAC;YACF,OAAO;SACR;QAED,IAAI,CAAC,OAAO,EAAE;YACZ,GAAG,CAAC,8CAA8C,IAAI,CAAC,YAAY,EAAE,CAAC,CAAC;YACvE,OAAO;SACR;QAED,MAAM,GAAG,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC,CAAC;QAEtC,IAAI,CAAC,GAAG,EAAE;YACR,GAAG,CAAC,6CAA6C,IAAI,CAAC,YAAY,EAAE,CAAC,CAAC;YACtE,OAAO;SACR;QAED,GAAG,CAAC,mBAAmB,EAAE,YAAY,CAAC,CAAC;QACvC,OAAO,IAAI,cAAc,CACvB,WAAW,EACX,YAAY,EACZ,GAAG,CAAC,OAAO,EACX,GAAG,CAAC,GAAG,EAAE,SAAS,EAClB,GAAG,CAAC,GAAG,EAAE,SAAS,CACnB,CAAC;IACJ,CAAC;CACF;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,aAAa,CAC3B,YAAoB,EACpB,UAAsB;IAEtB,OAAO,IAAI,OAAO,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;AAC/C,CAAC"}
|
package/dist/index.d.ts
CHANGED
@@ -1,19 +1,12 @@
|
|
1
|
-
import { DecodedMessage as DecodedMessageV0, proto } from "@waku/core/lib/message/version_0";
|
2
|
-
import type { IDecodedMessage } from "@waku/interfaces";
|
3
1
|
import { generatePrivateKey, generateSymmetricKey, getPublicKey } from "./crypto/index.js";
|
2
|
+
import { DecodedMessage } from "./decoded_message.js";
|
4
3
|
export declare const OneMillion: bigint;
|
5
4
|
export { generatePrivateKey, generateSymmetricKey, getPublicKey };
|
5
|
+
export type { DecodedMessage };
|
6
6
|
export * as ecies from "./ecies.js";
|
7
7
|
export * as symmetric from "./symmetric.js";
|
8
8
|
export declare const Version = 1;
|
9
|
-
export
|
9
|
+
export type Signature = {
|
10
10
|
signature: Uint8Array;
|
11
11
|
publicKey: Uint8Array | undefined;
|
12
12
|
};
|
13
|
-
export declare class DecodedMessage extends DecodedMessageV0 implements IDecodedMessage {
|
14
|
-
signature?: Uint8Array | undefined;
|
15
|
-
signaturePublicKey?: Uint8Array | undefined;
|
16
|
-
private readonly _decodedPayload;
|
17
|
-
constructor(proto: proto.WakuMessage, decodedPayload: Uint8Array, signature?: Uint8Array | undefined, signaturePublicKey?: Uint8Array | undefined);
|
18
|
-
get payload(): Uint8Array;
|
19
|
-
}
|
package/dist/index.js
CHANGED
@@ -1,19 +1,7 @@
|
|
1
|
-
import { DecodedMessage as DecodedMessageV0, } from "@waku/core/lib/message/version_0";
|
2
1
|
import { generatePrivateKey, generateSymmetricKey, getPublicKey, } from "./crypto/index.js";
|
3
2
|
export const OneMillion = BigInt(1000000);
|
4
3
|
export { generatePrivateKey, generateSymmetricKey, getPublicKey };
|
5
4
|
export * as ecies from "./ecies.js";
|
6
5
|
export * as symmetric from "./symmetric.js";
|
7
6
|
export const Version = 1;
|
8
|
-
export class DecodedMessage extends DecodedMessageV0 {
|
9
|
-
constructor(proto, decodedPayload, signature, signaturePublicKey) {
|
10
|
-
super(proto);
|
11
|
-
this.signature = signature;
|
12
|
-
this.signaturePublicKey = signaturePublicKey;
|
13
|
-
this._decodedPayload = decodedPayload;
|
14
|
-
}
|
15
|
-
get payload() {
|
16
|
-
return this._decodedPayload;
|
17
|
-
}
|
18
|
-
}
|
19
7
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,YAAY,GACb,MAAM,mBAAmB,CAAC;AAG3B,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,OAAS,CAAC,CAAC;AAE5C,OAAO,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,YAAY,EAAE,CAAC;AAGlE,OAAO,KAAK,KAAK,MAAM,YAAY,CAAC;AACpC,OAAO,KAAK,SAAS,MAAM,gBAAgB,CAAC;AAE5C,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,CAAC"}
|
package/dist/symmetric.d.ts
CHANGED
@@ -1,16 +1,25 @@
|
|
1
1
|
import { Decoder as DecoderV0 } from "@waku/core/lib/message/version_0";
|
2
|
-
import type { IDecoder, IEncoder, IMessage, IProtoMessage } from "@waku/interfaces";
|
3
|
-
import { DecodedMessage
|
4
|
-
|
5
|
-
export
|
2
|
+
import type { EncoderOptions as BaseEncoderOptions, IDecoder, IEncoder, IMessage, IMetaSetter, IProtoMessage } from "@waku/interfaces";
|
3
|
+
import { DecodedMessage } from "./decoded_message.js";
|
4
|
+
import { generateSymmetricKey } from "./index.js";
|
5
|
+
export { generateSymmetricKey };
|
6
|
+
export type { DecodedMessage, Encoder, Decoder };
|
7
|
+
declare class Encoder implements IEncoder {
|
6
8
|
contentTopic: string;
|
7
9
|
private symKey;
|
8
10
|
private sigPrivKey?;
|
9
11
|
ephemeral: boolean;
|
10
|
-
|
12
|
+
metaSetter?: IMetaSetter | undefined;
|
13
|
+
constructor(contentTopic: string, symKey: Uint8Array, sigPrivKey?: Uint8Array | undefined, ephemeral?: boolean, metaSetter?: IMetaSetter | undefined);
|
11
14
|
toWire(message: IMessage): Promise<Uint8Array | undefined>;
|
12
15
|
toProtoObj(message: IMessage): Promise<IProtoMessage | undefined>;
|
13
16
|
}
|
17
|
+
export interface EncoderOptions extends BaseEncoderOptions {
|
18
|
+
/** The symmetric key to encrypt the payload with. */
|
19
|
+
symKey: Uint8Array;
|
20
|
+
/** An optional private key to be used to sign the payload before encryption. */
|
21
|
+
sigPrivKey?: Uint8Array;
|
22
|
+
}
|
14
23
|
/**
|
15
24
|
* Creates an encoder that encrypts messages using symmetric encryption for the
|
16
25
|
* given key, as defined in [26/WAKU2-PAYLOAD](https://rfc.vac.dev/spec/26/).
|
@@ -23,17 +32,12 @@ export declare class Encoder implements IEncoder {
|
|
23
32
|
*
|
24
33
|
* The payload can optionally be signed with the given private key as defined
|
25
34
|
* in [26/WAKU2-PAYLOAD](https://rfc.vac.dev/spec/26/).
|
26
|
-
*
|
27
|
-
* @param contentTopic The content topic to set on outgoing messages.
|
28
|
-
* @param symKey The symmetric key to encrypt the payload with.
|
29
|
-
* @param sigPrivKey An optional private key to used to sign the payload before encryption.
|
30
|
-
* @param ephemeral An optional flag to mark message as ephemeral, ie, not to be stored by Waku Store nodes.
|
31
35
|
*/
|
32
|
-
export declare function createEncoder(contentTopic
|
33
|
-
|
36
|
+
export declare function createEncoder({ contentTopic, symKey, sigPrivKey, ephemeral, metaSetter, }: EncoderOptions): Encoder;
|
37
|
+
declare class Decoder extends DecoderV0 implements IDecoder<DecodedMessage> {
|
34
38
|
private symKey;
|
35
39
|
constructor(contentTopic: string, symKey: Uint8Array);
|
36
|
-
fromProtoObj(protoMessage: IProtoMessage): Promise<DecodedMessage | undefined>;
|
40
|
+
fromProtoObj(pubSubTopic: string, protoMessage: IProtoMessage): Promise<DecodedMessage | undefined>;
|
37
41
|
}
|
38
42
|
/**
|
39
43
|
* Creates a decoder that decrypts messages using symmetric encryption, using
|
package/dist/symmetric.js
CHANGED
@@ -1,16 +1,18 @@
|
|
1
1
|
import { Decoder as DecoderV0 } from "@waku/core/lib/message/version_0";
|
2
2
|
import { WakuMessage } from "@waku/proto";
|
3
3
|
import debug from "debug";
|
4
|
+
import { DecodedMessage } from "./decoded_message.js";
|
4
5
|
import { decryptSymmetric, encryptSymmetric, postCipher, preCipher, } from "./waku_payload.js";
|
5
|
-
import {
|
6
|
-
export {
|
6
|
+
import { generateSymmetricKey, OneMillion, Version } from "./index.js";
|
7
|
+
export { generateSymmetricKey };
|
7
8
|
const log = debug("waku:message-encryption:symmetric");
|
8
|
-
|
9
|
-
constructor(contentTopic, symKey, sigPrivKey, ephemeral = false) {
|
9
|
+
class Encoder {
|
10
|
+
constructor(contentTopic, symKey, sigPrivKey, ephemeral = false, metaSetter) {
|
10
11
|
this.contentTopic = contentTopic;
|
11
12
|
this.symKey = symKey;
|
12
13
|
this.sigPrivKey = sigPrivKey;
|
13
14
|
this.ephemeral = ephemeral;
|
15
|
+
this.metaSetter = metaSetter;
|
14
16
|
}
|
15
17
|
async toWire(message) {
|
16
18
|
const protoMessage = await this.toProtoObj(message);
|
@@ -20,20 +22,22 @@ export class Encoder {
|
|
20
22
|
}
|
21
23
|
async toProtoObj(message) {
|
22
24
|
const timestamp = message.timestamp ?? new Date();
|
23
|
-
if (!message.payload) {
|
24
|
-
log("No payload to encrypt, skipping: ", message);
|
25
|
-
return;
|
26
|
-
}
|
27
25
|
const preparedPayload = await preCipher(message.payload, this.sigPrivKey);
|
28
26
|
const payload = await encryptSymmetric(preparedPayload, this.symKey);
|
29
|
-
|
27
|
+
const protoMessage = {
|
30
28
|
payload,
|
31
29
|
version: Version,
|
32
30
|
contentTopic: this.contentTopic,
|
33
31
|
timestamp: BigInt(timestamp.valueOf()) * OneMillion,
|
32
|
+
meta: undefined,
|
34
33
|
rateLimitProof: message.rateLimitProof,
|
35
34
|
ephemeral: this.ephemeral,
|
36
35
|
};
|
36
|
+
if (this.metaSetter) {
|
37
|
+
const meta = this.metaSetter(protoMessage);
|
38
|
+
return { ...protoMessage, meta };
|
39
|
+
}
|
40
|
+
return protoMessage;
|
37
41
|
}
|
38
42
|
}
|
39
43
|
/**
|
@@ -48,31 +52,22 @@ export class Encoder {
|
|
48
52
|
*
|
49
53
|
* The payload can optionally be signed with the given private key as defined
|
50
54
|
* in [26/WAKU2-PAYLOAD](https://rfc.vac.dev/spec/26/).
|
51
|
-
*
|
52
|
-
* @param contentTopic The content topic to set on outgoing messages.
|
53
|
-
* @param symKey The symmetric key to encrypt the payload with.
|
54
|
-
* @param sigPrivKey An optional private key to used to sign the payload before encryption.
|
55
|
-
* @param ephemeral An optional flag to mark message as ephemeral, ie, not to be stored by Waku Store nodes.
|
56
55
|
*/
|
57
|
-
export function createEncoder(contentTopic, symKey, sigPrivKey, ephemeral = false) {
|
58
|
-
return new Encoder(contentTopic, symKey, sigPrivKey, ephemeral);
|
56
|
+
export function createEncoder({ contentTopic, symKey, sigPrivKey, ephemeral = false, metaSetter, }) {
|
57
|
+
return new Encoder(contentTopic, symKey, sigPrivKey, ephemeral, metaSetter);
|
59
58
|
}
|
60
|
-
|
59
|
+
class Decoder extends DecoderV0 {
|
61
60
|
constructor(contentTopic, symKey) {
|
62
61
|
super(contentTopic);
|
63
62
|
this.symKey = symKey;
|
64
63
|
}
|
65
|
-
async fromProtoObj(protoMessage) {
|
64
|
+
async fromProtoObj(pubSubTopic, protoMessage) {
|
66
65
|
const cipherPayload = protoMessage.payload;
|
67
66
|
if (protoMessage.version !== Version) {
|
68
67
|
log("Failed to decrypt due to incorrect version, expected:", Version, ", actual:", protoMessage.version);
|
69
68
|
return;
|
70
69
|
}
|
71
70
|
let payload;
|
72
|
-
if (!cipherPayload) {
|
73
|
-
log(`No payload to decrypt for contentTopic ${this.contentTopic}`);
|
74
|
-
return;
|
75
|
-
}
|
76
71
|
try {
|
77
72
|
payload = await decryptSymmetric(cipherPayload, this.symKey);
|
78
73
|
}
|
@@ -90,7 +85,7 @@ export class Decoder extends DecoderV0 {
|
|
90
85
|
return;
|
91
86
|
}
|
92
87
|
log("Message decrypted", protoMessage);
|
93
|
-
return new DecodedMessage(protoMessage, res.payload, res.sig?.signature, res.sig?.publicKey);
|
88
|
+
return new DecodedMessage(pubSubTopic, protoMessage, res.payload, res.sig?.signature, res.sig?.publicKey);
|
94
89
|
}
|
95
90
|
}
|
96
91
|
/**
|