diff --git a/@types/frame/index.d.ts b/@types/frame/index.d.ts index b27f8d938..5145e48af 100644 --- a/@types/frame/index.d.ts +++ b/@types/frame/index.d.ts @@ -7,3 +7,4 @@ type NullableTimeout = NodeJS.Timeout | null type Callback = (err: Error | null, result?: T) => void +type ErrorOnlyCallback = Callback diff --git a/@types/frame/state.d.ts b/@types/frame/state.d.ts index 67f18dcb6..abc05f421 100644 --- a/@types/frame/state.d.ts +++ b/@types/frame/state.d.ts @@ -26,7 +26,10 @@ interface Frame { views: Record } -type SignerType = 'ring' | 'seed' | 'trezor' | 'ledger' | 'lattice' +type HotSignerType = 'ring' | 'seed' +type HardwareSignerType = 'trezor' | 'ledger' | 'lattice' +type SignerType = HotSignerType | HardwareSignerType + type AccountStatus = 'ok' interface Signer { diff --git a/main/crypt/index.js b/main/crypt/index.ts similarity index 54% rename from main/crypt/index.js rename to main/crypt/index.ts index 3fe5b4b59..d1ce84496 100644 --- a/main/crypt/index.js +++ b/main/crypt/index.ts @@ -1,8 +1,6 @@ -const crypto = require('crypto') +import crypto from 'crypto' -const stringToKey = (pass) => { +export function stringToKey(pass: string) { const hash = crypto.createHash('sha256').update(pass) return Buffer.from(hash.digest('hex').substring(0, 32)) } - -module.exports = { stringToKey } diff --git a/main/crypt/typedDataUtils.js b/main/crypt/typedDataUtils.js deleted file mode 100644 index 12b2deedf..000000000 --- a/main/crypt/typedDataUtils.js +++ /dev/null @@ -1,112 +0,0 @@ -// Translated to JavaScript from https://github.com/dicether/eip712/blob/master/src/eip712.ts -const abi = require('ethereumjs-abi') -const ethUtil = require('@ethereumjs/util') - -const PRIMITIVE_TYPES = [ - /^bytes[0-9]|[0-2][0-9]|3[0-2]$/, - /^(?:uint)8|16|32|64|128|256$/, - /^(?:int)8|16|32|64|128|256$/, - /^address$/, - /^bool$/, - /^bytes$/, - /^string$/ -] - -function isPrimitiveType(type) { - return PRIMITIVE_TYPES.some((regex) => regex.test(type)) -} - -// Recursively finds all the dependencies of a type -function dependencies(primaryType, types, found = []) { - if (found.includes(primaryType)) { - return found - } - if (types[primaryType] === undefined) { - if (!isPrimitiveType(primaryType)) { - throw Error(`${primaryType} is not a primitive type!`) - } - return found - } - found.push(primaryType) - for (const field of types[primaryType]) { - for (const dep of dependencies(field.type, types, found)) { - if (!found.includes(dep)) { - found.push(dep) - } - } - } - return found -} - -function encodeType(primaryType, types) { - // Get dependencies primary first, then alphabetical - let deps = dependencies(primaryType, types) - deps = deps.filter((t) => t !== primaryType) - deps = [primaryType].concat(deps.sort()) - - // Format as a string with fields - let result = '' - for (const depType of deps) { - result += `${depType}(${types[depType].map(({ name, type }) => `${type} ${name}`).join(',')})` - } - - return Buffer.from(result) -} - -function typeHash(primaryType, types) { - return ethUtil.keccak256(encodeType(primaryType, types)) -} - -function encodeData(primaryType, types, data) { - const encTypes = [] - const encValues = [] - - // Add typehash - encTypes.push('bytes32') - encValues.push(typeHash(primaryType, types)) - - // Add field contents - for (const field of types[primaryType]) { - const value = data[field.name] - if (value === undefined) { - throw Error(`Invalid typed data! Data for ${field.name} not found!`) - } - - if (field.type === 'string' || field.type === 'bytes') { - encTypes.push('bytes32') - const valueHash = ethUtil.keccak256(Buffer.from(value)) - encValues.push(valueHash) - } else if (types[field.type] !== undefined) { - encTypes.push('bytes32') - const valueHash = ethUtil.keccak256(encodeData(field.type, types, value)) - encValues.push(valueHash) - } else if (field.type.lastIndexOf(']') === field.type.length - 1) { - throw new Error('Arrays currently not implemented!') - } else { - if (!isPrimitiveType(field.type)) { - throw Error(`Invalid primitive type ${field.type}`) - } - - encTypes.push(field.type) - encValues.push(value) - } - } - - return abi.rawEncode(encTypes, encValues) -} - -function structHash(primaryType, types, data) { - return ethUtil.keccak256(encodeData(primaryType, types, data)) -} - -function hashTypedData(typedData) { - return ethUtil.keccak256( - Buffer.concat([ - Buffer.from('1901', 'hex'), - structHash('EIP712Domain', typedData.types, typedData.domain), - structHash(typedData.primaryType, typedData.types, typedData.message) - ]) - ) -} - -module.exports = { hashTypedData } diff --git a/main/signers/Signer/index.ts b/main/signers/Signer/index.ts index 11a20527f..d28eea7b0 100644 --- a/main/signers/Signer/index.ts +++ b/main/signers/Signer/index.ts @@ -3,7 +3,6 @@ import EventEmitter from 'stream' import { addHexPrefix } from '@ethereumjs/util' import { deriveHDAccounts } from './derive' -import crypt from '../../crypt' import { TransactionData } from '../../../resources/domain/transaction' import { getSignerDisplayType } from '../../../resources/domain/signer' import type { TypedMessage } from '../../accounts/types' @@ -45,11 +44,6 @@ export default class Signer extends EventEmitter { deriveHDAccounts(publicKey, chainCode, cb) } - fingerprint() { - if (this.addresses && this.addresses.length) - return crypt.stringToKey(this.addresses.join()).toString('hex') - } - getCoinbase(cb: Callback) { cb(null, this.addresses[0].toString()) } diff --git a/main/signers/hot/HotSigner/index.js b/main/signers/hot/HotSigner/index.js deleted file mode 100644 index e453e4501..000000000 --- a/main/signers/hot/HotSigner/index.js +++ /dev/null @@ -1,183 +0,0 @@ -const path = require('path') -const fs = require('fs') -const { ensureDirSync, removeSync } = require('fs-extra') -const { fork } = require('child_process') -const { app } = require('electron') -const log = require('electron-log') -const { v4: uuid } = require('uuid') - -const Signer = require('../../Signer').default -const store = require('../../../store').default -// Mock windows module during tests -const windows = app ? require('../../../windows') : { broadcast: () => {} } -// Mock user data dir during tests -const USER_DATA = app - ? app.getPath('userData') - : path.resolve(path.dirname(require.main.filename), '../.userData') -const SIGNERS_PATH = path.resolve(USER_DATA, 'signers') - -class HotSigner extends Signer { - constructor(signer, workerPath) { - super() - this.status = 'locked' - this.addresses = signer ? signer.addresses : [] - this._worker = fork(workerPath) - this._getToken() - this.ready = false - } - - save(data) { - // Construct signer - const { id, addresses, type, network } = this - const signer = { id, addresses, type, network, ...data } - - // Ensure signers directory exists - ensureDirSync(SIGNERS_PATH) - - // Write signer to disk - fs.writeFileSync(path.resolve(SIGNERS_PATH, `${id}.json`), JSON.stringify(signer), { mode: 0o600 }) - - // Log - log.debug('Signer saved to disk') - } - - delete() { - const signerPath = path.resolve(SIGNERS_PATH, `${this.id}.json`) - - // Overwrite file - fs.writeFileSync(signerPath, '00000000000000000000000000000000000000000000000000000000000000000000', { - mode: 0o600 - }) - - // Remove file - removeSync(signerPath) - - // Log - log.info('Signer erased from disk') - } - - lock(cb) { - this._callWorker({ method: 'lock' }, () => { - this.status = 'locked' - this.update() - log.info('Signer locked') - cb(null) - }) - } - - unlock(password, data, cb) { - const params = { password, ...data } - this._callWorker({ method: 'unlock', params }, (err, result) => { - if (err) return cb(err) - this.status = 'ok' - this.update() - log.info('Signer unlocked') - cb(null) - }) - } - - close() { - if (this.ready) this._worker.disconnect() - else this.once('ready', () => this._worker.disconnect()) - store.removeSigner(this.id) - log.info('Signer closed') - } - - update() { - // Get derived ID - const derivedId = this.fingerprint() - - // On new ID -> - if (!this.id) { - // Update id - this.id = derivedId - // Write to disk - this.save({ encryptedKeys: this.encryptedKeys, encryptedSeed: this.encryptedSeed }) - } else if (this.id !== derivedId) { - // On changed ID - // Erase from disk - this.delete(this.id) - // Remove from store - store.removeSigner(this.id) - // Update id - this.id = derivedId - // Write to disk - this.save({ encryptedKeys: this.encryptedKeys, encryptedSeed: this.encryptedSeed }) - } - - store.updateSigner(this.summary()) - log.info('Signer updated') - } - - signMessage(index, message, cb) { - const payload = { method: 'signMessage', params: { index, message } } - this._callWorker(payload, cb) - } - - signTypedData(index, typedMessage, cb) { - const payload = { method: 'signTypedData', params: { index, typedMessage } } - this._callWorker(payload, cb) - } - - signTransaction(index, rawTx, cb) { - const payload = { method: 'signTransaction', params: { index, rawTx } } - this._callWorker(payload, cb) - } - - verifyAddress(index, address, display, cb = () => {}) { - const payload = { method: 'verifyAddress', params: { index, address } } - this._callWorker(payload, (err, verified) => { - if (err || !verified) { - if (!err) { - store.notify('hotSignerMismatch') - err = new Error('Unable to verify address') - } - this.lock(() => { - if (err) { - log.error('HotSigner verifyAddress: Unable to verify address') - } else { - log.error('HotSigner verifyAddress: Address mismatch') - } - log.error(err) - }) - cb(err) - } else { - log.info('Hot signer verify address matched') - cb(null, verified) - } - }) - } - - _getToken() { - const listener = ({ type, token }) => { - if (type === 'token') { - this._token = token - this._worker.removeListener('message', listener) - this.ready = true - this.emit('ready') - } - } - this._worker.addListener('message', listener) - } - - _callWorker(payload, cb) { - if (!this._worker) throw Error('Worker not running') - // If token not yet received -> retry in 100 ms - if (!this._token) return setTimeout(() => this._callWorker(payload, cb), 100) - // Generate message id - const id = uuid() - // Handle response - const listener = (response) => { - if (response.type === 'rpc' && response.id === id) { - const error = response.error ? new Error(response.error) : null - cb(error, response.result) - this._worker.removeListener('message', listener) - } - } - this._worker.addListener('message', listener) - // Make RPC call - this._worker.send({ id, token: this._token, ...payload }) - } -} - -module.exports = HotSigner diff --git a/main/signers/hot/HotSigner/index.ts b/main/signers/hot/HotSigner/index.ts new file mode 100644 index 000000000..46819ddaa --- /dev/null +++ b/main/signers/hot/HotSigner/index.ts @@ -0,0 +1,248 @@ +import path from 'path' +import fs from 'fs' +import log from 'electron-log' +import { app } from 'electron' +import { ChildProcess, fork } from 'child_process' +import { ensureDirSync, removeSync } from 'fs-extra' +import { v4 as uuid } from 'uuid' + +import { stringToKey } from '../../../crypt' +import Signer from '../../Signer' +import store from '../../../store' + +import type { TransactionData } from '../../../../resources/domain/transaction' +import type { TypedMessage } from '../../../accounts/types' +import type { + RPCMessage, + RPCMethod, + SignMessageParams, + SignTypedDataParams, + TransactionParams, + VerifyAddressParams, + WorkerMessage, + WorkerRPCMessage, + WorkerTokenMessage +} from './types' + +// TODO: remove these when updating tests +const windows = app ? require('../../../windows') : { broadcast: () => {} } +// Mock user data dir during tests +const USER_DATA = app + ? app.getPath('userData') + : // @ts-ignore + path.resolve(path.dirname(require.main.filename), '../.userData') + +const SIGNERS_PATH = path.resolve(USER_DATA, 'signers') +const WORKER_PATH = path.resolve(__dirname, 'worker/launch.js') + +type RPCMessagePayload = { + method: RPCMethod + params?: any +} + +export default class HotSigner extends Signer { + private ready = false + private token = '' + + private readonly worker: ChildProcess + + constructor(type: HotSignerType) { + super() + + this.type = type + this.status = 'locked' + + this.worker = fork(WORKER_PATH, [type]) + + // TODO: add when worker is mocked in tests + // this.worker.on('exit', (code) => { + // log.error('Hot signer worker exited with code:', code) + // }) + + this.getToken() + } + + protected save(data?: any) { + // Construct signer + const { id, addresses, type } = this + const signer = { id, addresses, type, ...data } + + // Ensure signers directory exists + ensureDirSync(SIGNERS_PATH) + + // Write signer to disk + fs.writeFileSync(path.resolve(SIGNERS_PATH, `${id}.json`), JSON.stringify(signer), { mode: 0o600 }) + + // Log + log.debug('Signer saved to disk') + } + + delete() { + const signerPath = path.resolve(SIGNERS_PATH, `${this.id}.json`) + + // Overwrite file + fs.writeFileSync(signerPath, '00000000000000000000000000000000000000000000000000000000000000000000', { + mode: 0o600 + }) + + // Remove file + removeSync(signerPath) + + // Log + log.info('Signer erased from disk') + } + + lock(cb: ErrorOnlyCallback) { + this.callWorker({ method: 'lock' }, () => { + this.status = 'locked' + this.update() + log.info('Signer locked') + cb(null) + }) + } + + unlock(password: string, cb: ErrorOnlyCallback) { + this.unlockWorker(password, {}, cb) + } + + protected unlockWorker(password: string, data: any, cb: ErrorOnlyCallback) { + const params = { password, ...data } + + this.callWorker({ method: 'unlock', params }, (err, result) => { + if (err) return cb(err) + this.status = 'ok' + this.update() + log.info('Signer unlocked') + cb(null) + }) + } + + close() { + if (this.ready) this.worker.disconnect() + else this.once('ready', () => this.worker.disconnect()) + store.removeSigner(this.id) + log.info('Signer closed') + } + + update() { + // Get derived ID + const derivedId = this.fingerprint() + + // On new ID -> + if (!this.id) { + // Update id + this.id = derivedId + // Write to disk + this.save() + } else if (this.id !== derivedId) { + // On changed ID + // Erase from disk + this.delete() + // Remove from store + store.removeSigner(this.id) + // Update id + this.id = derivedId + // Write to disk + this.save() + } + + store.updateSigner(this.summary()) + log.info('Signer updated') + } + + signMessage(index: number, message: string, cb: Callback) { + const params: SignMessageParams = { index, message } + const payload = { method: 'signMessage', params } as const + + this.callWorker(payload, cb as Callback) + } + + signTypedData(index: number, typedMessage: TypedMessage, cb: Callback) { + const params: SignTypedDataParams = { index, message: typedMessage } + const payload = { method: 'signTypedData', params } as const + + this.callWorker(payload, cb as Callback) + } + + signTransaction(index: number, rawTx: TransactionData, cb: Callback) { + const params: TransactionParams = { index, rawTx } + const payload = { method: 'signTransaction', params } as const + this.callWorker(payload, cb as Callback) + } + + verifyAddress(index: number, address: string, display: boolean, cb: Callback) { + const params: VerifyAddressParams = { index, address } + const payload = { method: 'verifyAddress', params } as const + + this.callWorker(payload, (err, isVerified) => { + const verified = isVerified as boolean + + if (err || !verified) { + if (!err) { + store.notify('hotSignerMismatch') + err = new Error('Unable to verify address') + } + this.lock(() => { + if (err) { + log.error('HotSigner verifyAddress: Unable to verify address') + } else { + log.error('HotSigner verifyAddress: Address mismatch') + } + log.error(err) + }) + cb(err) + } else { + log.info('Hot signer verify address matched') + cb(null, verified) + } + }) + } + + private fingerprint() { + if (this.addresses && this.addresses.length) { + return stringToKey(this.addresses.join()).toString('hex') + } + + return '' + } + + private getToken() { + const listener = (message: WorkerMessage) => { + if (message.type === 'token') { + this.token = (message as WorkerTokenMessage).token + this.worker.removeListener('message', listener) + this.ready = true + this.emit('ready') + } + } + + this.worker.addListener('message', listener) + } + + protected callWorker(payload: RPCMessagePayload, cb: Callback): void { + if (!this.worker) throw Error('Worker not running') + // If token not yet received -> retry in 100 ms + if (!this.token) return void setTimeout(() => this.callWorker(payload, cb), 100) + // Generate message id + const id = uuid() + // Handle response + const listener = (message: WorkerMessage) => { + if (message.type === 'rpc') { + const rpcMessage = message as WorkerRPCMessage + + if (rpcMessage.id === id) { + const error = rpcMessage.error ? new Error(rpcMessage.error) : null + cb(error, rpcMessage.result) + this.worker.removeListener('message', listener) + } + } + } + + this.worker.addListener('message', listener) + + // Make RPC call + const { method, params } = payload + const message: RPCMessage = { id, token: this.token, method, params } + this.worker.send(message) + } +} diff --git a/main/signers/hot/HotSigner/types.ts b/main/signers/hot/HotSigner/types.ts new file mode 100644 index 000000000..47fe6af3d --- /dev/null +++ b/main/signers/hot/HotSigner/types.ts @@ -0,0 +1,79 @@ +import type { TransactionData } from '../../../../resources/domain/transaction' +import type { TypedMessage } from '../../../accounts/types' + +export interface HotSignerMessageHandler { + handleMessage: (cb: PseudoCallback, method: WorkerMethod, params: any) => void +} + +export type PseudoCallback = (errorMessage: string | null, result?: T) => void + +export type UnlockParams = { + encryptedSecret: string + password: string +} + +export type SignMessageParams = { + index: number + message: string +} + +export type SignTypedDataParams = { + index: number + message: TypedMessage +} + +export type TransactionParams = { + index: number + rawTx: TransactionData +} + +export type VerifyAddressParams = { + index: number + address: Address +} + +export type EncryptSeedParams = { + seed: string + password: string +} + +export type AddKeyParams = { + key: string + encryptedKeys: string + password: string +} + +export type RemoveKeyParams = { + index: number + encryptedKeys: string + password: string +} + +export type CoreWorkerMethod = 'lock' | 'unlock' | 'signMessage' | 'signTypedData' | 'signTransaction' +export type SeedSignerMethod = 'encryptSeed' +export type RingSignerMethod = 'addKey' | 'removeKey' +export type WorkerMethod = CoreWorkerMethod | SeedSignerMethod | RingSignerMethod +export type RPCMethod = WorkerMethod | 'verifyAddress' + +export type RPCMessage = { + id: string + method: RPCMethod + params: any + token: string +} + +type WorkerMessageType = 'rpc' | 'token' + +export type WorkerMessage = { + type: WorkerMessageType +} + +export type WorkerTokenMessage = WorkerMessage & { + token: string +} + +export type WorkerRPCMessage = WorkerMessage & { + id: string + error?: string + result?: unknown +} diff --git a/main/signers/hot/HotSigner/worker.js b/main/signers/hot/HotSigner/worker.js deleted file mode 100644 index 5c4aa8299..000000000 --- a/main/signers/hot/HotSigner/worker.js +++ /dev/null @@ -1,134 +0,0 @@ -const crypto = require('crypto') -const { signTypedData } = require('@metamask/eth-sig-util') -const { TransactionFactory } = require('@ethereumjs/tx') -const { Common } = require('@ethereumjs/common') -const { - hashPersonalMessage, - toBuffer, - ecsign, - addHexPrefix, - pubToAddress, - ecrecover -} = require('@ethereumjs/util') - -function chainConfig(chain, hardfork) { - const chainId = BigInt(chain) - - return Common.isSupportedChainId(chainId) - ? new Common({ chain: chainId, hardfork }) - : Common.custom({ chainId: chainId }, { baseChain: 'mainnet', hardfork }) -} - -class HotSignerWorker { - constructor() { - this.token = crypto.randomBytes(32).toString('hex') - process.send({ type: 'token', token: this.token }) - } - - handleMessage({ id, method, params, token }) { - // Define (pseudo) callback - const pseudoCallback = (error, result) => { - // Add correlation id to response - const response = { id, error, result, type: 'rpc' } - // Send response to parent process - process.send(response) - } - // Verify token - if (!crypto.timingSafeEqual(Buffer.from(token), Buffer.from(this.token))) - return pseudoCallback('Invalid token') - // If method exists -> execute - if (this[method]) return this[method](params, pseudoCallback) - // Else return error - pseudoCallback(`Invalid method: '${method}'`) - } - - signMessage(key, message, pseudoCallback) { - // Hash message - const hash = hashPersonalMessage(toBuffer(message)) - - // Sign message - const signed = ecsign(hash, key) - - // Return serialized signed message - const hex = Buffer.concat([signed.r, signed.s, Buffer.from([Number(signed.v)])]).toString('hex') - - pseudoCallback(null, addHexPrefix(hex)) - } - - signTypedData(key, typedMessage, pseudoCallback) { - try { - const { data, version } = typedMessage - const signature = signTypedData({ privateKey: key, data, version }) - pseudoCallback(null, signature) - } catch (e) { - pseudoCallback(e.message) - } - } - - signTransaction(key, rawTx, pseudoCallback) { - if (!rawTx.chainId) { - console.error(`invalid chain id ${rawTx.chainId} for transaction`) - return pseudoCallback('could not determine chain id for transaction') - } - - const chainId = parseInt(rawTx.chainId, 16) - const hardfork = parseInt(rawTx.type) === 2 ? 'london' : 'berlin' - const common = chainConfig(chainId, hardfork) - - const tx = TransactionFactory.fromTxData(rawTx, { common }) - const signedTx = tx.sign(key) - const serialized = signedTx.serialize().toString('hex') - - pseudoCallback(null, addHexPrefix(serialized)) - } - - verifyAddress({ index, address }, pseudoCallback) { - const message = '0x' + crypto.randomBytes(32).toString('hex') - this.signMessage({ index, message }, (err, signedMessage) => { - // Handle signing errors - if (err) return pseudoCallback(err) - // Signature -> buffer - const signature = Buffer.from(signedMessage.replace('0x', ''), 'hex') - // Ensure correct length - if (signature.length !== 65) - return pseudoCallback(new Error('Frame verifyAddress signature has incorrect length')) - // Verify address - let v = signature[64] - v = BigInt(v === 0 || v === 1 ? v + 27 : v) - const r = toBuffer(signature.slice(0, 32)) - const s = toBuffer(signature.slice(32, 64)) - const hash = hashPersonalMessage(toBuffer(message)) - const verifiedAddress = '0x' + pubToAddress(ecrecover(hash, v, r, s)).toString('hex') - // Return result - pseudoCallback(null, verifiedAddress.toLowerCase() === address.toLowerCase()) - }) - } - - _encrypt(string, password) { - const salt = crypto.randomBytes(16) - const iv = crypto.randomBytes(16) - const cipher = crypto.createCipheriv('aes-256-cbc', this._hashPassword(password, salt), iv) - const encrypted = Buffer.concat([cipher.update(string), cipher.final()]) - return salt.toString('hex') + ':' + iv.toString('hex') + ':' + encrypted.toString('hex') - } - - _decrypt(string, password) { - const parts = string.split(':') - const salt = Buffer.from(parts.shift(), 'hex') - const iv = Buffer.from(parts.shift(), 'hex') - const decipher = crypto.createDecipheriv('aes-256-cbc', this._hashPassword(password, salt), iv) - const encryptedString = Buffer.from(parts.join(':'), 'hex') - const decrypted = Buffer.concat([decipher.update(encryptedString), decipher.final()]) - return decrypted.toString() - } - - _hashPassword(password, salt) { - try { - return crypto.scryptSync(password, salt, 32, { N: 32768, r: 8, p: 1, maxmem: 36000000 }) - } catch (e) { - console.error('Error during hashPassword', e) // TODO: Handle Error - } - } -} - -module.exports = HotSignerWorker diff --git a/main/signers/hot/HotSigner/worker/controller.ts b/main/signers/hot/HotSigner/worker/controller.ts new file mode 100644 index 000000000..9025322a7 --- /dev/null +++ b/main/signers/hot/HotSigner/worker/controller.ts @@ -0,0 +1,70 @@ +import crypto from 'crypto' + +import { verifySignedMessage } from '.' + +import type { + HotSignerMessageHandler, + PseudoCallback, + RPCMessage, + RPCMethod, + VerifyAddressParams, + WorkerRPCMessage, + WorkerTokenMessage +} from '../types' + +interface IPC { + send: (message: WorkerTokenMessage | WorkerRPCMessage) => void + on: (msgType: 'message', handler: (message: RPCMessage) => void) => void +} + +function processMessage(method: RPCMethod, params: any, cb: PseudoCallback) { + if (method === 'verifyAddress') { + const { index, address } = params as VerifyAddressParams + const message = '0x' + crypto.randomBytes(32).toString('hex') + + const callback: PseudoCallback = (err, msg) => { + // Handle signing errors + if (err) return cb(err) + + const signedMessage = msg as string + const signature = Buffer.from(signedMessage.replace('0x', ''), 'hex') + if (signature.length !== 65) return cb('Frame verifyAddress signature has incorrect length') + + const verified = verifySignedMessage(address, message, signature) + + cb(null, verified) + } + + return { method: 'signMessage', params: { index, message }, callback } as const + } + + return { method, params, callback: cb } as const +} + +export default function (worker: HotSignerMessageHandler, ipc: IPC) { + const workerToken = crypto.randomBytes(32).toString('hex') + + const isTokenValid = (token: string) => crypto.timingSafeEqual(Buffer.from(token), Buffer.from(workerToken)) + + const handleMessage = ({ id, method: rpcMethod, params: rpcParams, token }: RPCMessage) => { + const pseudoCallback: PseudoCallback = (error, result) => { + // Add correlation id to response + const response = { id, error: error || undefined, result, type: 'rpc' } as const + + // Send response to parent process + ipc.send(response) + } + + // Verify token + if (!isTokenValid(token)) { + return pseudoCallback('Invalid token') + } + + const { method, params, callback } = processMessage(rpcMethod, rpcParams, pseudoCallback) + + worker.handleMessage(callback, method, params) + } + + ipc.on('message', handleMessage) + ipc.send({ type: 'token', token: workerToken }) +} diff --git a/main/signers/hot/HotSigner/worker/index.ts b/main/signers/hot/HotSigner/worker/index.ts new file mode 100644 index 000000000..41f92eb6e --- /dev/null +++ b/main/signers/hot/HotSigner/worker/index.ts @@ -0,0 +1,110 @@ +import crypto from 'crypto' +import { signTypedData as signEthTypedData } from '@metamask/eth-sig-util' +import { TransactionFactory } from '@ethereumjs/tx' +import { Common } from '@ethereumjs/common' +import { + hashPersonalMessage, + toBuffer, + ecsign, + addHexPrefix, + pubToAddress, + ecrecover +} from '@ethereumjs/util' + +import type { TypedMessage } from '../../../../accounts/types' +import type { TransactionData } from '../../../../../resources/domain/transaction' +import type { PseudoCallback } from '../types' + +function chainConfig(chain: number, hardfork: string) { + const chainId = BigInt(chain) + + return Common.isSupportedChainId(chainId) + ? new Common({ chain: chainId, hardfork }) + : Common.custom({ chainId: chainId }, { baseChain: 'mainnet', hardfork }) +} + +export function isHotSignerMethod(method: string) { + return ['lock', 'unlock', 'signMessage', 'signTypedData', 'signTransaction'].includes(method) +} + +export function signMessage(key: Buffer, message: string, cb: PseudoCallback) { + // Hash message + const hash = hashPersonalMessage(toBuffer(message)) + + // Sign message + const signed = ecsign(hash, key) + + // Return serialized signed message + const hex = Buffer.concat([signed.r, signed.s, Buffer.from([Number(signed.v)])]).toString('hex') + + cb(null, addHexPrefix(hex)) +} + +export function signTypedData( + key: Buffer, + typedMessage: TypedMessage, + pseudoCallback: PseudoCallback +) { + try { + const { data, version } = typedMessage + const signature = signEthTypedData({ privateKey: key, data, version }) + pseudoCallback(null, signature) + } catch (e) { + pseudoCallback((e as Error).message) + } +} + +export function signTransaction(key: Buffer, rawTx: TransactionData, pseudoCallback: PseudoCallback) { + if (!rawTx.chainId) { + console.error(`invalid chain id ${rawTx.chainId} for transaction`) + return pseudoCallback('could not determine chain id for transaction') + } + + const chainId = parseInt(rawTx.chainId, 16) + const hardfork = parseInt(rawTx.type) === 2 ? 'london' : 'berlin' + const common = chainConfig(chainId, hardfork) + + const tx = TransactionFactory.fromTxData(rawTx, { common }) + const signedTx = tx.sign(key) + const serialized = signedTx.serialize().toString('hex') + + pseudoCallback(null, addHexPrefix(serialized)) +} + +export function verifySignedMessage(address: Address, message: string, signature: Buffer) { + const vNum = signature[64] + + const v = BigInt(vNum === 0 || vNum === 1 ? vNum + 27 : vNum) + const r = toBuffer(signature.slice(0, 32)) + const s = toBuffer(signature.slice(32, 64)) + const hash = hashPersonalMessage(toBuffer(message)) + const verifiedAddress = '0x' + pubToAddress(ecrecover(hash, v, r, s)).toString('hex') + + return verifiedAddress.toLowerCase() === address.toLowerCase() +} + +export function encrypt(s: string, password: string) { + const salt = crypto.randomBytes(16) + const iv = crypto.randomBytes(16) + const cipher = crypto.createCipheriv('aes-256-cbc', hashPassword(password, salt) as Buffer, iv) + const encrypted = Buffer.concat([cipher.update(s), cipher.final()]) + return salt.toString('hex') + ':' + iv.toString('hex') + ':' + encrypted.toString('hex') +} + +export function decrypt(s: string, password: string) { + const parts = s.split(':') + const salt = Buffer.from(parts.shift() as string, 'hex') + const iv = Buffer.from(parts.shift() as string, 'hex') + const decipher = crypto.createDecipheriv('aes-256-cbc', hashPassword(password, salt) as Buffer, iv) + const encryptedString = Buffer.from(parts.join(':'), 'hex') + const decrypted = Buffer.concat([decipher.update(encryptedString), decipher.final()]) + return decrypted.toString() +} + +export function hashPassword(password: string, salt: Buffer) { + try { + return crypto.scryptSync(password, salt, 32, { N: 32768, r: 8, p: 1, maxmem: 36000000 }) + } catch (e) { + console.error('Error during hashPassword', e) // TODO: Handle Error + } +} diff --git a/main/signers/hot/HotSigner/worker/launch.ts b/main/signers/hot/HotSigner/worker/launch.ts new file mode 100644 index 000000000..c326d8df2 --- /dev/null +++ b/main/signers/hot/HotSigner/worker/launch.ts @@ -0,0 +1,29 @@ +import RingSignerWorker from '../../RingSigner/worker' +import SeedSignerWorker from '../../SeedSigner/worker' +import launchController from './controller' + +import type { WorkerRPCMessage, WorkerTokenMessage } from '../types' + +const signerType = process.argv[2] as HotSignerType +let worker + +if (signerType === 'seed') { + worker = new SeedSignerWorker() +} + +if (signerType === 'ring') { + worker = new RingSignerWorker() +} + +if (!worker) { + process.exit(3) +} + +const ipc = { + send: (message: WorkerTokenMessage | WorkerRPCMessage) => { + if (process.send) process.send(message) + }, + on: process.on.bind(process) +} + +launchController(worker, ipc) diff --git a/main/signers/hot/RingSigner/index.js b/main/signers/hot/RingSigner/index.ts similarity index 51% rename from main/signers/hot/RingSigner/index.js rename to main/signers/hot/RingSigner/index.ts index cee514ce6..db0a7c4da 100644 --- a/main/signers/hot/RingSigner/index.js +++ b/main/signers/hot/RingSigner/index.ts @@ -1,36 +1,50 @@ -const path = require('path') -const log = require('electron-log') -const { fromPrivateKey, fromV1, fromV3 } = require('ethereumjs-wallet').default +import log from 'electron-log' +import Wallet from 'ethereumjs-wallet' -const HotSigner = require('../HotSigner') +import HotSigner from '../HotSigner' -const WORKER_PATH = path.resolve(__dirname, 'worker.js') +import type { HotSignerData } from '..' + +export interface RingSignerData extends HotSignerData { + encryptedKeys: string +} + +export default class RingSigner extends HotSigner { + private encryptedKeys = '' + + static fromStoredData(data: Omit) { + const signer = new RingSigner() + + signer.encryptedKeys = data.encryptedKeys + signer.addresses = data.addresses + signer.update() + + return signer + } + + constructor() { + super('ring') -class RingSigner extends HotSigner { - constructor(signer) { - super(signer, WORKER_PATH) - this.type = 'ring' this.model = 'keyring' - this.encryptedKeys = signer && signer.encryptedKeys - if (this.encryptedKeys) this.update() } - save() { + protected save() { super.save({ encryptedKeys: this.encryptedKeys }) } - unlock(password, cb) { - super.unlock(password, { encryptedKeys: this.encryptedKeys }, cb) + unlock(password: string, cb: ErrorOnlyCallback) { + super.unlockWorker(password, { encryptedSecret: this.encryptedKeys }, cb) } - addPrivateKey(key, password, cb) { + addPrivateKey(key: string, password: string, cb: ErrorOnlyCallback) { // Validate private key let wallet try { - wallet = fromPrivateKey(Buffer.from(key, 'hex')) + wallet = Wallet.fromPrivateKey(Buffer.from(key, 'hex')) } catch (e) { return cb(new Error('Invalid private key')) } + const address = wallet.getAddressString() // Ensure private key hasn't already been added @@ -40,7 +54,7 @@ class RingSigner extends HotSigner { // Call worker const params = { encryptedKeys: this.encryptedKeys, key, password } - this._callWorker({ method: 'addKey', params }, (err, encryptedKeys) => { + this.callWorker({ method: 'addKey', params }, (err, encryptedKeys) => { // Handle errors if (err) return cb(err) @@ -48,7 +62,7 @@ class RingSigner extends HotSigner { this.addresses = [...this.addresses, address] // Update encrypted keys - this.encryptedKeys = encryptedKeys + this.encryptedKeys = encryptedKeys as string // Log and update signer log.info('Private key added to signer', this.id) @@ -59,10 +73,10 @@ class RingSigner extends HotSigner { }) } - removePrivateKey(index, password, cb) { + removePrivateKey(index: number, password: string, cb: ErrorOnlyCallback) { // Call worker const params = { encryptedKeys: this.encryptedKeys, index, password } - this._callWorker({ method: 'removeKey', params }, (err, encryptedKeys) => { + this.callWorker({ method: 'removeKey', params }, (err, encryptedKeys) => { // Handle errors if (err) return cb(err) @@ -70,7 +84,7 @@ class RingSigner extends HotSigner { this.addresses = this.addresses.filter((address) => address !== this.addresses[index]) // Update encrypted keys - this.encryptedKeys = encryptedKeys + this.encryptedKeys = encryptedKeys as string // Log and update signer log.info('Private key removed from signer', this.id) @@ -83,19 +97,17 @@ class RingSigner extends HotSigner { } // TODO: Encrypt all keys together so that they all get the same password - async addKeystore(keystore, keystorePassword, password, cb) { + async addKeystore(keystore: any, keystorePassword: string, password: string, cb: ErrorOnlyCallback) { let wallet // Try to generate wallet from keystore try { - if (keystore.version === 1) wallet = await fromV1(keystore, keystorePassword) - else if (keystore.version === 3) wallet = await fromV3(keystore, keystorePassword) + if (keystore.version === 1) wallet = await Wallet.fromV1(keystore, keystorePassword) + else if (keystore.version === 3) wallet = await Wallet.fromV3(keystore, keystorePassword) else return cb(new Error('Invalid keystore version')) } catch (e) { - return cb(e) + return cb(e as Error) } // Add private key - this.addPrivateKey(wallet.privateKey.toString('hex'), password, cb) + this.addPrivateKey(wallet.getPrivateKey().toString('hex'), password, cb) } } - -module.exports = RingSigner diff --git a/main/signers/hot/RingSigner/worker.js b/main/signers/hot/RingSigner/worker.js deleted file mode 100644 index 31762a6a2..000000000 --- a/main/signers/hot/RingSigner/worker.js +++ /dev/null @@ -1,81 +0,0 @@ -const HotSignerWorker = require('../HotSigner/worker') - -class RingSignerWorker extends HotSignerWorker { - constructor() { - super() - this.keys = null - process.on('message', (message) => this.handleMessage(message)) - } - - unlock({ encryptedKeys, password }, pseudoCallback) { - try { - this.keys = this._decrypt(encryptedKeys, password) - .split(':') - .map((key) => Buffer.from(key, 'hex')) - pseudoCallback(null) - } catch (e) { - pseudoCallback('Invalid password') - } - } - - lock(_, pseudoCallback) { - this.keys = null - pseudoCallback(null) - } - - addKey({ encryptedKeys, key, password }, pseudoCallback) { - let keys - // If signer already has encrypted keys -> decrypt them and add new key - if (encryptedKeys) keys = [...this._decryptKeys(encryptedKeys, password), key] - // Else -> generate new list of keys - else keys = [key] - // Encrypt and return list of keys - encryptedKeys = this._encryptKeys(keys, password) - pseudoCallback(null, encryptedKeys) - } - - removeKey({ encryptedKeys, index, password }, pseudoCallback) { - if (!encryptedKeys) return pseudoCallback('Signer does not have any keys') - // Get list of decrypted keys - let keys = this._decryptKeys(encryptedKeys, password) - // Remove key from list - keys = keys.filter((key) => key !== keys[index]) - // Return encrypted list (or null if empty) - const result = keys.length > 0 ? this._encryptKeys(keys, password) : null - pseudoCallback(null, result) - } - - signMessage({ index, message }, pseudoCallback) { - // Make sure signer is unlocked - if (!this.keys) return pseudoCallback('Signer locked') - // Sign message - super.signMessage(this.keys[index], message, pseudoCallback) - } - - signTypedData({ index, typedMessage }, pseudoCallback) { - // Make sure signer is unlocked - if (!this.keys) return pseudoCallback('Signer locked') - // Sign Typed Data - super.signTypedData(this.keys[index], typedMessage, pseudoCallback) - } - - signTransaction({ index, rawTx }, pseudoCallback) { - // Make sure signer is unlocked - if (!this.keys) return pseudoCallback('Signer locked') - // Sign transaction - super.signTransaction(this.keys[index], rawTx, pseudoCallback) - } - - _decryptKeys(encryptedKeys, password) { - if (!encryptedKeys) return null - const keyString = this._decrypt(encryptedKeys, password) - return keyString.split(':') - } - - _encryptKeys(keys, password) { - const keyString = keys.join(':') - return this._encrypt(keyString, password) - } -} - -const ringSignerWorker = new RingSignerWorker() // eslint-disable-line diff --git a/main/signers/hot/RingSigner/worker.ts b/main/signers/hot/RingSigner/worker.ts new file mode 100644 index 000000000..11ab80579 --- /dev/null +++ b/main/signers/hot/RingSigner/worker.ts @@ -0,0 +1,108 @@ +import { + decrypt, + encrypt, + isHotSignerMethod, + signMessage, + signTransaction, + signTypedData +} from '../HotSigner/worker' + +import type { + AddKeyParams, + CoreWorkerMethod, + HotSignerMessageHandler, + PseudoCallback, + RemoveKeyParams, + RingSignerMethod, + SignMessageParams, + SignTypedDataParams, + TransactionParams, + UnlockParams, + WorkerMethod +} from '../HotSigner/types' + +function decryptKeys(encryptedKeys: string, password: string) { + const keyString = decrypt(encryptedKeys, password) + return keyString.split(':') +} + +function encryptKeys(keys: string[], password: string) { + const keyString = keys.join(':') + return encrypt(keyString, password) +} + +function isRingSignerMethod(method: string): method is RingSignerMethod | CoreWorkerMethod { + return isHotSignerMethod(method) || ['addKey', 'removeKey'].includes(method) +} + +export default class RingSignerWorker implements HotSignerMessageHandler { + private keys: Buffer[] | null = null + + handleMessage(cb: PseudoCallback, method: WorkerMethod, params: any) { + if (isRingSignerMethod(method)) { + return this[method](cb, params) + } + + cb(`Invalid method: '${method}'`) + } + + unlock(cb: PseudoCallback, { encryptedSecret: encryptedKeys, password }: UnlockParams) { + try { + this.keys = decrypt(encryptedKeys, password) + .split(':') + .map((key) => Buffer.from(key, 'hex')) + cb(null) + } catch (e) { + cb('Invalid password') + } + } + + lock(cb: PseudoCallback) { + this.keys = null + cb(null) + } + + addKey(cb: PseudoCallback, { encryptedKeys, key, password }: AddKeyParams) { + // If signer already has encrypted keys -> decrypt them and add new key + // Else -> generate new list of keys + const keys = encryptedKeys ? [...decryptKeys(encryptedKeys, password), key] : [key] + + // Encrypt and return list of keys + const newlyEncryptedKeys = encryptKeys(keys, password) + + cb(null, newlyEncryptedKeys) + } + + removeKey(cb: PseudoCallback, { encryptedKeys, index, password }: RemoveKeyParams) { + if (!encryptedKeys) return cb('Signer does not have any keys') + + const decryptedKeys = decryptKeys(encryptedKeys, password) + const keys = decryptedKeys.filter((key) => key !== decryptedKeys[index]) + + // Return encrypted list (or null if empty) + const result = keys.length > 0 ? encryptKeys(keys, password) : null + + cb(null, result) + } + + signMessage(cb: PseudoCallback, { index, message }: SignMessageParams) { + // Make sure signer is unlocked + if (!this.keys) return cb('Signer locked') + + signMessage(this.keys[index], message, cb) + } + + signTypedData(cb: PseudoCallback, { index, message }: SignTypedDataParams) { + // Make sure signer is unlocked + if (!this.keys) return cb('Signer locked') + + signTypedData(this.keys[index], message, cb) + } + + signTransaction(cb: PseudoCallback, { index, rawTx }: TransactionParams) { + // Make sure signer is unlocked + if (!this.keys) return cb('Signer locked') + + signTransaction(this.keys[index], rawTx, cb) + } +} diff --git a/main/signers/hot/SeedSigner/index.js b/main/signers/hot/SeedSigner/index.js deleted file mode 100644 index b110ddc42..000000000 --- a/main/signers/hot/SeedSigner/index.js +++ /dev/null @@ -1,60 +0,0 @@ -const path = require('path') -const HotSigner = require('../HotSigner') -const bip39 = require('bip39') -const hdKey = require('hdkey') -const { computeAddress } = require('ethers').utils - -const WORKER_PATH = path.resolve(__dirname, 'worker.js') - -class SeedSigner extends HotSigner { - constructor(signer) { - super(signer, WORKER_PATH) - this.encryptedSeed = signer && signer.encryptedSeed - this.type = 'seed' - this.model = 'phrase' - if (this.encryptedSeed) this.update() - } - - addSeed(seed, password, cb) { - if (this.encryptedSeed) return cb(new Error('This signer already has a seed')) - - this._callWorker({ method: 'encryptSeed', params: { seed, password } }, (err, encryptedSeed) => { - if (err) return cb(err) - - // Derive addresses - const wallet = hdKey.fromMasterSeed(Buffer.from(seed, 'hex')) - - const addresses = [] - for (let i = 0; i < 100; i++) { - const publicKey = wallet.derive("m/44'/60'/0'/0/" + i).publicKey - const address = computeAddress(publicKey) - addresses.push(address) - } - - // Update signer - this.encryptedSeed = encryptedSeed - this.addresses = addresses - this.update() - this.unlock(password, cb) - }) - } - - async addPhrase(phrase, password, cb) { - // Validate phrase - if (!bip39.validateMnemonic(phrase)) return cb(new Error('Invalid mnemonic phrase')) - // Get seed - const seed = await bip39.mnemonicToSeed(phrase) - // Add seed to signer - this.addSeed(seed.toString('hex'), password, cb) - } - - save() { - super.save({ encryptedSeed: this.encryptedSeed }) - } - - unlock(password, cb) { - super.unlock(password, { encryptedSeed: this.encryptedSeed }, cb) - } -} - -module.exports = SeedSigner diff --git a/main/signers/hot/SeedSigner/index.ts b/main/signers/hot/SeedSigner/index.ts new file mode 100644 index 000000000..cf56c9d86 --- /dev/null +++ b/main/signers/hot/SeedSigner/index.ts @@ -0,0 +1,72 @@ +import { validateMnemonic, mnemonicToSeed } from 'bip39' +import hdKey from 'hdkey' +import { utils } from 'ethers' + +import HotSigner from '../HotSigner' + +import type { HotSignerData } from '..' + +export interface SeedSignerData extends HotSignerData { + encryptedSeed: string +} + +export default class SeedSigner extends HotSigner { + private encryptedSeed = '' + + static fromStoredData(data: Omit) { + const signer = new SeedSigner() + + signer.encryptedSeed = data.encryptedSeed + signer.addresses = data.addresses + signer.update() + + return signer + } + + constructor() { + super('seed') + + this.model = 'phrase' + } + + addSeed(seed: string, password: string, cb: ErrorOnlyCallback) { + if (this.encryptedSeed) return cb(new Error('This signer already has a seed')) + + this.callWorker({ method: 'encryptSeed', params: { seed, password } }, (err, encryptedSeed) => { + if (err) return cb(err) + + // Derive addresses + const wallet = hdKey.fromMasterSeed(Buffer.from(seed, 'hex')) + + const addresses = [] + for (let i = 0; i < 100; i++) { + const publicKey = wallet.derive("m/44'/60'/0'/0/" + i).publicKey + const address = utils.computeAddress(publicKey) + addresses.push(address) + } + + // Update signer + this.encryptedSeed = encryptedSeed as string + this.addresses = addresses + this.update() + this.unlock(password, cb) + }) + } + + async addPhrase(phrase: string, password: string, cb: ErrorOnlyCallback) { + // Validate phrase + if (!validateMnemonic(phrase)) return cb(new Error('Invalid mnemonic phrase')) + // Get seed + const seed = await mnemonicToSeed(phrase) + // Add seed to signer + this.addSeed(seed.toString('hex'), password, cb) + } + + protected save() { + super.save({ encryptedSeed: this.encryptedSeed }) + } + + unlock(password: string, cb: ErrorOnlyCallback) { + super.unlockWorker(password, { encryptedSecret: this.encryptedSeed }, cb) + } +} diff --git a/main/signers/hot/SeedSigner/worker.js b/main/signers/hot/SeedSigner/worker.js deleted file mode 100644 index 4245411bf..000000000 --- a/main/signers/hot/SeedSigner/worker.js +++ /dev/null @@ -1,63 +0,0 @@ -const hdKey = require('hdkey') -const HotSignerWorker = require('../HotSigner/worker') - -class SeedSignerWorker extends HotSignerWorker { - constructor() { - super() - this.seed = null - process.on('message', (message) => this.handleMessage(message)) - } - - unlock({ encryptedSeed, password }, pseudoCallback) { - try { - this.seed = this._decrypt(encryptedSeed, password) - pseudoCallback(null) - } catch (e) { - pseudoCallback('Invalid password') - } - } - - lock(_, pseudoCallback) { - this.seed = null - pseudoCallback(null) - } - - encryptSeed({ seed, password }, pseudoCallback) { - pseudoCallback(null, this._encrypt(seed.toString('hex'), password)) - } - - signMessage({ index, message }, pseudoCallback) { - // Make sure signer is unlocked - if (!this.seed) return pseudoCallback('Signer locked') - // Derive private key - const key = this._derivePrivateKey(index) - // Sign message - super.signMessage(key, message, pseudoCallback) - } - - signTypedData({ index, typedMessage }, pseudoCallback) { - // Make sure signer is unlocked - if (!this.seed) return pseudoCallback('Signer locked') - // Derive private key - const key = this._derivePrivateKey(index) - // Sign message - super.signTypedData(key, typedMessage, pseudoCallback) - } - - signTransaction({ index, rawTx }, pseudoCallback) { - // Make sure signer is unlocked - if (!this.seed) return pseudoCallback('Signer locked') - // Derive private key - const key = this._derivePrivateKey(index) - // Sign transaction - super.signTransaction(key, rawTx, pseudoCallback) - } - - _derivePrivateKey(index) { - let key = hdKey.fromMasterSeed(Buffer.from(this.seed, 'hex')) - key = key.derive("m/44'/60'/0'/0/" + index) - return key.privateKey - } -} - -const seedSignerWorker = new SeedSignerWorker() // eslint-disable-line diff --git a/main/signers/hot/SeedSigner/worker.ts b/main/signers/hot/SeedSigner/worker.ts new file mode 100644 index 000000000..65444270a --- /dev/null +++ b/main/signers/hot/SeedSigner/worker.ts @@ -0,0 +1,87 @@ +import hdKey from 'hdkey' + +import { + decrypt, + encrypt, + isHotSignerMethod, + signMessage, + signTransaction, + signTypedData +} from '../HotSigner/worker' + +import type { + CoreWorkerMethod, + EncryptSeedParams, + HotSignerMessageHandler, + PseudoCallback, + SeedSignerMethod, + SignMessageParams, + SignTypedDataParams, + TransactionParams, + UnlockParams, + WorkerMethod +} from '../HotSigner/types' + +function derivePrivateKey(index: number, seed: string) { + const key = hdKey.fromMasterSeed(Buffer.from(seed as string, 'hex')).derive("m/44'/60'/0'/0/" + index) + + return key.privateKey +} + +function isSeedSignerMethod(method: string): method is CoreWorkerMethod | SeedSignerMethod { + return isHotSignerMethod(method) || ['encryptSeed'].includes(method) +} + +export default class SeedSignerWorker implements HotSignerMessageHandler { + private seed: string | null = null + + handleMessage(cb: PseudoCallback, method: WorkerMethod, params: any) { + if (isSeedSignerMethod(method)) { + return this[method](cb, params) + } + + cb(`Invalid method: '${method}'`) + } + + unlock(cb: PseudoCallback, { encryptedSecret: encryptedSeed, password }: UnlockParams) { + try { + this.seed = decrypt(encryptedSeed, password) + cb(null) + } catch (e) { + cb('Invalid password') + } + } + + lock(cb: PseudoCallback) { + this.seed = null + cb(null) + } + + encryptSeed(cb: PseudoCallback, { seed, password }: EncryptSeedParams) { + cb(null, encrypt(seed, password)) + } + + signMessage(cb: PseudoCallback, { index, message }: SignMessageParams) { + // Make sure signer is unlocked + if (!this.seed) return cb('Signer locked') + + const key = derivePrivateKey(index, this.seed) + signMessage(key, message, cb) + } + + signTypedData(cb: PseudoCallback, { index, message }: SignTypedDataParams) { + // Make sure signer is unlocked + if (!this.seed) return cb('Signer locked') + + const key = derivePrivateKey(index, this.seed) + signTypedData(key, message, cb) + } + + signTransaction(cb: PseudoCallback, { index, rawTx }: TransactionParams) { + // Make sure signer is unlocked + if (!this.seed) return cb('Signer locked') + + const key = derivePrivateKey(index, this.seed) + signTransaction(key, rawTx, cb) + } +} diff --git a/main/signers/hot/index.js b/main/signers/hot/index.ts similarity index 61% rename from main/signers/hot/index.js rename to main/signers/hot/index.ts index 71642cae3..c449d9887 100644 --- a/main/signers/hot/index.js +++ b/main/signers/hot/index.ts @@ -1,48 +1,43 @@ -const path = require('path') -const fs = require('fs') -const { ensureDirSync } = require('fs-extra') -const { app } = require('electron') -const log = require('electron-log') -const bip39 = require('bip39') -const zxcvbn = require('zxcvbn') +import path from 'path' +import fs from 'fs' +import log from 'electron-log' +import { generateMnemonic } from 'bip39' +import zxcvbn from 'zxcvbn' +import { ensureDirSync } from 'fs-extra' +import { app } from 'electron' +import { stripHexPrefix } from '@ethereumjs/util' -const crypt = require('../../crypt') +import { stringToKey } from '../../crypt' +import { wait } from '../../../resources/utils' -const SeedSigner = require('./SeedSigner') -const RingSigner = require('./RingSigner') -const { stripHexPrefix } = require('@ethereumjs/util') +import SeedSigner, { SeedSignerData } from './SeedSigner' +import RingSigner, { RingSignerData } from './RingSigner' +import type { Signers } from '..' +import type Signer from '../Signer' + +export interface HotSignerData { + type: HotSignerType + addresses: Address[] +} + +// TODO: remove this when updating tests const USER_DATA = app ? app.getPath('userData') - : path.resolve(path.dirname(require.main.filename), '../.userData') + : // @ts-ignore + path.resolve(path.dirname(require.main.filename), '../.userData') const SIGNERS_PATH = path.resolve(USER_DATA, 'signers') -const wait = async (ms) => new Promise((resolve) => setTimeout(resolve, ms)) - -module.exports = { - newPhrase: (cb) => { - cb(null, bip39.generateMnemonic()) +export default { + newPhrase: (cb: Callback) => { + cb(null, generateMnemonic()) }, - createFromSeed: (signers, seed, password, cb) => { - if (!seed) return cb(new Error('Seed required to create hot signer')) - if (!password) return cb(new Error('Password required to create hot signer')) - if (password.length < 12) return cb(new Error('Hot account password is too short')) - if (zxcvbn(password).score < 3) return cb(new Error('Hot account password is too weak')) - const signer = new SeedSigner() - signer.addSeed(seed, password, (err, result) => { - if (err) { - signer.close() - return cb(err) - } - signers.add(signer) - cb(null, signer) - }) - }, - createFromPhrase: (signers, phrase, password, cb) => { + createFromPhrase: (signers: Signers, phrase: string, password: string, cb: Callback) => { if (!phrase) return cb(new Error('Phrase required to create hot signer')) if (!password) return cb(new Error('Password required to create hot signer')) if (password.length < 12) return cb(new Error('Hot account password is too short')) if (zxcvbn(password).score < 3) return cb(new Error('Hot account password is too weak')) + const signer = new SeedSigner() signer.addPhrase(phrase, password, (err) => { if (err) { @@ -53,15 +48,15 @@ module.exports = { cb(null, signer) }) }, - createFromPrivateKey: (signers, privateKey, password, cb) => { + createFromPrivateKey: (signers: Signers, privateKey: string, password: string, cb: Callback) => { const privateKeyHex = stripHexPrefix(privateKey) if (!privateKeyHex) return cb(new Error('Private key required to create hot signer')) if (!password) return cb(new Error('Password required to create hot signer')) if (password.length < 12) return cb(new Error('Hot account password is too short')) if (zxcvbn(password).score < 3) return cb(new Error('Hot account password is too weak')) - const signer = new RingSigner() + const signer = new RingSigner() signer.addPrivateKey(privateKeyHex, password, (err) => { if (err) { signer.close() @@ -71,7 +66,13 @@ module.exports = { cb(null, signer) }) }, - createFromKeystore: (signers, keystore, keystorePassword, password, cb) => { + createFromKeystore: ( + signers: Signers, + keystore: any, + keystorePassword: string, + password: string, + cb: Callback + ) => { if (!keystore) return cb(new Error('Keystore required')) if (!keystorePassword) return cb(new Error('Keystore password required')) if (!password) return cb(new Error('Password required to create hot signer')) @@ -87,8 +88,8 @@ module.exports = { cb(null, signer) }) }, - scan: (signers) => { - const storedSigners = {} + scan: (signers: Signers) => { + const storedSigners: Record = {} const scan = async () => { // Ensure signer directory exists @@ -107,14 +108,21 @@ module.exports = { // Add stored signers for (const id of Object.keys(storedSigners)) { await wait(100) - const { addresses, encryptedKeys, encryptedSeed, type, network } = storedSigners[id] + const signerData = storedSigners[id] + const { addresses, type } = signerData + if (addresses && addresses.length) { - const id = crypt.stringToKey(addresses.join()).toString('hex') + const id = stringToKey(addresses.join()).toString('hex') if (!signers.exists(id)) { if (type === 'seed') { - signers.add(new SeedSigner({ network, addresses, encryptedSeed })) + const { encryptedSeed } = signerData as SeedSignerData + const signer = SeedSigner.fromStoredData({ addresses, encryptedSeed }) + signers.add(signer) } else if (type === 'ring') { - signers.add(new RingSigner({ network, addresses, encryptedKeys })) + const { encryptedKeys } = signerData as RingSignerData + const signer = RingSigner.fromStoredData({ addresses, encryptedKeys }) + + signers.add(signer) } } } diff --git a/main/signers/index.ts b/main/signers/index.ts index ff12c9be3..042315d24 100644 --- a/main/signers/index.ts +++ b/main/signers/index.ts @@ -14,6 +14,8 @@ import HotSigner from './hot/HotSigner' import store from '../store' +export type { Signers } + const registeredAdapters = [new LedgerAdapter(), new TrezorAdapter(), new LatticeAdapter()] interface AdapterSpec { @@ -171,7 +173,7 @@ class Signers extends EventEmitter { hot.createFromKeystore(this, keystore, keystorePassword, password, cb) } - addPrivateKey(id: string, privateKey: string, password: string, cb: Callback) { + addPrivateKey(id: string, privateKey: string, password: string, cb: ErrorOnlyCallback) { // Get signer const signer = this.get(id) // Make sure signer is of type 'ring' @@ -180,10 +182,11 @@ class Signers extends EventEmitter { } // Add private key - ;(signer as RingSigner).addPrivateKey(privateKey, password, cb) + const ringSigner = signer as RingSigner + ringSigner.addPrivateKey(privateKey, password, cb) } - removePrivateKey(id: string, index: number, password: string, cb: Callback) { + removePrivateKey(id: string, index: number, password: string, cb: ErrorOnlyCallback) { // Get signer const signer = this.get(id) @@ -192,7 +195,8 @@ class Signers extends EventEmitter { } // Add keystore - ;(signer as RingSigner).removePrivateKey(index, password, cb) + const ringSigner = signer as RingSigner + ringSigner.removePrivateKey(index, password, cb) } addKeystore( @@ -200,7 +204,7 @@ class Signers extends EventEmitter { keystore: Keystore, keystorePassword: string, password: string, - cb: Callback + cb: ErrorOnlyCallback ) { // Get signer const signer = this.get(id) @@ -209,24 +213,27 @@ class Signers extends EventEmitter { return cb(new Error('Keystores can only be used with ring signers'), undefined) } - ;(signer as RingSigner).addKeystore(keystore, keystorePassword, password, cb) + const ringSigner = signer as RingSigner + ringSigner.addKeystore(keystore, keystorePassword, password, cb) } - lock(id: string, cb: Callback) { + lock(id: string, cb: ErrorOnlyCallback) { const signer = this.get(id) - // @ts-ignore - if (signer && signer.lock) { - ;(signer as HotSigner).lock(cb) + // only hot signers have a lock method + if (signer && (signer as any).lock) { + const hotSigner = signer as HotSigner + hotSigner.lock(cb) } } - unlock(id: string, password: string, cb: Callback) { + unlock(id: string, password: string, cb: ErrorOnlyCallback) { const signer = this.signers[id] - // @ts-ignore - if (signer && signer.unlock) { - ;(signer as HotSigner).unlock(password, cb) + // only hot signers have an unlock method + if (signer && (signer as any).unlock) { + const hotSigner = signer as HotSigner + hotSigner.unlock(password, cb) } else { log.error('Signer not unlockable via password, no unlock method') } diff --git a/package-lock.json b/package-lock.json index 50e6fba34..694bdfaa1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -103,6 +103,7 @@ "@types/tar-fs": "2.0.1", "@types/uuid": "9.0.1", "@types/ws": "8.5.4", + "@types/zxcvbn": "4.4.1", "@typescript-eslint/eslint-plugin": "5.54.1", "@typescript-eslint/parser": "5.54.1", "electron": "23.1.3", @@ -2506,6 +2507,29 @@ "multihashes": "^2.0.0" } }, + "node_modules/@ensdomains/content-hash/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/@ensdomains/content-hash/node_modules/cids": { "version": "1.1.9", "resolved": "https://registry.npmjs.org/cids/-/cids-1.1.9.tgz", @@ -4501,9 +4525,9 @@ "hasInstallScript": true }, "node_modules/@ledgerhq/cryptoassets": { - "version": "9.2.0", - "resolved": "https://registry.npmjs.org/@ledgerhq/cryptoassets/-/cryptoassets-9.2.0.tgz", - "integrity": "sha512-mqoyiPXOnhSTm/djoN0e01NpzcW2u5AokToFACQgVxzE+DKAEkC4nXCGegBEjjnYxa7yXc3Kykpt9qEi0/d/oA==", + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@ledgerhq/cryptoassets/-/cryptoassets-9.3.0.tgz", + "integrity": "sha512-SUhGt8mF3E1bzNUR/HBZClC4wzfdiLPuMXLZ4SlKiMgp4fvt5Qi7UImdBssHVhcw0A+lcFqs0y1uRMFDllbTWQ==", "dependencies": { "invariant": "2" } @@ -4947,6 +4971,26 @@ "node": ">=14" } }, + "node_modules/@nomicfoundation/ethereumjs-block/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-block/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/@nomicfoundation/ethereumjs-block/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -4993,6 +5037,26 @@ "node": ">=14" } }, + "node_modules/@nomicfoundation/ethereumjs-blockchain/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-blockchain/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/@nomicfoundation/ethereumjs-blockchain/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -5043,6 +5107,26 @@ "node": ">=14" } }, + "node_modules/@nomicfoundation/ethereumjs-ethash/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-ethash/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/@nomicfoundation/ethereumjs-ethash/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -5085,6 +5169,26 @@ "node": ">=14" } }, + "node_modules/@nomicfoundation/ethereumjs-evm/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-evm/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/@nomicfoundation/ethereumjs-evm/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -5135,169 +5239,269 @@ "functional-red-black-tree": "^1.0.1" } }, - "node_modules/@nomicfoundation/ethereumjs-statemanager/node_modules/ethereum-cryptography": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", - "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", - "dev": true, - "dependencies": { - "@types/pbkdf2": "^3.0.0", - "@types/secp256k1": "^4.0.1", - "blakejs": "^1.1.0", - "browserify-aes": "^1.2.0", - "bs58check": "^2.1.2", - "create-hash": "^1.2.0", - "create-hmac": "^1.1.7", - "hash.js": "^1.1.7", - "keccak": "^3.0.0", - "pbkdf2": "^3.0.17", - "randombytes": "^2.1.0", - "safe-buffer": "^5.1.2", - "scrypt-js": "^3.0.0", - "secp256k1": "^4.0.1", - "setimmediate": "^1.0.5" - } - }, - "node_modules/@nomicfoundation/ethereumjs-trie": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-trie/-/ethereumjs-trie-5.0.5.tgz", - "integrity": "sha512-+8sNZrXkzvA1NH5F4kz5RSYl1I6iaRz7mAZRsyxOm0IVY4UaP43Ofvfp/TwOalFunurQrYB5pRO40+8FBcxFMA==", - "dev": true, - "dependencies": { - "@nomicfoundation/ethereumjs-rlp": "4.0.3", - "@nomicfoundation/ethereumjs-util": "8.0.6", - "ethereum-cryptography": "0.1.3", - "readable-stream": "^3.6.0" - }, - "engines": { - "node": ">=14" - } - }, - "node_modules/@nomicfoundation/ethereumjs-trie/node_modules/ethereum-cryptography": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", - "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", - "dev": true, - "dependencies": { - "@types/pbkdf2": "^3.0.0", - "@types/secp256k1": "^4.0.1", - "blakejs": "^1.1.0", - "browserify-aes": "^1.2.0", - "bs58check": "^2.1.2", - "create-hash": "^1.2.0", - "create-hmac": "^1.1.7", - "hash.js": "^1.1.7", - "keccak": "^3.0.0", - "pbkdf2": "^3.0.17", - "randombytes": "^2.1.0", - "safe-buffer": "^5.1.2", - "scrypt-js": "^3.0.0", - "secp256k1": "^4.0.1", - "setimmediate": "^1.0.5" - } - }, - "node_modules/@nomicfoundation/ethereumjs-tx": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-tx/-/ethereumjs-tx-4.1.2.tgz", - "integrity": "sha512-emJBJZpmTdUa09cqxQqHaysbBI9Od353ZazeH7WgPb35miMgNY6mb7/3vBA98N5lUW/rgkiItjX0KZfIzihSoQ==", - "dev": true, - "dependencies": { - "@nomicfoundation/ethereumjs-common": "3.1.2", - "@nomicfoundation/ethereumjs-rlp": "4.0.3", - "@nomicfoundation/ethereumjs-util": "8.0.6", - "ethereum-cryptography": "0.1.3" - }, - "engines": { - "node": ">=14" - } - }, - "node_modules/@nomicfoundation/ethereumjs-tx/node_modules/ethereum-cryptography": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", - "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", - "dev": true, - "dependencies": { - "@types/pbkdf2": "^3.0.0", - "@types/secp256k1": "^4.0.1", - "blakejs": "^1.1.0", - "browserify-aes": "^1.2.0", - "bs58check": "^2.1.2", - "create-hash": "^1.2.0", - "create-hmac": "^1.1.7", - "hash.js": "^1.1.7", - "keccak": "^3.0.0", - "pbkdf2": "^3.0.17", - "randombytes": "^2.1.0", - "safe-buffer": "^5.1.2", - "scrypt-js": "^3.0.0", - "secp256k1": "^4.0.1", - "setimmediate": "^1.0.5" - } - }, - "node_modules/@nomicfoundation/ethereumjs-util": { - "version": "8.0.6", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-util/-/ethereumjs-util-8.0.6.tgz", - "integrity": "sha512-jOQfF44laa7xRfbfLXojdlcpkvxeHrE2Xu7tSeITsWFgoII163MzjOwFEzSNozHYieFysyoEMhCdP+NY5ikstw==", - "dev": true, - "dependencies": { - "@nomicfoundation/ethereumjs-rlp": "4.0.3", - "ethereum-cryptography": "0.1.3" - }, - "engines": { - "node": ">=14" - } - }, - "node_modules/@nomicfoundation/ethereumjs-util/node_modules/ethereum-cryptography": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", - "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", + "node_modules/@nomicfoundation/ethereumjs-statemanager/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", "dev": true, "dependencies": { - "@types/pbkdf2": "^3.0.0", - "@types/secp256k1": "^4.0.1", - "blakejs": "^1.1.0", - "browserify-aes": "^1.2.0", - "bs58check": "^2.1.2", - "create-hash": "^1.2.0", - "create-hmac": "^1.1.7", - "hash.js": "^1.1.7", - "keccak": "^3.0.0", - "pbkdf2": "^3.0.17", - "randombytes": "^2.1.0", - "safe-buffer": "^5.1.2", - "scrypt-js": "^3.0.0", - "secp256k1": "^4.0.1", - "setimmediate": "^1.0.5" + "base-x": "^3.0.2" } }, - "node_modules/@nomicfoundation/ethereumjs-vm": { - "version": "6.4.2", - "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-vm/-/ethereumjs-vm-6.4.2.tgz", - "integrity": "sha512-PRTyxZMP6kx+OdAzBhuH1LD2Yw+hrSpaytftvaK//thDy2OI07S0nrTdbrdk7b8ZVPAc9H9oTwFBl3/wJ3w15g==", + "node_modules/@nomicfoundation/ethereumjs-statemanager/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", "dev": true, "dependencies": { - "@nomicfoundation/ethereumjs-block": "4.2.2", - "@nomicfoundation/ethereumjs-blockchain": "6.2.2", - "@nomicfoundation/ethereumjs-common": "3.1.2", - "@nomicfoundation/ethereumjs-evm": "1.3.2", - "@nomicfoundation/ethereumjs-rlp": "4.0.3", - "@nomicfoundation/ethereumjs-statemanager": "1.0.5", - "@nomicfoundation/ethereumjs-trie": "5.0.5", - "@nomicfoundation/ethereumjs-tx": "4.1.2", - "@nomicfoundation/ethereumjs-util": "8.0.6", - "@types/async-eventemitter": "^0.2.1", - "async-eventemitter": "^0.2.4", - "debug": "^4.3.3", - "ethereum-cryptography": "0.1.3", - "functional-red-black-tree": "^1.0.1", - "mcl-wasm": "^0.7.1", - "rustbn.js": "~0.2.0" - }, - "engines": { - "node": ">=14" + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" } }, - "node_modules/@nomicfoundation/ethereumjs-vm/node_modules/ethereum-cryptography": { + "node_modules/@nomicfoundation/ethereumjs-statemanager/node_modules/ethereum-cryptography": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", + "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", + "dev": true, + "dependencies": { + "@types/pbkdf2": "^3.0.0", + "@types/secp256k1": "^4.0.1", + "blakejs": "^1.1.0", + "browserify-aes": "^1.2.0", + "bs58check": "^2.1.2", + "create-hash": "^1.2.0", + "create-hmac": "^1.1.7", + "hash.js": "^1.1.7", + "keccak": "^3.0.0", + "pbkdf2": "^3.0.17", + "randombytes": "^2.1.0", + "safe-buffer": "^5.1.2", + "scrypt-js": "^3.0.0", + "secp256k1": "^4.0.1", + "setimmediate": "^1.0.5" + } + }, + "node_modules/@nomicfoundation/ethereumjs-trie": { + "version": "5.0.5", + "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-trie/-/ethereumjs-trie-5.0.5.tgz", + "integrity": "sha512-+8sNZrXkzvA1NH5F4kz5RSYl1I6iaRz7mAZRsyxOm0IVY4UaP43Ofvfp/TwOalFunurQrYB5pRO40+8FBcxFMA==", + "dev": true, + "dependencies": { + "@nomicfoundation/ethereumjs-rlp": "4.0.3", + "@nomicfoundation/ethereumjs-util": "8.0.6", + "ethereum-cryptography": "0.1.3", + "readable-stream": "^3.6.0" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@nomicfoundation/ethereumjs-trie/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-trie/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-trie/node_modules/ethereum-cryptography": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", + "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", + "dev": true, + "dependencies": { + "@types/pbkdf2": "^3.0.0", + "@types/secp256k1": "^4.0.1", + "blakejs": "^1.1.0", + "browserify-aes": "^1.2.0", + "bs58check": "^2.1.2", + "create-hash": "^1.2.0", + "create-hmac": "^1.1.7", + "hash.js": "^1.1.7", + "keccak": "^3.0.0", + "pbkdf2": "^3.0.17", + "randombytes": "^2.1.0", + "safe-buffer": "^5.1.2", + "scrypt-js": "^3.0.0", + "secp256k1": "^4.0.1", + "setimmediate": "^1.0.5" + } + }, + "node_modules/@nomicfoundation/ethereumjs-tx": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-tx/-/ethereumjs-tx-4.1.2.tgz", + "integrity": "sha512-emJBJZpmTdUa09cqxQqHaysbBI9Od353ZazeH7WgPb35miMgNY6mb7/3vBA98N5lUW/rgkiItjX0KZfIzihSoQ==", + "dev": true, + "dependencies": { + "@nomicfoundation/ethereumjs-common": "3.1.2", + "@nomicfoundation/ethereumjs-rlp": "4.0.3", + "@nomicfoundation/ethereumjs-util": "8.0.6", + "ethereum-cryptography": "0.1.3" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@nomicfoundation/ethereumjs-tx/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-tx/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-tx/node_modules/ethereum-cryptography": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", + "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", + "dev": true, + "dependencies": { + "@types/pbkdf2": "^3.0.0", + "@types/secp256k1": "^4.0.1", + "blakejs": "^1.1.0", + "browserify-aes": "^1.2.0", + "bs58check": "^2.1.2", + "create-hash": "^1.2.0", + "create-hmac": "^1.1.7", + "hash.js": "^1.1.7", + "keccak": "^3.0.0", + "pbkdf2": "^3.0.17", + "randombytes": "^2.1.0", + "safe-buffer": "^5.1.2", + "scrypt-js": "^3.0.0", + "secp256k1": "^4.0.1", + "setimmediate": "^1.0.5" + } + }, + "node_modules/@nomicfoundation/ethereumjs-util": { + "version": "8.0.6", + "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-util/-/ethereumjs-util-8.0.6.tgz", + "integrity": "sha512-jOQfF44laa7xRfbfLXojdlcpkvxeHrE2Xu7tSeITsWFgoII163MzjOwFEzSNozHYieFysyoEMhCdP+NY5ikstw==", + "dev": true, + "dependencies": { + "@nomicfoundation/ethereumjs-rlp": "4.0.3", + "ethereum-cryptography": "0.1.3" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@nomicfoundation/ethereumjs-util/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-util/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-util/node_modules/ethereum-cryptography": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", + "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", + "dev": true, + "dependencies": { + "@types/pbkdf2": "^3.0.0", + "@types/secp256k1": "^4.0.1", + "blakejs": "^1.1.0", + "browserify-aes": "^1.2.0", + "bs58check": "^2.1.2", + "create-hash": "^1.2.0", + "create-hmac": "^1.1.7", + "hash.js": "^1.1.7", + "keccak": "^3.0.0", + "pbkdf2": "^3.0.17", + "randombytes": "^2.1.0", + "safe-buffer": "^5.1.2", + "scrypt-js": "^3.0.0", + "secp256k1": "^4.0.1", + "setimmediate": "^1.0.5" + } + }, + "node_modules/@nomicfoundation/ethereumjs-vm": { + "version": "6.4.2", + "resolved": "https://registry.npmjs.org/@nomicfoundation/ethereumjs-vm/-/ethereumjs-vm-6.4.2.tgz", + "integrity": "sha512-PRTyxZMP6kx+OdAzBhuH1LD2Yw+hrSpaytftvaK//thDy2OI07S0nrTdbrdk7b8ZVPAc9H9oTwFBl3/wJ3w15g==", + "dev": true, + "dependencies": { + "@nomicfoundation/ethereumjs-block": "4.2.2", + "@nomicfoundation/ethereumjs-blockchain": "6.2.2", + "@nomicfoundation/ethereumjs-common": "3.1.2", + "@nomicfoundation/ethereumjs-evm": "1.3.2", + "@nomicfoundation/ethereumjs-rlp": "4.0.3", + "@nomicfoundation/ethereumjs-statemanager": "1.0.5", + "@nomicfoundation/ethereumjs-trie": "5.0.5", + "@nomicfoundation/ethereumjs-tx": "4.1.2", + "@nomicfoundation/ethereumjs-util": "8.0.6", + "@types/async-eventemitter": "^0.2.1", + "async-eventemitter": "^0.2.4", + "debug": "^4.3.3", + "ethereum-cryptography": "0.1.3", + "functional-red-black-tree": "^1.0.1", + "mcl-wasm": "^0.7.1", + "rustbn.js": "~0.2.0" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@nomicfoundation/ethereumjs-vm/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-vm/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/@nomicfoundation/ethereumjs-vm/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", "integrity": "sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==", @@ -6299,6 +6503,135 @@ "url": "https://opencollective.com/parcel" } }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/commander": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", + "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", + "dev": true, + "engines": { + "node": ">= 10" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/css-select": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", + "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", + "dev": true, + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^6.0.1", + "domhandler": "^4.3.1", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/css-tree": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz", + "integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==", + "dev": true, + "dependencies": { + "mdn-data": "2.0.14", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/csso": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/csso/-/csso-4.2.0.tgz", + "integrity": "sha512-wvlcdIbf6pwKEk7vHj8/Bkc0B4ylXZruLvOgs9doS5eOsOpuodOV2zJChSpkp+pRpYQLQMeF04nr3Z68Sta9jA==", + "dev": true, + "dependencies": { + "css-tree": "^1.1.2" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/dom-serializer": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", + "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "dev": true, + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "dev": true, + "dependencies": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", + "dev": true, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/mdn-data": { + "version": "2.0.14", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", + "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", + "dev": true + }, + "node_modules/@parcel/optimizer-htmlnano/node_modules/svgo": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/svgo/-/svgo-2.8.0.tgz", + "integrity": "sha512-+N/Q9kV1+F+UeWYoSiULYo4xYSDQlTgb+ayMobAXPwMnLvop7oxKMo9OzIrX5x3eS4L4f2UHhc9axXwY8DpChg==", + "dev": true, + "dependencies": { + "@trysound/sax": "0.2.0", + "commander": "^7.2.0", + "css-select": "^4.1.3", + "css-tree": "^1.1.3", + "csso": "^4.2.0", + "picocolors": "^1.0.0", + "stable": "^0.1.8" + }, + "bin": { + "svgo": "bin/svgo" + }, + "engines": { + "node": ">=10.13.0" + } + }, "node_modules/@parcel/optimizer-image": { "version": "2.8.3", "resolved": "https://registry.npmjs.org/@parcel/optimizer-image/-/optimizer-image-2.8.3.tgz", @@ -6340,6 +6673,135 @@ "url": "https://opencollective.com/parcel" } }, + "node_modules/@parcel/optimizer-svgo/node_modules/commander": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", + "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", + "dev": true, + "engines": { + "node": ">= 10" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/css-select": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", + "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", + "dev": true, + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^6.0.1", + "domhandler": "^4.3.1", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/css-tree": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz", + "integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==", + "dev": true, + "dependencies": { + "mdn-data": "2.0.14", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/csso": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/csso/-/csso-4.2.0.tgz", + "integrity": "sha512-wvlcdIbf6pwKEk7vHj8/Bkc0B4ylXZruLvOgs9doS5eOsOpuodOV2zJChSpkp+pRpYQLQMeF04nr3Z68Sta9jA==", + "dev": true, + "dependencies": { + "css-tree": "^1.1.2" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/dom-serializer": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", + "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", + "dev": true, + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "dev": true, + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "dev": true, + "dependencies": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", + "dev": true, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/@parcel/optimizer-svgo/node_modules/mdn-data": { + "version": "2.0.14", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", + "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", + "dev": true + }, + "node_modules/@parcel/optimizer-svgo/node_modules/svgo": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/svgo/-/svgo-2.8.0.tgz", + "integrity": "sha512-+N/Q9kV1+F+UeWYoSiULYo4xYSDQlTgb+ayMobAXPwMnLvop7oxKMo9OzIrX5x3eS4L4f2UHhc9axXwY8DpChg==", + "dev": true, + "dependencies": { + "@trysound/sax": "0.2.0", + "commander": "^7.2.0", + "css-select": "^4.1.3", + "css-tree": "^1.1.3", + "csso": "^4.2.0", + "picocolors": "^1.0.0", + "stable": "^0.1.8" + }, + "bin": { + "svgo": "bin/svgo" + }, + "engines": { + "node": ">=10.13.0" + } + }, "node_modules/@parcel/optimizer-terser": { "version": "2.8.3", "resolved": "https://registry.npmjs.org/@parcel/optimizer-terser/-/optimizer-terser-2.8.3.tgz", @@ -7916,13 +8378,15 @@ } }, "node_modules/@trezor/blockchain-link": { - "version": "2.1.8", - "resolved": "https://registry.npmjs.org/@trezor/blockchain-link/-/blockchain-link-2.1.8.tgz", - "integrity": "sha512-U42+SMUTyMoxm92wETtpIkrWH2SqkG42qq9F55KHMfu1Lt6rkrxhcDjnvmgcvTjmr9qxGmKe0vPtB/l3qH0aGQ==", - "dependencies": { - "@trezor/utils": "^9.0.6", - "@trezor/utxo-lib": "^1.0.4", - "@types/web": "^0.0.91", + "version": "2.1.10", + "resolved": "https://registry.npmjs.org/@trezor/blockchain-link/-/blockchain-link-2.1.10.tgz", + "integrity": "sha512-MDkOVdGSUiWKD2yVtlPO0tSRs+D0NRcAuUCiOBoW2fpPpDCPCqgAbqdHDbJKtz0BGSS5J22Zw9qFeGXevE5Hgw==", + "dependencies": { + "@trezor/blockchain-link-types": "1.0.1", + "@trezor/blockchain-link-utils": "1.0.1", + "@trezor/utils": "9.0.7", + "@trezor/utxo-lib": "1.0.5", + "@types/web": "^0.0.99", "bignumber.js": "^9.1.1", "events": "^3.3.0", "ripple-lib": "^1.10.1", @@ -7930,6 +8394,20 @@ "ws": "7.5.9" } }, + "node_modules/@trezor/blockchain-link-types": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@trezor/blockchain-link-types/-/blockchain-link-types-1.0.1.tgz", + "integrity": "sha512-MoH+AI0/skRuT2v/ijSmTx70xuScc5ubkkBPsDTBCxjJUR7jpAHpLRqsD6SaYLwmXa178ly7ELLlaf0nqRLHuA==" + }, + "node_modules/@trezor/blockchain-link-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@trezor/blockchain-link-utils/-/blockchain-link-utils-1.0.1.tgz", + "integrity": "sha512-Yh31oVYm2JigL/pmut5+m/uLQwO0/1y7gOTyTLLHhe2EFtfWI3ztRjFZR1QcVmY4+fj9YbDZ5ngLw494xoHoUA==", + "dependencies": { + "@trezor/utils": "9.0.7", + "bignumber.js": "^9.1.1" + } + }, "node_modules/@trezor/blockchain-link/node_modules/ws": { "version": "7.5.9", "resolved": "https://registry.npmjs.org/ws/-/ws-7.5.9.tgz", @@ -7976,29 +8454,43 @@ "integrity": "sha512-u7hrcS3eBHzR6b2dYD1PBPYw5vWaKT5eLoEL+ykPv2DeJsq0AgdRTNQom9tTUonyHoxGdnjQuaEO2Y4j2hZeng==" }, "node_modules/@trezor/transport": { - "version": "1.1.8", - "resolved": "https://registry.npmjs.org/@trezor/transport/-/transport-1.1.8.tgz", - "integrity": "sha512-Q5X0vTaZQu21PqaHL1Dnm6TVSsuK1mweMWRo2PDioDErSDlQrTMt/81gUV+HHZq/ej2m4C6YHx74pTlo2zJkfQ==", + "version": "1.1.9", + "resolved": "https://registry.npmjs.org/@trezor/transport/-/transport-1.1.9.tgz", + "integrity": "sha512-BzwVjJcRZcgpWh/db2a9paHVosUhVgV25z6RYFfzFg/GregjJiOMbofFBM1j5Xmz1JHls7H/tO3q+6dv7vRbJQ==", "dependencies": { - "@trezor/utils": "^9.0.6", + "@trezor/utils": "9.0.7", "bytebuffer": "^5.0.1", "json-stable-stringify": "^1.0.2", "long": "^4.0.0", - "prettier": "2.8.4", - "protobufjs": "^6.11.3" + "prettier": "2.8.7", + "protobufjs": "6.11.3" + } + }, + "node_modules/@trezor/transport/node_modules/prettier": { + "version": "2.8.7", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.7.tgz", + "integrity": "sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw==", + "bin": { + "prettier": "bin-prettier.js" + }, + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" } }, "node_modules/@trezor/utils": { - "version": "9.0.6", - "resolved": "https://registry.npmjs.org/@trezor/utils/-/utils-9.0.6.tgz", - "integrity": "sha512-ZrZDMa1DzcfptBTdIPd7jLJGd03EVbocCSa92o64Qb6FMGSUh+t8Y+9Yy6rBPN1GTOsJxVQmcj3leKrtJMgwVQ==" + "version": "9.0.7", + "resolved": "https://registry.npmjs.org/@trezor/utils/-/utils-9.0.7.tgz", + "integrity": "sha512-EyjYqufnbtIbeN9A+RKkxh2UoGabxtZWsWubJbcyXNmQUiEFou5PRayEEG5YKav+aiWwDw2tDEJl2w1IQcSzNw==" }, "node_modules/@trezor/utxo-lib": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@trezor/utxo-lib/-/utxo-lib-1.0.4.tgz", - "integrity": "sha512-n4Xj2YIpqRKaZiDZww0mcY0c2ZN+SDygR3dAJkUb7O/2FykxCS28z3QHIjfbdzMwquywbkxDeiErcdrHw3GIvg==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@trezor/utxo-lib/-/utxo-lib-1.0.5.tgz", + "integrity": "sha512-75DtK4COKftXWdNfAwudm9fVSC0bE3GSwd1wXWVrqFtiIVmwcLZohbdaVEo3Z6UqbCHWqzgiZBRfycX0EsYriw==", "dependencies": { - "@trezor/utils": "^9.0.6", + "@trezor/utils": "9.0.7", "bchaddrjs": "^0.5.2", "bech32": "^2.0.0", "bip66": "^1.1.5", @@ -8007,7 +8499,7 @@ "blakejs": "^1.2.1", "bn.js": "^5.2.1", "bs58": "^5.0.0", - "bs58check": "^2.1.2", + "bs58check": "^3.0.1", "create-hash": "^1.2.0", "create-hmac": "^1.1.7", "int64-buffer": "^1.0.1", @@ -8267,9 +8759,9 @@ } }, "node_modules/@types/lodash": { - "version": "4.14.192", - "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.192.tgz", - "integrity": "sha512-km+Vyn3BYm5ytMO13k9KTp27O75rbQ0NFw+U//g+PX7VZyjCioXaRFisqSIJRECljcTv73G3i6BpglNGHgUQ5A==" + "version": "4.14.194", + "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.194.tgz", + "integrity": "sha512-r22s9tAS7imvBt2lyHC9B8AGwWnXaYb1tY09oyLkXDs4vArpYJzw09nj8MLx5VfciBPGIb+ZwG0ssYnEPJxn/g==" }, "node_modules/@types/long": { "version": "4.0.2", @@ -8325,12 +8817,6 @@ "@types/node": "*" } }, - "node_modules/@types/parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==", - "dev": true - }, "node_modules/@types/pbkdf2": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@types/pbkdf2/-/pbkdf2-3.1.0.tgz", @@ -8363,9 +8849,9 @@ "dev": true }, "node_modules/@types/react": { - "version": "18.0.35", - "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.35.tgz", - "integrity": "sha512-6Laome31HpetaIUGFWl1VQ3mdSImwxtFZ39rh059a1MNnKGqBpC88J6NJ8n/Is3Qx7CefDGLgf/KhN/sYCf7ag==", + "version": "18.0.37", + "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.37.tgz", + "integrity": "sha512-4yaZZtkRN3ZIQD3KSEwkfcik8s0SWV+82dlJot1AbGYHCzJkWP3ENBY6wYeDRmKZ6HkrgoGAmR2HqdwYGp6OEw==", "dev": true, "dependencies": { "@types/prop-types": "*", @@ -8464,9 +8950,9 @@ "integrity": "sha512-cSjhgrr8g4KbPnnijAr/KJDNKa/bBa+ixYkywFRvrhvi9n1WEl7yYbtRyzE6jqNQiSxxJxoAW3STaOQwJHndaw==" }, "node_modules/@types/web": { - "version": "0.0.91", - "resolved": "https://registry.npmjs.org/@types/web/-/web-0.0.91.tgz", - "integrity": "sha512-KIw/1SNDyzPMpN7JiS2TTmiKXUhg4vkV2b8ozgQV0aw82dZr1chPXyunxVbUjSHaDrLxQbD+xpVk+CXiVkakHg==" + "version": "0.0.99", + "resolved": "https://registry.npmjs.org/@types/web/-/web-0.0.99.tgz", + "integrity": "sha512-xMz3tOvtkZzc7RpQrDNiLe5sfMmP+fz8bOxHIZ/U8qXyvzDX4L4Ss1HCjor/O9DSelba+1iXK1VM7lruX28hiQ==" }, "node_modules/@types/ws": { "version": "8.5.4", @@ -8501,6 +8987,12 @@ "@types/node": "*" } }, + "node_modules/@types/zxcvbn": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@types/zxcvbn/-/zxcvbn-4.4.1.tgz", + "integrity": "sha512-3NoqvZC2W5gAC5DZbTpCeJ251vGQmgcWIHQJGq2J240HY6ErQ9aWKkwfoKJlHLx+A83WPNTZ9+3cd2ILxbvr1w==", + "dev": true + }, "node_modules/@typescript-eslint/eslint-plugin": { "version": "5.54.1", "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.54.1.tgz", @@ -8749,30 +9241,6 @@ "node": ">=12" } }, - "node_modules/abstract-level/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/acorn": { "version": "8.8.2", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", @@ -9960,27 +10428,22 @@ "node": ">=8.0.0" } }, - "node_modules/bchaddrjs/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], + "node_modules/bchaddrjs/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" + "base-x": "^3.0.2" + } + }, + "node_modules/bchaddrjs/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" } }, "node_modules/bcrypt-pbkdf": { @@ -10010,26 +10473,14 @@ } }, "node_modules/bigint-crypto-utils": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/bigint-crypto-utils/-/bigint-crypto-utils-3.2.1.tgz", - "integrity": "sha512-/sERxP9gzXUJ7wfrFf4/oCnLc/Y87tkhi58o0zifx4VdQdLVW6OkV3X2+BxVJn1FTLpT1laG2YIbwP6ZLNut+A==", + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/bigint-crypto-utils/-/bigint-crypto-utils-3.2.2.tgz", + "integrity": "sha512-U1RbE3aX9ayCUVcIPHuPDPKcK3SFOXf93J1UK/iHlJuQB7bhagPIX06/CLpLEsDThJ7KA4Dhrnzynl+d2weTiw==", "dev": true, - "dependencies": { - "bigint-mod-arith": "^3.2.0" - }, "engines": { "node": ">=14.0.0" } }, - "node_modules/bigint-mod-arith": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/bigint-mod-arith/-/bigint-mod-arith-3.2.0.tgz", - "integrity": "sha512-Khb+sLGLqbe/2NOLVMOpCSgsC3lz8r3VIRZGc41hccudLPnvks7RYZNOnGukQZV8scn5+bA6MABga3Ueq6z3+w==", - "dev": true, - "engines": { - "node": ">=10.4.0" - } - }, "node_modules/bignumber.js": { "version": "9.1.1", "resolved": "https://registry.npmjs.org/bignumber.js/-/bignumber.js-9.1.1.tgz", @@ -10106,29 +10557,6 @@ "readable-stream": "^3.4.0" } }, - "node_modules/bl/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/blake-hash": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/blake-hash/-/blake-hash-2.0.0.tgz", @@ -10205,6 +10633,29 @@ "node": ">=4" } }, + "node_modules/borc/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/borc/node_modules/commander": { "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", @@ -10331,21 +10782,12 @@ "integrity": "sha512-FuwxlW4H5kh37X/oW59pwTzzTKRzfrrQwhmyspRM7swOEZcHtDZSCt45U6oKgtuFE+WYPblePMVIPR4RZrh/hw==" }, "node_modules/bs58check": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", - "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", - "dependencies": { - "bs58": "^4.0.0", - "create-hash": "^1.1.0", - "safe-buffer": "^5.1.2" - } - }, - "node_modules/bs58check/node_modules/bs58": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", - "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-3.0.1.tgz", + "integrity": "sha512-hjuuJvoWEybo7Hn/0xOrczQKKEKD63WguEjlhLExYs2wUBcebDC1jDNK17eEAD2lYfw82d5ASC1d7K3SWszjaQ==", "dependencies": { - "base-x": "^3.0.2" + "@noble/hashes": "^1.2.0", + "bs58": "^5.0.0" } }, "node_modules/bser": { @@ -10358,9 +10800,9 @@ } }, "node_modules/buffer": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", - "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", "funding": [ { "type": "github", @@ -10377,7 +10819,7 @@ ], "dependencies": { "base64-js": "^1.3.1", - "ieee754": "^1.1.13" + "ieee754": "^1.2.1" } }, "node_modules/buffer-alloc": { @@ -10803,9 +11245,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001478", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001478.tgz", - "integrity": "sha512-gMhDyXGItTHipJj2ApIvR+iVB5hd0KP3svMWWXDvZOmjzJJassGLMfxRkQCSYgGd2gtdL/ReeiyvMSFD1Ss6Mw==", + "version": "1.0.30001480", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001480.tgz", + "integrity": "sha512-q7cpoPPvZYgtyC4VaBSN0Bt+PJ4c4EYRf0DrduInOz2SkFpHD5p3LnvEpqBp7UnJn+8x1Ogl1s38saUxe+ihQQ==", "dev": true, "funding": [ { @@ -11015,6 +11457,29 @@ "npm": ">=3.0.0" } }, + "node_modules/cids/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/cids/node_modules/multicodec": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/multicodec/-/multicodec-1.0.4.tgz", @@ -11220,9 +11685,9 @@ } }, "node_modules/colorette": { - "version": "2.0.19", - "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.19.tgz", - "integrity": "sha512-3tlv/dIP7FWvj3BsbHrGLJ6l/oKh1O3TcgBqMn+yyCagOxc23fyzDS6HypQbgxWbkpDnf52p1LuR4eWDQ/K9WQ==", + "version": "2.0.20", + "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.20.tgz", + "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", "dev": true }, "node_modules/colors": { @@ -11346,9 +11811,9 @@ "integrity": "sha512-LDx6oHrK+PhzLKJU9j5S7/Y3jM/mUHvD/DeI1WQmJn652iPC5Y4TBzC9l+5OMOXlyTTA+SmVUPm0HQUwpD5Jqw==" }, "node_modules/core-js": { - "version": "3.30.0", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.30.0.tgz", - "integrity": "sha512-hQotSSARoNh1mYPi9O2YaWeiq/cEB95kOrFb4NCrO4RIFt1qqNpKsaE+vy/L3oiqvND5cThqXzUU3r9F7Efztg==", + "version": "3.30.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.30.1.tgz", + "integrity": "sha512-ZNS5nbiSwDTq4hFosEDqm65izl2CWmLz0hARJMyNQBgkUZMIF51cQiMvIQKA6hvuaeWxQDP3hEedM1JZIgTldQ==", "dev": true, "hasInstallScript": true, "funding": { @@ -11357,9 +11822,9 @@ } }, "node_modules/core-js-compat": { - "version": "3.30.0", - "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.30.0.tgz", - "integrity": "sha512-P5A2h/9mRYZFIAP+5Ab8ns6083IyVpSclU74UNvbGVQ8VM7n3n3/g2yF3AkKQ9NXz2O+ioxLbEWKnDtgsFamhg==", + "version": "3.30.1", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.30.1.tgz", + "integrity": "sha512-d690npR7MC6P0gq4npTl5n2VQeNAmUrJ90n+MHiKS7W2+xno4o3F5GDEuylSdi6EJ3VssibSGXOa1r3YXD3Mhw==", "dev": true, "dependencies": { "browserslist": "^4.21.5" @@ -11375,19 +11840,21 @@ "integrity": "sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==" }, "node_modules/cosmiconfig": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.1.0.tgz", - "integrity": "sha512-AdmX6xUzdNASswsFtmwSt7Vj8po9IuqXm0UXz7QKPuEUmPB4XyjGfaAr2PSuELMwkRMVH1EpIkX5bTZGRB3eCA==", + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.1.3.tgz", + "integrity": "sha512-/UkO2JKI18b5jVMJUp0lvKFMpa/Gye+ZgZjKD+DGEN9y7NRcf/nK1A0sp67ONmKtnDCNMS44E6jrk0Yc3bDuUw==", "dev": true, "dependencies": { - "@types/parse-json": "^4.0.0", "import-fresh": "^3.2.1", + "js-yaml": "^4.1.0", "parse-json": "^5.0.0", - "path-type": "^4.0.0", - "yaml": "^1.10.0" + "path-type": "^4.0.0" }, "engines": { - "node": ">=10" + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/d-fischer" } }, "node_modules/crc": { @@ -11411,6 +11878,31 @@ "node": ">=0.8" } }, + "node_modules/crc/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "optional": true, + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/create-hash": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz", @@ -11546,16 +12038,18 @@ } }, "node_modules/css-tree": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz", - "integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==", + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.3.1.tgz", + "integrity": "sha512-6Fv1DV/TYw//QF5IzQdqsNDjx/wc8TrMBZsqjL9eW01tWb7R7k/mq+/VXfJCl7SoD5emsJop9cOByJZfs8hYIw==", "dev": true, + "optional": true, + "peer": true, "dependencies": { - "mdn-data": "2.0.14", - "source-map": "^0.6.1" + "mdn-data": "2.0.30", + "source-map-js": "^1.0.1" }, "engines": { - "node": ">=8.0.0" + "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0" } }, "node_modules/css-what": { @@ -11570,17 +12064,44 @@ } }, "node_modules/csso": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/csso/-/csso-4.2.0.tgz", - "integrity": "sha512-wvlcdIbf6pwKEk7vHj8/Bkc0B4ylXZruLvOgs9doS5eOsOpuodOV2zJChSpkp+pRpYQLQMeF04nr3Z68Sta9jA==", + "version": "5.0.5", + "resolved": "https://registry.npmjs.org/csso/-/csso-5.0.5.tgz", + "integrity": "sha512-0LrrStPOdJj+SPCCrGhzryycLjwcgUSHBtxNA8aIDxf0GLsRh1cKYhB00Gd1lDOS4yGH69+SNn13+TWbVHETFQ==", "dev": true, + "optional": true, + "peer": true, "dependencies": { - "css-tree": "^1.1.2" + "css-tree": "~2.2.0" }, "engines": { - "node": ">=8.0.0" + "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", + "npm": ">=7.0.0" + } + }, + "node_modules/csso/node_modules/css-tree": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.2.1.tgz", + "integrity": "sha512-OA0mILzGc1kCOCSJerOeqDxDQ4HOh+G8NbOJFOTgOCzpw7fCBubk0fEyxp8AgOL/jvLgYA/uV0cMbe43ElF1JA==", + "dev": true, + "optional": true, + "peer": true, + "dependencies": { + "mdn-data": "2.0.28", + "source-map-js": "^1.0.1" + }, + "engines": { + "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0", + "npm": ">=7.0.0" } }, + "node_modules/csso/node_modules/mdn-data": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.28.tgz", + "integrity": "sha512-aylIc7Z9y4yzHYAJNuESG3hfhC+0Ibp/MAMiaOZgNv4pmEdFyfZhhhny4MNiAfWdBQ1RQ2mfDWmM1x8SvGyp8g==", + "dev": true, + "optional": true, + "peer": true + }, "node_modules/cssom": { "version": "0.5.0", "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.5.0.tgz", @@ -12561,9 +13082,9 @@ } }, "node_modules/electron-to-chromium": { - "version": "1.4.361", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.361.tgz", - "integrity": "sha512-VocVwjPp05HUXzf3xmL0boRn5b0iyqC7amtDww84Jb1QJNPBc7F69gJyEeXRoriLBC4a5pSyckdllrXAg4mmRA==", + "version": "1.4.368", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.368.tgz", + "integrity": "sha512-e2aeCAixCj9M7nJxdB/wDjO6mbYX+lJJxSJCXDzlr5YPGYVofuJwGN9nKg2o6wWInjX6XmxRinn3AeJMK81ltw==", "dev": true }, "node_modules/electron-updater": { @@ -12596,9 +13117,9 @@ } }, "node_modules/electron/node_modules/@types/node": { - "version": "16.18.23", - "resolved": "https://registry.npmjs.org/@types/node/-/node-16.18.23.tgz", - "integrity": "sha512-XAMpaw1s1+6zM+jn2tmw8MyaRDIJfXxqmIQIS0HfoGYPuf7dUWeiUKopwq13KFX9lEp1+THGtlaaYx39Nxr58g==", + "version": "16.18.24", + "resolved": "https://registry.npmjs.org/@types/node/-/node-16.18.24.tgz", + "integrity": "sha512-zvSN2Esek1aeLdKDYuntKAYjti9Z2oT4I8bfkLLhIxHlv3dwZ5vvATxOc31820iYm4hQRCwjUgDpwSMFjfTUnw==", "dev": true }, "node_modules/elliptic": { @@ -12672,9 +13193,9 @@ } }, "node_modules/entities": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.4.0.tgz", - "integrity": "sha512-oYp7156SP8LkeGD0GF85ad1X9Ai79WtRsZ2gxJqtBuzH+98YUV6jkHEKlZkMbcrjJjIVJNIDP/3WL9wQkoPbWA==", + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", + "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", "engines": { "node": ">=0.12" }, @@ -13244,15 +13765,18 @@ } }, "node_modules/eslint/node_modules/eslint-scope": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.1.tgz", - "integrity": "sha512-QKQM/UXpIiHcLqJ5AOyIW7XZmzjkzQXYE54n1++wb0u9V/abW3l9uQnxX8Z5Xd18xyKIMTUAyQ0k1e8pz6LUrw==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", + "integrity": "sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==", "dependencies": { "esrecurse": "^4.3.0", "estraverse": "^5.2.0" }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/eslint/node_modules/has-flag": { @@ -13356,29 +13880,6 @@ "js-sha3": "^0.8.0" } }, - "node_modules/eth-eip712-util-browser/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/eth-ens-namehash": { "version": "2.0.8", "resolved": "https://registry.npmjs.org/eth-ens-namehash/-/eth-ens-namehash-2.0.8.tgz", @@ -13481,6 +13982,26 @@ "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", "dev": true }, + "node_modules/ethereumjs-abi/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/ethereumjs-abi/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/ethereumjs-abi/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -13552,6 +14073,24 @@ "node": ">=10.0.0" } }, + "node_modules/ethereumjs-util/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/ethereumjs-util/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/ethereumjs-util/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -13600,6 +14139,24 @@ "uuid": "^8.3.2" } }, + "node_modules/ethereumjs-wallet/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/ethereumjs-wallet/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/ethereumjs-wallet/node_modules/ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -14490,6 +15047,47 @@ "resolved": "https://registry.npmjs.org/bech32/-/bech32-2.0.0.tgz", "integrity": "sha512-LcknSilhIGatDAsY1ak2I8VtGaHNhgMSYVxFrGLXv+xLHytaKZKcaUJJUE7qmBr7h33o5YQwP55pMI0xmkpJwg==" }, + "node_modules/gridplus-sdk/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/gridplus-sdk/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, + "node_modules/gridplus-sdk/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/hamt-sharding": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/hamt-sharding/-/hamt-sharding-2.0.1.tgz", @@ -14700,6 +15298,26 @@ "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", "dev": true }, + "node_modules/hardhat/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/hardhat/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/hardhat/node_modules/cookie": { "version": "0.4.2", "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.2.tgz", @@ -15083,6 +15701,24 @@ "secp256k1": "^4.0.0" } }, + "node_modules/hdkey/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/hdkey/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/he": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", @@ -15193,22 +15829,22 @@ "dev": true }, "node_modules/htmlnano": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/htmlnano/-/htmlnano-2.0.3.tgz", - "integrity": "sha512-S4PGGj9RbdgW8LhbILNK7W9JhmYP8zmDY7KDV/8eCiJBQJlbmltp5I0gv8c5ntLljfdxxfmJ+UJVSqyH4mb41A==", + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/htmlnano/-/htmlnano-2.0.4.tgz", + "integrity": "sha512-WGCkyGFwjKW1GeCBsPYacMvaMnZtFJ0zIRnC2NCddkA+IOEhTqskXrS7lep+3yYZw/nQ3dW1UAX4yA/GJyR8BA==", "dev": true, "dependencies": { - "cosmiconfig": "^7.0.1", + "cosmiconfig": "^8.0.0", "posthtml": "^0.16.5", "timsort": "^0.3.0" }, "peerDependencies": { - "cssnano": "^5.0.11", + "cssnano": "^6.0.0", "postcss": "^8.3.11", "purgecss": "^5.0.0", "relateurl": "^0.2.7", "srcset": "4.0.0", - "svgo": "^2.8.0", + "svgo": "^3.0.2", "terser": "^5.10.0", "uncss": "^0.17.3" }, @@ -15818,29 +16454,6 @@ "npm": ">=7.0.0" } }, - "node_modules/ipfs-utils/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/ipfs-utils/node_modules/iso-url": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/iso-url/-/iso-url-1.2.1.tgz", @@ -16629,29 +17242,6 @@ "readable-stream": "^3.6.0" } }, - "node_modules/it-to-stream/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/jake": { "version": "10.8.5", "resolved": "https://registry.npmjs.org/jake/-/jake-10.8.5.tgz", @@ -18989,30 +19579,6 @@ "node": ">=12" } }, - "node_modules/level-transcoder/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/leven": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", @@ -19044,9 +19610,9 @@ } }, "node_modules/lightningcss": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.19.0.tgz", - "integrity": "sha512-yV5UR7og+Og7lQC+70DA7a8ta1uiOPnWPJfxa0wnxylev5qfo4P+4iMpzWAdYWOca4jdNQZii+bDL/l+4hUXIA==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.20.0.tgz", + "integrity": "sha512-4bj8aP+Vi+or8Gwq/hknmicr4PmA8D9uL/3qY0N0daX5vYBMYERGI6Y93nzoeRgQMULq+gtrN/FvJYtH0xNN8g==", "dev": true, "dependencies": { "detect-libc": "^1.0.3" @@ -19059,20 +19625,20 @@ "url": "https://opencollective.com/parcel" }, "optionalDependencies": { - "lightningcss-darwin-arm64": "1.19.0", - "lightningcss-darwin-x64": "1.19.0", - "lightningcss-linux-arm-gnueabihf": "1.19.0", - "lightningcss-linux-arm64-gnu": "1.19.0", - "lightningcss-linux-arm64-musl": "1.19.0", - "lightningcss-linux-x64-gnu": "1.19.0", - "lightningcss-linux-x64-musl": "1.19.0", - "lightningcss-win32-x64-msvc": "1.19.0" + "lightningcss-darwin-arm64": "1.20.0", + "lightningcss-darwin-x64": "1.20.0", + "lightningcss-linux-arm-gnueabihf": "1.20.0", + "lightningcss-linux-arm64-gnu": "1.20.0", + "lightningcss-linux-arm64-musl": "1.20.0", + "lightningcss-linux-x64-gnu": "1.20.0", + "lightningcss-linux-x64-musl": "1.20.0", + "lightningcss-win32-x64-msvc": "1.20.0" } }, "node_modules/lightningcss-darwin-arm64": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.19.0.tgz", - "integrity": "sha512-wIJmFtYX0rXHsXHSr4+sC5clwblEMji7HHQ4Ub1/CznVRxtCFha6JIt5JZaNf8vQrfdZnBxLLC6R8pC818jXqg==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.20.0.tgz", + "integrity": "sha512-aYEohJTlzwB8URJaNiS57tMbjyLub0mYvxlxKQk8SZv+irXx6MoBWpDNQKKTS9gg1pGf/eAwjpa3BLAoCBsh1A==", "cpu": [ "arm64" ], @@ -19090,9 +19656,9 @@ } }, "node_modules/lightningcss-darwin-x64": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.19.0.tgz", - "integrity": "sha512-Lif1wD6P4poaw9c/4Uh2z+gmrWhw/HtXFoeZ3bEsv6Ia4tt8rOJBdkfVaUJ6VXmpKHALve+iTyP2+50xY1wKPw==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.20.0.tgz", + "integrity": "sha512-cmMgY8FFWVaGgtift7eKKkHMqlz9O09/yTdlCXEDOeDP9yeo6vHOBTRP7ojb368kjw8Ew3l0L2uT1Gtx56eNkg==", "cpu": [ "x64" ], @@ -19110,9 +19676,9 @@ } }, "node_modules/lightningcss-linux-arm-gnueabihf": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.19.0.tgz", - "integrity": "sha512-P15VXY5682mTXaiDtbnLYQflc8BYb774j2R84FgDLJTN6Qp0ZjWEFyN1SPqyfTj2B2TFjRHRUvQSSZ7qN4Weig==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.20.0.tgz", + "integrity": "sha512-/m+NDO1O6JCv7R9F0XWlXcintQHx4MPNU+kt8jZJO07LLdGwCfvjN31GVcwVPlStnnx/cU8uTTmax6g/Qu/whg==", "cpu": [ "arm" ], @@ -19130,9 +19696,9 @@ } }, "node_modules/lightningcss-linux-arm64-gnu": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.19.0.tgz", - "integrity": "sha512-zwXRjWqpev8wqO0sv0M1aM1PpjHz6RVIsBcxKszIG83Befuh4yNysjgHVplF9RTU7eozGe3Ts7r6we1+Qkqsww==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.20.0.tgz", + "integrity": "sha512-gtXoa6v0HvMRLbev6Hsef0+Q5He7NslB+Rs7G49Y5LUSdJeGIATEN+j8JzHC0DnxCsOGbEgGRmvtJzzYDkkluw==", "cpu": [ "arm64" ], @@ -19150,9 +19716,9 @@ } }, "node_modules/lightningcss-linux-arm64-musl": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.19.0.tgz", - "integrity": "sha512-vSCKO7SDnZaFN9zEloKSZM5/kC5gbzUjoJQ43BvUpyTFUX7ACs/mDfl2Eq6fdz2+uWhUh7vf92c4EaaP4udEtA==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.20.0.tgz", + "integrity": "sha512-Po7XpucM1kZnkiyd2BNwTExSDcZ8jm8uB9u+Sq44qjpkf5f75jreQwn3DQm9I1t5C6tB9HGt30HExMju9umJBQ==", "cpu": [ "arm64" ], @@ -19170,9 +19736,9 @@ } }, "node_modules/lightningcss-linux-x64-gnu": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.19.0.tgz", - "integrity": "sha512-0AFQKvVzXf9byrXUq9z0anMGLdZJS+XSDqidyijI5njIwj6MdbvX2UZK/c4FfNmeRa2N/8ngTffoIuOUit5eIQ==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.20.0.tgz", + "integrity": "sha512-8yR/fGNn/P0I+Lc3PK+VWPET/zdSpBfHFIG0DJ38TywMbItVKvnFvoTBwnIm4LqBz7g2G2dDexnNP95za2Ll8g==", "cpu": [ "x64" ], @@ -19190,9 +19756,9 @@ } }, "node_modules/lightningcss-linux-x64-musl": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.19.0.tgz", - "integrity": "sha512-SJoM8CLPt6ECCgSuWe+g0qo8dqQYVcPiW2s19dxkmSI5+Uu1GIRzyKA0b7QqmEXolA+oSJhQqCmJpzjY4CuZAg==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.20.0.tgz", + "integrity": "sha512-EmpJ+VkPZ8RACiB4m+l8TmapmE1W2UvJKDHE+ML/3Ihr9tRKUs3CibfnQTFZC8aSsrxgXagDAN+PgCDDhIyriA==", "cpu": [ "x64" ], @@ -19210,9 +19776,9 @@ } }, "node_modules/lightningcss-win32-x64-msvc": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.19.0.tgz", - "integrity": "sha512-C+VuUTeSUOAaBZZOPT7Etn/agx/MatzJzGRkeV+zEABmPuntv1zihncsi+AyGmjkkzq3wVedEy7h0/4S84mUtg==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.20.0.tgz", + "integrity": "sha512-BRdPvbq7Cc1qxAzp2emqWJHrqsEkf4ggxS29VOnxT7jhkdHKU+a26OVMjvm/OL0NH0ToNOZNAPvHMSexiEgBeA==", "cpu": [ "x64" ], @@ -19511,15 +20077,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/lint-staged/node_modules/yaml": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.1.tgz", - "integrity": "sha512-e0WHiYql7+9wr4cWMx3TVQrNwejKaEe7/rHNmQmqRjazfOP5W8PB6Jpebb5o6fIapbz9o9+2ipcaTM2ZwDI6lw==", - "dev": true, - "engines": { - "node": ">= 14" - } - }, "node_modules/listr2": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/listr2/-/listr2-5.0.8.tgz", @@ -19992,10 +20549,12 @@ } }, "node_modules/mdn-data": { - "version": "2.0.14", - "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", - "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", - "dev": true + "version": "2.0.30", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.30.tgz", + "integrity": "sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==", + "dev": true, + "optional": true, + "peer": true }, "node_modules/memory-level": { "version": "1.0.0", @@ -20501,6 +21060,29 @@ "buffer": "^5.5.0" } }, + "node_modules/multibase/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/multicodec": { "version": "0.5.7", "resolved": "https://registry.npmjs.org/multicodec/-/multicodec-0.5.7.tgz", @@ -20525,6 +21107,29 @@ "varint": "^5.0.0" } }, + "node_modules/multihashes/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/multihashes/node_modules/multibase": { "version": "0.7.0", "resolved": "https://registry.npmjs.org/multibase/-/multibase-0.7.0.tgz", @@ -21219,15 +21824,16 @@ } }, "node_modules/object.getownpropertydescriptors": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.5.tgz", - "integrity": "sha512-yDNzckpM6ntyQiGTik1fKV1DcVDRS+w8bvpWNCBanvH5LfRX9O8WTHqQzG4RZwRAM4I0oU7TV11Lj5v0g20ibw==", + "version": "2.1.6", + "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.6.tgz", + "integrity": "sha512-lq+61g26E/BgHv0ZTFgRvi7NMEPuAxLkFU7rukXjc/AlwH4Am5xXVnIXy3un1bg/JPbXHrixRkK1itUzzPiIjQ==", "dev": true, "dependencies": { "array.prototype.reduce": "^1.0.5", "call-bind": "^1.0.2", - "define-properties": "^1.1.4", - "es-abstract": "^1.20.4" + "define-properties": "^1.2.0", + "es-abstract": "^1.21.2", + "safe-array-concat": "^1.0.0" }, "engines": { "node": ">= 0.8" @@ -21667,9 +22273,9 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" }, "node_modules/path-scurry": { - "version": "1.6.4", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.6.4.tgz", - "integrity": "sha512-Qp/9IHkdNiXJ3/Kon++At2nVpnhRiPq/aSvQN+H3U1WZbvNRK0RIQK/o4HMqPoXjpuGJUEWpHSs6Mnjxqh3TQg==", + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.7.0.tgz", + "integrity": "sha512-UkZUeDjczjYRE495+9thsgcVgsaCPkaw80slmfVFgllxY+IO8ubTsOpFVjDPROBqJdHfVPUFRHPBV/WciOVfWg==", "dev": true, "dependencies": { "lru-cache": "^9.0.0", @@ -21683,9 +22289,9 @@ } }, "node_modules/path-scurry/node_modules/lru-cache": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-9.0.1.tgz", - "integrity": "sha512-C8QsKIN1UIXeOs3iWmiZ1lQY+EnKDojWd37fXy1aSbJvH4iSma1uy2OWuoB3m4SYRli5+CUjDv3Dij5DVoetmg==", + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-9.1.0.tgz", + "integrity": "sha512-qFXQEwchrZcMVen2uIDceR8Tii6kCJak5rzDStfEM0qA3YLMswaxIEZO0DhIbJ3aqaJiDjt+3crlplOb0tDtKQ==", "dev": true, "engines": { "node": "14 || >=16.14" @@ -22207,6 +22813,7 @@ "version": "2.8.4", "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.4.tgz", "integrity": "sha512-vIS4Rlc2FNh0BySk3Wkd6xmwxB0FpOndW5fisM5H8hsZSxU2VWVB5CWIkIjWvrHjIhxk2g3bfMKM87zNTrZddw==", + "dev": true, "bin": { "prettier": "bin-prettier.js" }, @@ -22756,13 +23363,13 @@ } }, "node_modules/regexp.prototype.flags": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz", - "integrity": "sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA==", + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz", + "integrity": "sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA==", "dependencies": { "call-bind": "^1.0.2", - "define-properties": "^1.1.3", - "functions-have-names": "^1.2.2" + "define-properties": "^1.2.0", + "functions-have-names": "^1.2.3" }, "engines": { "node": ">= 0.4" @@ -23347,6 +23954,24 @@ "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" }, + "node_modules/safe-array-concat": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.0.tgz", + "integrity": "sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ==", + "dev": true, + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", @@ -23563,29 +24188,6 @@ "buffer": "6.0.3" } }, - "node_modules/sha3/node_modules/buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "dependencies": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "node_modules/shallow-clone": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-3.0.1.tgz", @@ -23929,6 +24531,17 @@ "node": ">=0.10.0" } }, + "node_modules/source-map-js": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", + "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", + "dev": true, + "optional": true, + "peer": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/source-map-resolve": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.6.0.tgz", @@ -24398,24 +25011,29 @@ } }, "node_modules/svgo": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/svgo/-/svgo-2.8.0.tgz", - "integrity": "sha512-+N/Q9kV1+F+UeWYoSiULYo4xYSDQlTgb+ayMobAXPwMnLvop7oxKMo9OzIrX5x3eS4L4f2UHhc9axXwY8DpChg==", + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/svgo/-/svgo-3.0.2.tgz", + "integrity": "sha512-Z706C1U2pb1+JGP48fbazf3KxHrWOsLme6Rv7imFBn5EnuanDW1GPaA/P1/dvObE670JDePC3mnj0k0B7P0jjQ==", "dev": true, + "optional": true, + "peer": true, "dependencies": { "@trysound/sax": "0.2.0", "commander": "^7.2.0", - "css-select": "^4.1.3", - "css-tree": "^1.1.3", - "csso": "^4.2.0", - "picocolors": "^1.0.0", - "stable": "^0.1.8" + "css-select": "^5.1.0", + "css-tree": "^2.2.1", + "csso": "^5.0.5", + "picocolors": "^1.0.0" }, "bin": { "svgo": "bin/svgo" }, "engines": { - "node": ">=10.13.0" + "node": ">=14.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/svgo" } }, "node_modules/svgo/node_modules/commander": { @@ -24423,78 +25041,12 @@ "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", "dev": true, + "optional": true, + "peer": true, "engines": { "node": ">= 10" } }, - "node_modules/svgo/node_modules/css-select": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", - "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", - "dev": true, - "dependencies": { - "boolbase": "^1.0.0", - "css-what": "^6.0.1", - "domhandler": "^4.3.1", - "domutils": "^2.8.0", - "nth-check": "^2.0.1" - }, - "funding": { - "url": "https://github.com/sponsors/fb55" - } - }, - "node_modules/svgo/node_modules/dom-serializer": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", - "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", - "dev": true, - "dependencies": { - "domelementtype": "^2.0.1", - "domhandler": "^4.2.0", - "entities": "^2.0.0" - }, - "funding": { - "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" - } - }, - "node_modules/svgo/node_modules/domhandler": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", - "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", - "dev": true, - "dependencies": { - "domelementtype": "^2.2.0" - }, - "engines": { - "node": ">= 4" - }, - "funding": { - "url": "https://github.com/fb55/domhandler?sponsor=1" - } - }, - "node_modules/svgo/node_modules/domutils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", - "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", - "dev": true, - "dependencies": { - "dom-serializer": "^1.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0" - }, - "funding": { - "url": "https://github.com/fb55/domutils?sponsor=1" - } - }, - "node_modules/svgo/node_modules/entities": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", - "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", - "dev": true, - "funding": { - "url": "https://github.com/fb55/entities?sponsor=1" - } - }, "node_modules/symbol-tree": { "version": "3.2.4", "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz", @@ -24559,6 +25111,29 @@ "readable-stream": "^3.4.0" } }, + "node_modules/tar-stream/node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "node_modules/tar/node_modules/minipass": { "version": "4.2.8", "resolved": "https://registry.npmjs.org/minipass/-/minipass-4.2.8.tgz", @@ -24623,9 +25198,9 @@ } }, "node_modules/terser": { - "version": "5.16.9", - "resolved": "https://registry.npmjs.org/terser/-/terser-5.16.9.tgz", - "integrity": "sha512-HPa/FdTB9XGI2H1/keLFZHxl6WNvAI4YalHGtDQTlMnJcoqSab1UwL4l1hGEhs6/GmLHBZIg/YgB++jcbzoOEg==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.17.1.tgz", + "integrity": "sha512-hVl35zClmpisy6oaoKALOpS0rDYLxRFLHhRuDlEGTKey9qHjS1w9GMORjuwIMt70Wan4lwsLYyWDVnWgF+KUEw==", "dev": true, "dependencies": { "@jridgewell/source-map": "^0.3.2", @@ -25077,15 +25652,15 @@ } }, "node_modules/undici": { - "version": "5.21.2", - "resolved": "https://registry.npmjs.org/undici/-/undici-5.21.2.tgz", - "integrity": "sha512-f6pTQ9RF4DQtwoWSaC42P/NKlUjvezVvd9r155ohqkwFNRyBKM3f3pcty3ouusefNRyM25XhIQEbeQ46sZDJfQ==", + "version": "5.22.0", + "resolved": "https://registry.npmjs.org/undici/-/undici-5.22.0.tgz", + "integrity": "sha512-fR9RXCc+6Dxav4P9VV/sp5w3eFiSdOjJYsbtWfd4s5L5C4ogyuVpdKIVHeW0vV1MloM65/f7W45nR9ZxwVdyiA==", "dev": true, "dependencies": { "busboy": "^1.6.0" }, "engines": { - "node": ">=12.18" + "node": ">=14.0" } }, "node_modules/unicode-canonical-property-names-ecmascript": { @@ -25194,9 +25769,9 @@ } }, "node_modules/update-browserslist-db": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.10.tgz", - "integrity": "sha512-OztqDenkfFkbSG+tRxBeAnCVPckDBcvibKd35yDONx6OU8N7sqgwc7rCbkJ/WcYtVRZ4ba68d6byhC21GFh7sQ==", + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.11.tgz", + "integrity": "sha512-dCwEFf0/oT85M1fHBg4F0jtLwJrutGoHSQXCh7u4o2t1drG+c0a9Flnqww6XUKSfQMPpJBRjU8d4RXB09qtvaA==", "dev": true, "funding": [ { @@ -25206,6 +25781,10 @@ { "type": "tidelift", "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" } ], "dependencies": { @@ -25213,7 +25792,7 @@ "picocolors": "^1.0.0" }, "bin": { - "browserslist-lint": "cli.js" + "update-browserslist-db": "cli.js" }, "peerDependencies": { "browserslist": ">= 4.21.0" @@ -25573,6 +26152,24 @@ "bs58check": "<3.0.0" } }, + "node_modules/wif/node_modules/bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dependencies": { + "base-x": "^3.0.2" + } + }, + "node_modules/wif/node_modules/bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dependencies": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "node_modules/winreg": { "version": "1.2.4", "resolved": "https://registry.npmjs.org/winreg/-/winreg-1.2.4.tgz", @@ -25774,12 +26371,12 @@ "dev": true }, "node_modules/yaml": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", - "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.1.tgz", + "integrity": "sha512-e0WHiYql7+9wr4cWMx3TVQrNwejKaEe7/rHNmQmqRjazfOP5W8PB6Jpebb5o6fIapbz9o9+2ipcaTM2ZwDI6lw==", "dev": true, "engines": { - "node": ">= 6" + "node": ">= 14" } }, "node_modules/yargs": { @@ -27553,6 +28150,15 @@ "multihashes": "^2.0.0" }, "dependencies": { + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "cids": { "version": "1.1.9", "resolved": "https://registry.npmjs.org/cids/-/cids-1.1.9.tgz", @@ -28928,9 +29534,9 @@ "dev": true }, "@ledgerhq/cryptoassets": { - "version": "9.2.0", - "resolved": "https://registry.npmjs.org/@ledgerhq/cryptoassets/-/cryptoassets-9.2.0.tgz", - "integrity": "sha512-mqoyiPXOnhSTm/djoN0e01NpzcW2u5AokToFACQgVxzE+DKAEkC4nXCGegBEjjnYxa7yXc3Kykpt9qEi0/d/oA==", + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@ledgerhq/cryptoassets/-/cryptoassets-9.3.0.tgz", + "integrity": "sha512-SUhGt8mF3E1bzNUR/HBZClC4wzfdiLPuMXLZ4SlKiMgp4fvt5Qi7UImdBssHVhcw0A+lcFqs0y1uRMFDllbTWQ==", "requires": { "invariant": "2" } @@ -29257,6 +29863,26 @@ "ethereum-cryptography": "0.1.3" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29302,6 +29928,26 @@ "memory-level": "^1.0.0" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29351,6 +29997,26 @@ "ethereum-cryptography": "0.1.3" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29392,6 +30058,26 @@ "rustbn.js": "~0.2.0" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29438,6 +30124,26 @@ "functional-red-black-tree": "^1.0.1" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29475,6 +30181,26 @@ "readable-stream": "^3.6.0" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29512,6 +30238,26 @@ "ethereum-cryptography": "0.1.3" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29547,6 +30293,26 @@ "ethereum-cryptography": "0.1.3" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -29596,6 +30362,26 @@ "rustbn.js": "~0.2.0" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -30283,6 +31069,104 @@ "nullthrows": "^1.1.1", "posthtml": "^0.16.5", "svgo": "^2.4.0" + }, + "dependencies": { + "commander": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", + "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", + "dev": true + }, + "css-select": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", + "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", + "dev": true, + "requires": { + "boolbase": "^1.0.0", + "css-what": "^6.0.1", + "domhandler": "^4.3.1", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + } + }, + "css-tree": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz", + "integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==", + "dev": true, + "requires": { + "mdn-data": "2.0.14", + "source-map": "^0.6.1" + } + }, + "csso": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/csso/-/csso-4.2.0.tgz", + "integrity": "sha512-wvlcdIbf6pwKEk7vHj8/Bkc0B4ylXZruLvOgs9doS5eOsOpuodOV2zJChSpkp+pRpYQLQMeF04nr3Z68Sta9jA==", + "dev": true, + "requires": { + "css-tree": "^1.1.2" + } + }, + "dom-serializer": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", + "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", + "dev": true, + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + } + }, + "domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "dev": true, + "requires": { + "domelementtype": "^2.2.0" + } + }, + "domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "dev": true, + "requires": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + } + }, + "entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", + "dev": true + }, + "mdn-data": { + "version": "2.0.14", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", + "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", + "dev": true + }, + "svgo": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/svgo/-/svgo-2.8.0.tgz", + "integrity": "sha512-+N/Q9kV1+F+UeWYoSiULYo4xYSDQlTgb+ayMobAXPwMnLvop7oxKMo9OzIrX5x3eS4L4f2UHhc9axXwY8DpChg==", + "dev": true, + "requires": { + "@trysound/sax": "0.2.0", + "commander": "^7.2.0", + "css-select": "^4.1.3", + "css-tree": "^1.1.3", + "csso": "^4.2.0", + "picocolors": "^1.0.0", + "stable": "^0.1.8" + } + } } }, "@parcel/optimizer-image": { @@ -30308,6 +31192,104 @@ "@parcel/plugin": "2.8.3", "@parcel/utils": "2.8.3", "svgo": "^2.4.0" + }, + "dependencies": { + "commander": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", + "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", + "dev": true + }, + "css-select": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", + "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", + "dev": true, + "requires": { + "boolbase": "^1.0.0", + "css-what": "^6.0.1", + "domhandler": "^4.3.1", + "domutils": "^2.8.0", + "nth-check": "^2.0.1" + } + }, + "css-tree": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz", + "integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==", + "dev": true, + "requires": { + "mdn-data": "2.0.14", + "source-map": "^0.6.1" + } + }, + "csso": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/csso/-/csso-4.2.0.tgz", + "integrity": "sha512-wvlcdIbf6pwKEk7vHj8/Bkc0B4ylXZruLvOgs9doS5eOsOpuodOV2zJChSpkp+pRpYQLQMeF04nr3Z68Sta9jA==", + "dev": true, + "requires": { + "css-tree": "^1.1.2" + } + }, + "dom-serializer": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", + "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", + "dev": true, + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + } + }, + "domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "dev": true, + "requires": { + "domelementtype": "^2.2.0" + } + }, + "domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "dev": true, + "requires": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + } + }, + "entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", + "dev": true + }, + "mdn-data": { + "version": "2.0.14", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", + "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", + "dev": true + }, + "svgo": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/svgo/-/svgo-2.8.0.tgz", + "integrity": "sha512-+N/Q9kV1+F+UeWYoSiULYo4xYSDQlTgb+ayMobAXPwMnLvop7oxKMo9OzIrX5x3eS4L4f2UHhc9axXwY8DpChg==", + "dev": true, + "requires": { + "@trysound/sax": "0.2.0", + "commander": "^7.2.0", + "css-select": "^4.1.3", + "css-tree": "^1.1.3", + "csso": "^4.2.0", + "picocolors": "^1.0.0", + "stable": "^0.1.8" + } + } } }, "@parcel/optimizer-terser": { @@ -31439,13 +32421,15 @@ "dev": true }, "@trezor/blockchain-link": { - "version": "2.1.8", - "resolved": "https://registry.npmjs.org/@trezor/blockchain-link/-/blockchain-link-2.1.8.tgz", - "integrity": "sha512-U42+SMUTyMoxm92wETtpIkrWH2SqkG42qq9F55KHMfu1Lt6rkrxhcDjnvmgcvTjmr9qxGmKe0vPtB/l3qH0aGQ==", - "requires": { - "@trezor/utils": "^9.0.6", - "@trezor/utxo-lib": "^1.0.4", - "@types/web": "^0.0.91", + "version": "2.1.10", + "resolved": "https://registry.npmjs.org/@trezor/blockchain-link/-/blockchain-link-2.1.10.tgz", + "integrity": "sha512-MDkOVdGSUiWKD2yVtlPO0tSRs+D0NRcAuUCiOBoW2fpPpDCPCqgAbqdHDbJKtz0BGSS5J22Zw9qFeGXevE5Hgw==", + "requires": { + "@trezor/blockchain-link-types": "1.0.1", + "@trezor/blockchain-link-utils": "1.0.1", + "@trezor/utils": "9.0.7", + "@trezor/utxo-lib": "1.0.5", + "@types/web": "^0.0.99", "bignumber.js": "^9.1.1", "events": "^3.3.0", "ripple-lib": "^1.10.1", @@ -31461,6 +32445,20 @@ } } }, + "@trezor/blockchain-link-types": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@trezor/blockchain-link-types/-/blockchain-link-types-1.0.1.tgz", + "integrity": "sha512-MoH+AI0/skRuT2v/ijSmTx70xuScc5ubkkBPsDTBCxjJUR7jpAHpLRqsD6SaYLwmXa178ly7ELLlaf0nqRLHuA==" + }, + "@trezor/blockchain-link-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@trezor/blockchain-link-utils/-/blockchain-link-utils-1.0.1.tgz", + "integrity": "sha512-Yh31oVYm2JigL/pmut5+m/uLQwO0/1y7gOTyTLLHhe2EFtfWI3ztRjFZR1QcVmY4+fj9YbDZ5ngLw494xoHoUA==", + "requires": { + "@trezor/utils": "9.0.7", + "bignumber.js": "^9.1.1" + } + }, "@trezor/connect": { "version": "9.0.7", "resolved": "https://registry.npmjs.org/@trezor/connect/-/connect-9.0.7.tgz", @@ -31487,29 +32485,36 @@ "integrity": "sha512-u7hrcS3eBHzR6b2dYD1PBPYw5vWaKT5eLoEL+ykPv2DeJsq0AgdRTNQom9tTUonyHoxGdnjQuaEO2Y4j2hZeng==" }, "@trezor/transport": { - "version": "1.1.8", - "resolved": "https://registry.npmjs.org/@trezor/transport/-/transport-1.1.8.tgz", - "integrity": "sha512-Q5X0vTaZQu21PqaHL1Dnm6TVSsuK1mweMWRo2PDioDErSDlQrTMt/81gUV+HHZq/ej2m4C6YHx74pTlo2zJkfQ==", + "version": "1.1.9", + "resolved": "https://registry.npmjs.org/@trezor/transport/-/transport-1.1.9.tgz", + "integrity": "sha512-BzwVjJcRZcgpWh/db2a9paHVosUhVgV25z6RYFfzFg/GregjJiOMbofFBM1j5Xmz1JHls7H/tO3q+6dv7vRbJQ==", "requires": { - "@trezor/utils": "^9.0.6", + "@trezor/utils": "9.0.7", "bytebuffer": "^5.0.1", "json-stable-stringify": "^1.0.2", "long": "^4.0.0", - "prettier": "2.8.4", - "protobufjs": "^6.11.3" + "prettier": "2.8.7", + "protobufjs": "6.11.3" + }, + "dependencies": { + "prettier": { + "version": "2.8.7", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.7.tgz", + "integrity": "sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw==" + } } }, "@trezor/utils": { - "version": "9.0.6", - "resolved": "https://registry.npmjs.org/@trezor/utils/-/utils-9.0.6.tgz", - "integrity": "sha512-ZrZDMa1DzcfptBTdIPd7jLJGd03EVbocCSa92o64Qb6FMGSUh+t8Y+9Yy6rBPN1GTOsJxVQmcj3leKrtJMgwVQ==" + "version": "9.0.7", + "resolved": "https://registry.npmjs.org/@trezor/utils/-/utils-9.0.7.tgz", + "integrity": "sha512-EyjYqufnbtIbeN9A+RKkxh2UoGabxtZWsWubJbcyXNmQUiEFou5PRayEEG5YKav+aiWwDw2tDEJl2w1IQcSzNw==" }, "@trezor/utxo-lib": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@trezor/utxo-lib/-/utxo-lib-1.0.4.tgz", - "integrity": "sha512-n4Xj2YIpqRKaZiDZww0mcY0c2ZN+SDygR3dAJkUb7O/2FykxCS28z3QHIjfbdzMwquywbkxDeiErcdrHw3GIvg==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@trezor/utxo-lib/-/utxo-lib-1.0.5.tgz", + "integrity": "sha512-75DtK4COKftXWdNfAwudm9fVSC0bE3GSwd1wXWVrqFtiIVmwcLZohbdaVEo3Z6UqbCHWqzgiZBRfycX0EsYriw==", "requires": { - "@trezor/utils": "^9.0.6", + "@trezor/utils": "9.0.7", "bchaddrjs": "^0.5.2", "bech32": "^2.0.0", "bip66": "^1.1.5", @@ -31518,7 +32523,7 @@ "blakejs": "^1.2.1", "bn.js": "^5.2.1", "bs58": "^5.0.0", - "bs58check": "^2.1.2", + "bs58check": "^3.0.1", "create-hash": "^1.2.0", "create-hmac": "^1.1.7", "int64-buffer": "^1.0.1", @@ -31770,9 +32775,9 @@ } }, "@types/lodash": { - "version": "4.14.192", - "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.192.tgz", - "integrity": "sha512-km+Vyn3BYm5ytMO13k9KTp27O75rbQ0NFw+U//g+PX7VZyjCioXaRFisqSIJRECljcTv73G3i6BpglNGHgUQ5A==" + "version": "4.14.194", + "resolved": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.194.tgz", + "integrity": "sha512-r22s9tAS7imvBt2lyHC9B8AGwWnXaYb1tY09oyLkXDs4vArpYJzw09nj8MLx5VfciBPGIb+ZwG0ssYnEPJxn/g==" }, "@types/long": { "version": "4.0.2", @@ -31828,12 +32833,6 @@ "@types/node": "*" } }, - "@types/parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA==", - "dev": true - }, "@types/pbkdf2": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@types/pbkdf2/-/pbkdf2-3.1.0.tgz", @@ -31866,9 +32865,9 @@ "dev": true }, "@types/react": { - "version": "18.0.35", - "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.35.tgz", - "integrity": "sha512-6Laome31HpetaIUGFWl1VQ3mdSImwxtFZ39rh059a1MNnKGqBpC88J6NJ8n/Is3Qx7CefDGLgf/KhN/sYCf7ag==", + "version": "18.0.37", + "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.37.tgz", + "integrity": "sha512-4yaZZtkRN3ZIQD3KSEwkfcik8s0SWV+82dlJot1AbGYHCzJkWP3ENBY6wYeDRmKZ6HkrgoGAmR2HqdwYGp6OEw==", "dev": true, "requires": { "@types/prop-types": "*", @@ -31967,9 +32966,9 @@ "integrity": "sha512-cSjhgrr8g4KbPnnijAr/KJDNKa/bBa+ixYkywFRvrhvi9n1WEl7yYbtRyzE6jqNQiSxxJxoAW3STaOQwJHndaw==" }, "@types/web": { - "version": "0.0.91", - "resolved": "https://registry.npmjs.org/@types/web/-/web-0.0.91.tgz", - "integrity": "sha512-KIw/1SNDyzPMpN7JiS2TTmiKXUhg4vkV2b8ozgQV0aw82dZr1chPXyunxVbUjSHaDrLxQbD+xpVk+CXiVkakHg==" + "version": "0.0.99", + "resolved": "https://registry.npmjs.org/@types/web/-/web-0.0.99.tgz", + "integrity": "sha512-xMz3tOvtkZzc7RpQrDNiLe5sfMmP+fz8bOxHIZ/U8qXyvzDX4L4Ss1HCjor/O9DSelba+1iXK1VM7lruX28hiQ==" }, "@types/ws": { "version": "8.5.4", @@ -32004,6 +33003,12 @@ "@types/node": "*" } }, + "@types/zxcvbn": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@types/zxcvbn/-/zxcvbn-4.4.1.tgz", + "integrity": "sha512-3NoqvZC2W5gAC5DZbTpCeJ251vGQmgcWIHQJGq2J240HY6ErQ9aWKkwfoKJlHLx+A83WPNTZ9+3cd2ILxbvr1w==", + "dev": true + }, "@typescript-eslint/eslint-plugin": { "version": "5.54.1", "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.54.1.tgz", @@ -32155,18 +33160,6 @@ "level-transcoder": "^1.0.1", "module-error": "^1.0.1", "queue-microtask": "^1.2.3" - }, - "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "dev": true, - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - } } }, "acorn": { @@ -33114,13 +34107,22 @@ "stream-browserify": "^3.0.0" }, "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" } } } @@ -33151,18 +34153,9 @@ "integrity": "sha512-t70bfa7HYEA1D9idDbmuv7YbsbVkQ+Hp+8KFSul4aE5e/i1bjCNIRYJZlA8Q8p0r9T8cF/RVvwUgRA//FydEyg==" }, "bigint-crypto-utils": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/bigint-crypto-utils/-/bigint-crypto-utils-3.2.1.tgz", - "integrity": "sha512-/sERxP9gzXUJ7wfrFf4/oCnLc/Y87tkhi58o0zifx4VdQdLVW6OkV3X2+BxVJn1FTLpT1laG2YIbwP6ZLNut+A==", - "dev": true, - "requires": { - "bigint-mod-arith": "^3.2.0" - } - }, - "bigint-mod-arith": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/bigint-mod-arith/-/bigint-mod-arith-3.2.0.tgz", - "integrity": "sha512-Khb+sLGLqbe/2NOLVMOpCSgsC3lz8r3VIRZGc41hccudLPnvks7RYZNOnGukQZV8scn5+bA6MABga3Ueq6z3+w==", + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/bigint-crypto-utils/-/bigint-crypto-utils-3.2.2.tgz", + "integrity": "sha512-U1RbE3aX9ayCUVcIPHuPDPKcK3SFOXf93J1UK/iHlJuQB7bhagPIX06/CLpLEsDThJ7KA4Dhrnzynl+d2weTiw==", "dev": true }, "bignumber.js": { @@ -33230,17 +34223,6 @@ "buffer": "^6.0.3", "inherits": "^2.0.4", "readable-stream": "^3.4.0" - }, - "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - } } }, "blake-hash": { @@ -33312,6 +34294,15 @@ "readable-stream": "^3.6.0" }, "dependencies": { + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "commander": { "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", @@ -33420,23 +34411,12 @@ } }, "bs58check": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", - "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-3.0.1.tgz", + "integrity": "sha512-hjuuJvoWEybo7Hn/0xOrczQKKEKD63WguEjlhLExYs2wUBcebDC1jDNK17eEAD2lYfw82d5ASC1d7K3SWszjaQ==", "requires": { - "bs58": "^4.0.0", - "create-hash": "^1.1.0", - "safe-buffer": "^5.1.2" - }, - "dependencies": { - "bs58": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", - "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", - "requires": { - "base-x": "^3.0.2" - } - } + "@noble/hashes": "^1.2.0", + "bs58": "^5.0.0" } }, "bser": { @@ -33449,12 +34429,12 @@ } }, "buffer": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", - "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", "requires": { "base64-js": "^1.3.1", - "ieee754": "^1.1.13" + "ieee754": "^1.2.1" } }, "buffer-alloc": { @@ -33789,9 +34769,9 @@ "integrity": "sha512-dU+Tx2fsypxTgtLoE36npi3UqcjSSMNYfkqgmoEhtZrraP5VWq0K7FkWVTYa8eMPtnU/G2txVsfdCJTn9uzpuQ==" }, "caniuse-lite": { - "version": "1.0.30001478", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001478.tgz", - "integrity": "sha512-gMhDyXGItTHipJj2ApIvR+iVB5hd0KP3svMWWXDvZOmjzJJassGLMfxRkQCSYgGd2gtdL/ReeiyvMSFD1Ss6Mw==", + "version": "1.0.30001480", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001480.tgz", + "integrity": "sha512-q7cpoPPvZYgtyC4VaBSN0Bt+PJ4c4EYRf0DrduInOz2SkFpHD5p3LnvEpqBp7UnJn+8x1Ogl1s38saUxe+ihQQ==", "dev": true }, "case": { @@ -33937,6 +34917,15 @@ "multihashes": "~0.4.15" }, "dependencies": { + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "multicodec": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/multicodec/-/multicodec-1.0.4.tgz", @@ -34105,9 +35094,9 @@ "dev": true }, "colorette": { - "version": "2.0.19", - "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.19.tgz", - "integrity": "sha512-3tlv/dIP7FWvj3BsbHrGLJ6l/oKh1O3TcgBqMn+yyCagOxc23fyzDS6HypQbgxWbkpDnf52p1LuR4eWDQ/K9WQ==", + "version": "2.0.20", + "resolved": "https://registry.npmjs.org/colorette/-/colorette-2.0.20.tgz", + "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", "dev": true }, "colors": { @@ -34210,15 +35199,15 @@ "integrity": "sha512-LDx6oHrK+PhzLKJU9j5S7/Y3jM/mUHvD/DeI1WQmJn652iPC5Y4TBzC9l+5OMOXlyTTA+SmVUPm0HQUwpD5Jqw==" }, "core-js": { - "version": "3.30.0", - "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.30.0.tgz", - "integrity": "sha512-hQotSSARoNh1mYPi9O2YaWeiq/cEB95kOrFb4NCrO4RIFt1qqNpKsaE+vy/L3oiqvND5cThqXzUU3r9F7Efztg==", + "version": "3.30.1", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.30.1.tgz", + "integrity": "sha512-ZNS5nbiSwDTq4hFosEDqm65izl2CWmLz0hARJMyNQBgkUZMIF51cQiMvIQKA6hvuaeWxQDP3hEedM1JZIgTldQ==", "dev": true }, "core-js-compat": { - "version": "3.30.0", - "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.30.0.tgz", - "integrity": "sha512-P5A2h/9mRYZFIAP+5Ab8ns6083IyVpSclU74UNvbGVQ8VM7n3n3/g2yF3AkKQ9NXz2O+ioxLbEWKnDtgsFamhg==", + "version": "3.30.1", + "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.30.1.tgz", + "integrity": "sha512-d690npR7MC6P0gq4npTl5n2VQeNAmUrJ90n+MHiKS7W2+xno4o3F5GDEuylSdi6EJ3VssibSGXOa1r3YXD3Mhw==", "dev": true, "requires": { "browserslist": "^4.21.5" @@ -34230,16 +35219,15 @@ "integrity": "sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==" }, "cosmiconfig": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-7.1.0.tgz", - "integrity": "sha512-AdmX6xUzdNASswsFtmwSt7Vj8po9IuqXm0UXz7QKPuEUmPB4XyjGfaAr2PSuELMwkRMVH1EpIkX5bTZGRB3eCA==", + "version": "8.1.3", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.1.3.tgz", + "integrity": "sha512-/UkO2JKI18b5jVMJUp0lvKFMpa/Gye+ZgZjKD+DGEN9y7NRcf/nK1A0sp67ONmKtnDCNMS44E6jrk0Yc3bDuUw==", "dev": true, "requires": { - "@types/parse-json": "^4.0.0", "import-fresh": "^3.2.1", + "js-yaml": "^4.1.0", "parse-json": "^5.0.0", - "path-type": "^4.0.0", - "yaml": "^1.10.0" + "path-type": "^4.0.0" } }, "crc": { @@ -34250,6 +35238,19 @@ "optional": true, "requires": { "buffer": "^5.1.0" + }, + "dependencies": { + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "dev": true, + "optional": true, + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + } } }, "crc-32": { @@ -34376,13 +35377,15 @@ } }, "css-tree": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-1.1.3.tgz", - "integrity": "sha512-tRpdppF7TRazZrjJ6v3stzv93qxRcSsFmW6cX0Zm2NVKpxE1WV1HblnghVv9TreireHkqI/VDEsfolRF1p6y7Q==", + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.3.1.tgz", + "integrity": "sha512-6Fv1DV/TYw//QF5IzQdqsNDjx/wc8TrMBZsqjL9eW01tWb7R7k/mq+/VXfJCl7SoD5emsJop9cOByJZfs8hYIw==", "dev": true, + "optional": true, + "peer": true, "requires": { - "mdn-data": "2.0.14", - "source-map": "^0.6.1" + "mdn-data": "2.0.30", + "source-map-js": "^1.0.1" } }, "css-what": { @@ -34391,12 +35394,36 @@ "integrity": "sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==" }, "csso": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/csso/-/csso-4.2.0.tgz", - "integrity": "sha512-wvlcdIbf6pwKEk7vHj8/Bkc0B4ylXZruLvOgs9doS5eOsOpuodOV2zJChSpkp+pRpYQLQMeF04nr3Z68Sta9jA==", + "version": "5.0.5", + "resolved": "https://registry.npmjs.org/csso/-/csso-5.0.5.tgz", + "integrity": "sha512-0LrrStPOdJj+SPCCrGhzryycLjwcgUSHBtxNA8aIDxf0GLsRh1cKYhB00Gd1lDOS4yGH69+SNn13+TWbVHETFQ==", "dev": true, + "optional": true, + "peer": true, "requires": { - "css-tree": "^1.1.2" + "css-tree": "~2.2.0" + }, + "dependencies": { + "css-tree": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/css-tree/-/css-tree-2.2.1.tgz", + "integrity": "sha512-OA0mILzGc1kCOCSJerOeqDxDQ4HOh+G8NbOJFOTgOCzpw7fCBubk0fEyxp8AgOL/jvLgYA/uV0cMbe43ElF1JA==", + "dev": true, + "optional": true, + "peer": true, + "requires": { + "mdn-data": "2.0.28", + "source-map-js": "^1.0.1" + } + }, + "mdn-data": { + "version": "2.0.28", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.28.tgz", + "integrity": "sha512-aylIc7Z9y4yzHYAJNuESG3hfhC+0Ibp/MAMiaOZgNv4pmEdFyfZhhhny4MNiAfWdBQ1RQ2mfDWmM1x8SvGyp8g==", + "dev": true, + "optional": true, + "peer": true + } } }, "cssom": { @@ -34886,9 +35913,9 @@ }, "dependencies": { "@types/node": { - "version": "16.18.23", - "resolved": "https://registry.npmjs.org/@types/node/-/node-16.18.23.tgz", - "integrity": "sha512-XAMpaw1s1+6zM+jn2tmw8MyaRDIJfXxqmIQIS0HfoGYPuf7dUWeiUKopwq13KFX9lEp1+THGtlaaYx39Nxr58g==", + "version": "16.18.24", + "resolved": "https://registry.npmjs.org/@types/node/-/node-16.18.24.tgz", + "integrity": "sha512-zvSN2Esek1aeLdKDYuntKAYjti9Z2oT4I8bfkLLhIxHlv3dwZ5vvATxOc31820iYm4hQRCwjUgDpwSMFjfTUnw==", "dev": true } } @@ -35161,9 +36188,9 @@ } }, "electron-to-chromium": { - "version": "1.4.361", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.361.tgz", - "integrity": "sha512-VocVwjPp05HUXzf3xmL0boRn5b0iyqC7amtDww84Jb1QJNPBc7F69gJyEeXRoriLBC4a5pSyckdllrXAg4mmRA==", + "version": "1.4.368", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.368.tgz", + "integrity": "sha512-e2aeCAixCj9M7nJxdB/wDjO6mbYX+lJJxSJCXDzlr5YPGYVofuJwGN9nKg2o6wWInjX6XmxRinn3AeJMK81ltw==", "dev": true }, "electron-updater": { @@ -35258,9 +36285,9 @@ } }, "entities": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.4.0.tgz", - "integrity": "sha512-oYp7156SP8LkeGD0GF85ad1X9Ai79WtRsZ2gxJqtBuzH+98YUV6jkHEKlZkMbcrjJjIVJNIDP/3WL9wQkoPbWA==" + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", + "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==" }, "env-paths": { "version": "2.2.1", @@ -35552,9 +36579,9 @@ "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" }, "eslint-scope": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.1.tgz", - "integrity": "sha512-QKQM/UXpIiHcLqJ5AOyIW7XZmzjkzQXYE54n1++wb0u9V/abW3l9uQnxX8Z5Xd18xyKIMTUAyQ0k1e8pz6LUrw==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", + "integrity": "sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==", "requires": { "esrecurse": "^4.3.0", "estraverse": "^5.2.0" @@ -35751,17 +36778,6 @@ "bn.js": ">4.0.0", "buffer": "^6.0.3", "js-sha3": "^0.8.0" - }, - "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - } } }, "eth-ens-namehash": { @@ -35852,6 +36868,26 @@ "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", "dev": true }, + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -35921,6 +36957,24 @@ "rlp": "^2.2.4" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -35968,6 +37022,24 @@ "uuid": "^8.3.2" }, "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "ethereum-cryptography": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-0.1.3.tgz", @@ -36661,6 +37733,33 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/bech32/-/bech32-2.0.0.tgz", "integrity": "sha512-LcknSilhIGatDAsY1ak2I8VtGaHNhgMSYVxFrGLXv+xLHytaKZKcaUJJUE7qmBr7h33o5YQwP55pMI0xmkpJwg==" + }, + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } } } }, @@ -36828,6 +37927,26 @@ "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==", "dev": true }, + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "dev": true, + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "dev": true, + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + }, "cookie": { "version": "0.4.2", "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.2.tgz", @@ -37119,6 +38238,26 @@ "ripemd160": "^2.0.2", "safe-buffer": "^5.1.1", "secp256k1": "^4.0.0" + }, + "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + } } }, "he": { @@ -37217,12 +38356,12 @@ "dev": true }, "htmlnano": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/htmlnano/-/htmlnano-2.0.3.tgz", - "integrity": "sha512-S4PGGj9RbdgW8LhbILNK7W9JhmYP8zmDY7KDV/8eCiJBQJlbmltp5I0gv8c5ntLljfdxxfmJ+UJVSqyH4mb41A==", + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/htmlnano/-/htmlnano-2.0.4.tgz", + "integrity": "sha512-WGCkyGFwjKW1GeCBsPYacMvaMnZtFJ0zIRnC2NCddkA+IOEhTqskXrS7lep+3yYZw/nQ3dW1UAX4yA/GJyR8BA==", "dev": true, "requires": { - "cosmiconfig": "^7.0.1", + "cosmiconfig": "^8.0.0", "posthtml": "^0.16.5", "timsort": "^0.3.0" } @@ -37679,15 +38818,6 @@ "stream-to-it": "^0.2.2" }, "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - }, "iso-url": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/iso-url/-/iso-url-1.2.1.tgz", @@ -38237,17 +39367,6 @@ "p-defer": "^3.0.0", "p-fifo": "^1.0.0", "readable-stream": "^3.6.0" - }, - "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - } } }, "jake": { @@ -40010,18 +41129,6 @@ "requires": { "buffer": "^6.0.3", "module-error": "^1.0.1" - }, - "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "dev": true, - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - } } }, "leven": { @@ -40049,75 +41156,75 @@ } }, "lightningcss": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.19.0.tgz", - "integrity": "sha512-yV5UR7og+Og7lQC+70DA7a8ta1uiOPnWPJfxa0wnxylev5qfo4P+4iMpzWAdYWOca4jdNQZii+bDL/l+4hUXIA==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.20.0.tgz", + "integrity": "sha512-4bj8aP+Vi+or8Gwq/hknmicr4PmA8D9uL/3qY0N0daX5vYBMYERGI6Y93nzoeRgQMULq+gtrN/FvJYtH0xNN8g==", "dev": true, "requires": { "detect-libc": "^1.0.3", - "lightningcss-darwin-arm64": "1.19.0", - "lightningcss-darwin-x64": "1.19.0", - "lightningcss-linux-arm-gnueabihf": "1.19.0", - "lightningcss-linux-arm64-gnu": "1.19.0", - "lightningcss-linux-arm64-musl": "1.19.0", - "lightningcss-linux-x64-gnu": "1.19.0", - "lightningcss-linux-x64-musl": "1.19.0", - "lightningcss-win32-x64-msvc": "1.19.0" + "lightningcss-darwin-arm64": "1.20.0", + "lightningcss-darwin-x64": "1.20.0", + "lightningcss-linux-arm-gnueabihf": "1.20.0", + "lightningcss-linux-arm64-gnu": "1.20.0", + "lightningcss-linux-arm64-musl": "1.20.0", + "lightningcss-linux-x64-gnu": "1.20.0", + "lightningcss-linux-x64-musl": "1.20.0", + "lightningcss-win32-x64-msvc": "1.20.0" } }, "lightningcss-darwin-arm64": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.19.0.tgz", - "integrity": "sha512-wIJmFtYX0rXHsXHSr4+sC5clwblEMji7HHQ4Ub1/CznVRxtCFha6JIt5JZaNf8vQrfdZnBxLLC6R8pC818jXqg==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.20.0.tgz", + "integrity": "sha512-aYEohJTlzwB8URJaNiS57tMbjyLub0mYvxlxKQk8SZv+irXx6MoBWpDNQKKTS9gg1pGf/eAwjpa3BLAoCBsh1A==", "dev": true, "optional": true }, "lightningcss-darwin-x64": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.19.0.tgz", - "integrity": "sha512-Lif1wD6P4poaw9c/4Uh2z+gmrWhw/HtXFoeZ3bEsv6Ia4tt8rOJBdkfVaUJ6VXmpKHALve+iTyP2+50xY1wKPw==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.20.0.tgz", + "integrity": "sha512-cmMgY8FFWVaGgtift7eKKkHMqlz9O09/yTdlCXEDOeDP9yeo6vHOBTRP7ojb368kjw8Ew3l0L2uT1Gtx56eNkg==", "dev": true, "optional": true }, "lightningcss-linux-arm-gnueabihf": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.19.0.tgz", - "integrity": "sha512-P15VXY5682mTXaiDtbnLYQflc8BYb774j2R84FgDLJTN6Qp0ZjWEFyN1SPqyfTj2B2TFjRHRUvQSSZ7qN4Weig==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.20.0.tgz", + "integrity": "sha512-/m+NDO1O6JCv7R9F0XWlXcintQHx4MPNU+kt8jZJO07LLdGwCfvjN31GVcwVPlStnnx/cU8uTTmax6g/Qu/whg==", "dev": true, "optional": true }, "lightningcss-linux-arm64-gnu": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.19.0.tgz", - "integrity": "sha512-zwXRjWqpev8wqO0sv0M1aM1PpjHz6RVIsBcxKszIG83Befuh4yNysjgHVplF9RTU7eozGe3Ts7r6we1+Qkqsww==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.20.0.tgz", + "integrity": "sha512-gtXoa6v0HvMRLbev6Hsef0+Q5He7NslB+Rs7G49Y5LUSdJeGIATEN+j8JzHC0DnxCsOGbEgGRmvtJzzYDkkluw==", "dev": true, "optional": true }, "lightningcss-linux-arm64-musl": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.19.0.tgz", - "integrity": "sha512-vSCKO7SDnZaFN9zEloKSZM5/kC5gbzUjoJQ43BvUpyTFUX7ACs/mDfl2Eq6fdz2+uWhUh7vf92c4EaaP4udEtA==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.20.0.tgz", + "integrity": "sha512-Po7XpucM1kZnkiyd2BNwTExSDcZ8jm8uB9u+Sq44qjpkf5f75jreQwn3DQm9I1t5C6tB9HGt30HExMju9umJBQ==", "dev": true, "optional": true }, "lightningcss-linux-x64-gnu": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.19.0.tgz", - "integrity": "sha512-0AFQKvVzXf9byrXUq9z0anMGLdZJS+XSDqidyijI5njIwj6MdbvX2UZK/c4FfNmeRa2N/8ngTffoIuOUit5eIQ==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.20.0.tgz", + "integrity": "sha512-8yR/fGNn/P0I+Lc3PK+VWPET/zdSpBfHFIG0DJ38TywMbItVKvnFvoTBwnIm4LqBz7g2G2dDexnNP95za2Ll8g==", "dev": true, "optional": true }, "lightningcss-linux-x64-musl": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.19.0.tgz", - "integrity": "sha512-SJoM8CLPt6ECCgSuWe+g0qo8dqQYVcPiW2s19dxkmSI5+Uu1GIRzyKA0b7QqmEXolA+oSJhQqCmJpzjY4CuZAg==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.20.0.tgz", + "integrity": "sha512-EmpJ+VkPZ8RACiB4m+l8TmapmE1W2UvJKDHE+ML/3Ihr9tRKUs3CibfnQTFZC8aSsrxgXagDAN+PgCDDhIyriA==", "dev": true, "optional": true }, "lightningcss-win32-x64-msvc": { - "version": "1.19.0", - "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.19.0.tgz", - "integrity": "sha512-C+VuUTeSUOAaBZZOPT7Etn/agx/MatzJzGRkeV+zEABmPuntv1zihncsi+AyGmjkkzq3wVedEy7h0/4S84mUtg==", + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.20.0.tgz", + "integrity": "sha512-BRdPvbq7Cc1qxAzp2emqWJHrqsEkf4ggxS29VOnxT7jhkdHKU+a26OVMjvm/OL0NH0ToNOZNAPvHMSexiEgBeA==", "dev": true, "optional": true }, @@ -40294,12 +41401,6 @@ "resolved": "https://registry.npmjs.org/strip-final-newline/-/strip-final-newline-3.0.0.tgz", "integrity": "sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==", "dev": true - }, - "yaml": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.1.tgz", - "integrity": "sha512-e0WHiYql7+9wr4cWMx3TVQrNwejKaEe7/rHNmQmqRjazfOP5W8PB6Jpebb5o6fIapbz9o9+2ipcaTM2ZwDI6lw==", - "dev": true } } }, @@ -40682,10 +41783,12 @@ } }, "mdn-data": { - "version": "2.0.14", - "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.14.tgz", - "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", - "dev": true + "version": "2.0.30", + "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.30.tgz", + "integrity": "sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==", + "dev": true, + "optional": true, + "peer": true }, "memory-level": { "version": "1.0.0", @@ -41080,6 +42183,17 @@ "requires": { "base-x": "^3.0.8", "buffer": "^5.5.0" + }, + "dependencies": { + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + } } }, "multicodec": { @@ -41105,6 +42219,15 @@ "varint": "^5.0.0" }, "dependencies": { + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, "multibase": { "version": "0.7.0", "resolved": "https://registry.npmjs.org/multibase/-/multibase-0.7.0.tgz", @@ -41614,15 +42737,16 @@ } }, "object.getownpropertydescriptors": { - "version": "2.1.5", - "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.5.tgz", - "integrity": "sha512-yDNzckpM6ntyQiGTik1fKV1DcVDRS+w8bvpWNCBanvH5LfRX9O8WTHqQzG4RZwRAM4I0oU7TV11Lj5v0g20ibw==", + "version": "2.1.6", + "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.6.tgz", + "integrity": "sha512-lq+61g26E/BgHv0ZTFgRvi7NMEPuAxLkFU7rukXjc/AlwH4Am5xXVnIXy3un1bg/JPbXHrixRkK1itUzzPiIjQ==", "dev": true, "requires": { "array.prototype.reduce": "^1.0.5", "call-bind": "^1.0.2", - "define-properties": "^1.1.4", - "es-abstract": "^1.20.4" + "define-properties": "^1.2.0", + "es-abstract": "^1.21.2", + "safe-array-concat": "^1.0.0" } }, "object.hasown": { @@ -41942,9 +43066,9 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" }, "path-scurry": { - "version": "1.6.4", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.6.4.tgz", - "integrity": "sha512-Qp/9IHkdNiXJ3/Kon++At2nVpnhRiPq/aSvQN+H3U1WZbvNRK0RIQK/o4HMqPoXjpuGJUEWpHSs6Mnjxqh3TQg==", + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.7.0.tgz", + "integrity": "sha512-UkZUeDjczjYRE495+9thsgcVgsaCPkaw80slmfVFgllxY+IO8ubTsOpFVjDPROBqJdHfVPUFRHPBV/WciOVfWg==", "dev": true, "requires": { "lru-cache": "^9.0.0", @@ -41952,9 +43076,9 @@ }, "dependencies": { "lru-cache": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-9.0.1.tgz", - "integrity": "sha512-C8QsKIN1UIXeOs3iWmiZ1lQY+EnKDojWd37fXy1aSbJvH4iSma1uy2OWuoB3m4SYRli5+CUjDv3Dij5DVoetmg==", + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-9.1.0.tgz", + "integrity": "sha512-qFXQEwchrZcMVen2uIDceR8Tii6kCJak5rzDStfEM0qA3YLMswaxIEZO0DhIbJ3aqaJiDjt+3crlplOb0tDtKQ==", "dev": true }, "minipass": { @@ -42333,7 +43457,8 @@ "prettier": { "version": "2.8.4", "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.8.4.tgz", - "integrity": "sha512-vIS4Rlc2FNh0BySk3Wkd6xmwxB0FpOndW5fisM5H8hsZSxU2VWVB5CWIkIjWvrHjIhxk2g3bfMKM87zNTrZddw==" + "integrity": "sha512-vIS4Rlc2FNh0BySk3Wkd6xmwxB0FpOndW5fisM5H8hsZSxU2VWVB5CWIkIjWvrHjIhxk2g3bfMKM87zNTrZddw==", + "dev": true }, "pretty-format": { "version": "27.5.1", @@ -42759,13 +43884,13 @@ } }, "regexp.prototype.flags": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz", - "integrity": "sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA==", + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz", + "integrity": "sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA==", "requires": { "call-bind": "^1.0.2", - "define-properties": "^1.1.3", - "functions-have-names": "^1.2.2" + "define-properties": "^1.2.0", + "functions-have-names": "^1.2.3" } }, "regexpp": { @@ -43189,6 +44314,18 @@ } } }, + "safe-array-concat": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.0.tgz", + "integrity": "sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ==", + "dev": true, + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + } + }, "safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", @@ -43358,17 +44495,6 @@ "integrity": "sha512-S8cNxbyb0UGUM2VhRD4Poe5N58gJnJsLJ5vC7FYWGUmGhcsj4++WaIOBFVDxlG0W3To6xBuiRh+i0Qp2oNCOtg==", "requires": { "buffer": "6.0.3" - }, - "dependencies": { - "buffer": { - "version": "6.0.3", - "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", - "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", - "requires": { - "base64-js": "^1.3.1", - "ieee754": "^1.2.1" - } - } } }, "shallow-clone": { @@ -43623,6 +44749,14 @@ "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", "dev": true }, + "source-map-js": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", + "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", + "dev": true, + "optional": true, + "peer": true + }, "source-map-resolve": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.6.0.tgz", @@ -43969,75 +45103,28 @@ "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==" }, "svgo": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/svgo/-/svgo-2.8.0.tgz", - "integrity": "sha512-+N/Q9kV1+F+UeWYoSiULYo4xYSDQlTgb+ayMobAXPwMnLvop7oxKMo9OzIrX5x3eS4L4f2UHhc9axXwY8DpChg==", + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/svgo/-/svgo-3.0.2.tgz", + "integrity": "sha512-Z706C1U2pb1+JGP48fbazf3KxHrWOsLme6Rv7imFBn5EnuanDW1GPaA/P1/dvObE670JDePC3mnj0k0B7P0jjQ==", "dev": true, + "optional": true, + "peer": true, "requires": { "@trysound/sax": "0.2.0", "commander": "^7.2.0", - "css-select": "^4.1.3", - "css-tree": "^1.1.3", - "csso": "^4.2.0", - "picocolors": "^1.0.0", - "stable": "^0.1.8" + "css-select": "^5.1.0", + "css-tree": "^2.2.1", + "csso": "^5.0.5", + "picocolors": "^1.0.0" }, "dependencies": { "commander": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", "integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==", - "dev": true - }, - "css-select": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/css-select/-/css-select-4.3.0.tgz", - "integrity": "sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==", "dev": true, - "requires": { - "boolbase": "^1.0.0", - "css-what": "^6.0.1", - "domhandler": "^4.3.1", - "domutils": "^2.8.0", - "nth-check": "^2.0.1" - } - }, - "dom-serializer": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", - "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", - "dev": true, - "requires": { - "domelementtype": "^2.0.1", - "domhandler": "^4.2.0", - "entities": "^2.0.0" - } - }, - "domhandler": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", - "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", - "dev": true, - "requires": { - "domelementtype": "^2.2.0" - } - }, - "domutils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", - "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", - "dev": true, - "requires": { - "dom-serializer": "^1.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0" - } - }, - "entities": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", - "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", - "dev": true + "optional": true, + "peer": true } } }, @@ -44120,6 +45207,15 @@ "inherits": "^2.0.4", "readable-stream": "^3.4.0" } + }, + "buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } } } }, @@ -44153,9 +45249,9 @@ "dev": true }, "terser": { - "version": "5.16.9", - "resolved": "https://registry.npmjs.org/terser/-/terser-5.16.9.tgz", - "integrity": "sha512-HPa/FdTB9XGI2H1/keLFZHxl6WNvAI4YalHGtDQTlMnJcoqSab1UwL4l1hGEhs6/GmLHBZIg/YgB++jcbzoOEg==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.17.1.tgz", + "integrity": "sha512-hVl35zClmpisy6oaoKALOpS0rDYLxRFLHhRuDlEGTKey9qHjS1w9GMORjuwIMt70Wan4lwsLYyWDVnWgF+KUEw==", "dev": true, "requires": { "@jridgewell/source-map": "^0.3.2", @@ -44502,9 +45598,9 @@ } }, "undici": { - "version": "5.21.2", - "resolved": "https://registry.npmjs.org/undici/-/undici-5.21.2.tgz", - "integrity": "sha512-f6pTQ9RF4DQtwoWSaC42P/NKlUjvezVvd9r155ohqkwFNRyBKM3f3pcty3ouusefNRyM25XhIQEbeQ46sZDJfQ==", + "version": "5.22.0", + "resolved": "https://registry.npmjs.org/undici/-/undici-5.22.0.tgz", + "integrity": "sha512-fR9RXCc+6Dxav4P9VV/sp5w3eFiSdOjJYsbtWfd4s5L5C4ogyuVpdKIVHeW0vV1MloM65/f7W45nR9ZxwVdyiA==", "dev": true, "requires": { "busboy": "^1.6.0" @@ -44589,9 +45685,9 @@ } }, "update-browserslist-db": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.10.tgz", - "integrity": "sha512-OztqDenkfFkbSG+tRxBeAnCVPckDBcvibKd35yDONx6OU8N7sqgwc7rCbkJ/WcYtVRZ4ba68d6byhC21GFh7sQ==", + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.11.tgz", + "integrity": "sha512-dCwEFf0/oT85M1fHBg4F0jtLwJrutGoHSQXCh7u4o2t1drG+c0a9Flnqww6XUKSfQMPpJBRjU8d4RXB09qtvaA==", "dev": true, "requires": { "escalade": "^3.1.1", @@ -44891,6 +45987,26 @@ "integrity": "sha512-HIanZn1zmduSF+BQhkE+YXIbEiH0xPr1012QbFEGB0xsKqJii0/SqJjyn8dFv6y36kOznMgMB+LGcbZTJ1xACQ==", "requires": { "bs58check": "<3.0.0" + }, + "dependencies": { + "bs58": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/bs58/-/bs58-4.0.1.tgz", + "integrity": "sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==", + "requires": { + "base-x": "^3.0.2" + } + }, + "bs58check": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/bs58check/-/bs58check-2.1.2.tgz", + "integrity": "sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==", + "requires": { + "bs58": "^4.0.0", + "create-hash": "^1.1.0", + "safe-buffer": "^5.1.2" + } + } } }, "winreg": { @@ -45046,9 +46162,9 @@ "dev": true }, "yaml": { - "version": "1.10.2", - "resolved": "https://registry.npmjs.org/yaml/-/yaml-1.10.2.tgz", - "integrity": "sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.2.1.tgz", + "integrity": "sha512-e0WHiYql7+9wr4cWMx3TVQrNwejKaEe7/rHNmQmqRjazfOP5W8PB6Jpebb5o6fIapbz9o9+2ipcaTM2ZwDI6lw==", "dev": true }, "yargs": { diff --git a/package.json b/package.json index 3998012a6..9e9e38b3e 100644 --- a/package.json +++ b/package.json @@ -152,6 +152,7 @@ "@types/tar-fs": "2.0.1", "@types/uuid": "9.0.1", "@types/ws": "8.5.4", + "@types/zxcvbn": "4.4.1", "@typescript-eslint/eslint-plugin": "5.54.1", "@typescript-eslint/parser": "5.54.1", "electron": "23.1.3", diff --git a/resources/utils/index.ts b/resources/utils/index.ts index 49b0f400d..b5fd95981 100644 --- a/resources/utils/index.ts +++ b/resources/utils/index.ts @@ -41,6 +41,10 @@ function debounce(func: (...args: any) => any, timeout = 300) { } } +async function wait(ms: number) { + return new Promise((resolve) => setTimeout(resolve, ms)) +} + function instanceOfNodeError( value: Error, errorType: T @@ -90,6 +94,7 @@ export { arraysEqual, arraysMatch, debounce, + wait, weiToGwei, weiToHex, gweiToWei, diff --git a/test/main/signers/hot/HotSigner/controller.test.js b/test/main/signers/hot/HotSigner/controller.test.js new file mode 100644 index 000000000..44e3a03df --- /dev/null +++ b/test/main/signers/hot/HotSigner/controller.test.js @@ -0,0 +1,94 @@ +import EventEmitter from 'events' +import crypto from 'crypto' + +import createController from '../../../../../main/signers/hot/HotSigner/worker/controller' + +let ipc, worker, token + +beforeEach(() => { + ipc = new EventEmitter() + ipc.send = jest.fn() + + worker = { + signMessage: jest.fn(), + handleMessage: jest.fn() + } + + createController(worker, ipc) + + token = ipc.send.mock.calls[0][0].token + expect(token).toMatch(/^[A-Za-z0-9]{64}$/) + + ipc.send.mockClear() +}) + +afterEach(() => { + ipc.removeAllListeners() +}) + +it('does not handle a message with an invalid token', () => { + ipc.emit('message', { + id: 1, + method: 'signMessage', + params: [], + token: crypto.randomBytes(32).toString('hex') + }) + + expect(ipc.send).toHaveBeenCalledWith({ id: 1, type: 'rpc', error: 'Invalid token', result: undefined }) +}) + +it('verifies an address on the signer worker', () => { + ipc.emit('message', { + id: 1, + method: 'verifyAddress', + params: { index: 0, address: '' }, + token + }) + + expect(worker.handleMessage).toHaveBeenCalledWith(expect.any(Function), 'signMessage', { + index: 0, + message: expect.stringMatching(/^0x[A-Za-z0-9]{64}$/) + }) +}) + +it('dispatches a message to the signer worker for handling', () => { + const tx = { chainId: '0x5', from: 'someone' } + + ipc.emit('message', { + id: 2, + method: 'signTransaction', + params: { index: 5, rawTx: tx }, + token + }) + + expect(worker.handleMessage).toHaveBeenCalledWith(expect.any(Function), 'signTransaction', { + index: 5, + rawTx: tx + }) +}) + +it('returns the result after the signer worker handles a message', () => { + worker.handleMessage.mockImplementation((cb) => cb(null, 'txsignature')) + + ipc.emit('message', { + id: 2, + method: 'signTypedData', + params: { index: 8, message: 'signme' }, + token + }) + + expect(ipc.send).toHaveBeenCalledWith({ id: 2, type: 'rpc', error: undefined, result: 'txsignature' }) +}) + +it('returns an error after the signer worker cannot handle a message', () => { + worker.handleMessage.mockImplementation((cb) => cb('Invalid method')) + + ipc.emit('message', { + id: 2, + method: 'sendRawTransaction', + params: { index: 8, message: 'signme' }, + token + }) + + expect(ipc.send).toHaveBeenCalledWith({ id: 2, type: 'rpc', error: 'Invalid method', result: undefined }) +}) diff --git a/test/main/signers/hot/RingSigner/index.test.js b/test/main/signers/hot/RingSigner/index.test.js index 116a53f4f..5d7e9db30 100644 --- a/test/main/signers/hot/RingSigner/index.test.js +++ b/test/main/signers/hot/RingSigner/index.test.js @@ -4,10 +4,31 @@ import crypto from 'crypto' import { remove } from 'fs-extra' import log from 'electron-log' +import hot from '../../../../../main/signers/hot' + const PASSWORD = 'fr@///3_password' const SIGNER_PATH = path.resolve(__dirname, '../.userData/signers') const FILE_PATH = path.resolve(__dirname, 'keystore.json') +jest.mock('path', () => { + const original = jest.requireActual('path') + + return { + ...original, + resolve: (...args) => { + // TODO: this can be cleaned up once tests are re-worked + if (args.includes('worker/launch.js')) { + return original.resolve( + __dirname, + '../../../../../compiled/main/signers/hot/HotSigner/worker/launch.js' + ) + } + + return original.resolve(...args) + } + } +}) + jest.mock('electron') jest.mock('../../../../../main/store/persist') @@ -16,7 +37,7 @@ const signers = { add: () => {} } // Util const clean = () => remove(SIGNER_PATH) -let hot, store +let store describe('Ring signer', () => { let signer @@ -26,7 +47,6 @@ describe('Ring signer', () => { clean() - hot = await import('../../../../../main/signers/hot') store = require('../../../../../main/store').default }) diff --git a/test/main/signers/hot/HotSigner/worker.test.js b/test/main/signers/hot/RingSigner/worker.test.js similarity index 86% rename from test/main/signers/hot/HotSigner/worker.test.js rename to test/main/signers/hot/RingSigner/worker.test.js index ec9de7cf3..a16b73921 100644 --- a/test/main/signers/hot/HotSigner/worker.test.js +++ b/test/main/signers/hot/RingSigner/worker.test.js @@ -1,9 +1,11 @@ -import HotSignerWorker from '../../../../../main/signers/hot/HotSigner/worker' +import RingSignerWorker from '../../../../../main/signers/hot/RingSigner/worker' let worker // mnemonic: test test test test test test test test test test test junk -const key = Buffer.from('4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356', 'hex') +const key = '4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356' +const password = 'afr@metest!' + let errorOutput = console.error beforeAll(() => { @@ -15,8 +17,14 @@ afterAll(() => { console.error = errorOutput }) -beforeEach(() => { - worker = new HotSignerWorker() +beforeEach((done) => { + worker = new RingSignerWorker() + + const unlockCb = (err, encryptedKeys) => { + worker.unlock(done, { encryptedSecret: encryptedKeys, password }) + } + + worker.addKey(unlockCb, { key, password }) }) describe('#signTransaction', () => { @@ -91,7 +99,7 @@ describe('#signTransaction', () => { it(`signs a transaction on ${chain.name}`, (done) => { const tx = { ...rawTx, chainId: chain.chainId.toString(16) } - worker.signTransaction(key, tx, (err, signature) => { + const cb = (err, signature) => { try { expect(err).toBe(null) expect(signature).toBe(chain.expectedSignature) @@ -99,20 +107,24 @@ describe('#signTransaction', () => { } catch (e) { done(e) } - }) + } + + worker.signTransaction(cb, { index: 0, rawTx: tx }) }, 200) }) it('rejects a transaction with an unknown chain id', (done) => { const { chainId, ...tx } = rawTx - worker.signTransaction(key, tx, (err) => { + const cb = (err) => { try { expect(err).toBe('could not determine chain id for transaction') done() } catch (e) { done(e) } - }) + } + + worker.signTransaction(cb, { index: 0, rawTx: tx }) }, 200) }) diff --git a/test/main/signers/hot/SeedSigner/index.test.js b/test/main/signers/hot/SeedSigner/index.test.js index 9aad28f50..e6c67a0f6 100644 --- a/test/main/signers/hot/SeedSigner/index.test.js +++ b/test/main/signers/hot/SeedSigner/index.test.js @@ -3,18 +3,39 @@ import { remove } from 'fs-extra' import { generateMnemonic } from 'bip39' import log from 'electron-log' +import hot from '../../../../../main/signers/hot' + const PASSWORD = 'fr@///3_password' const SIGNER_PATH = path.resolve(__dirname, '../.userData/signers') jest.mock('electron') jest.mock('../../../../../main/store/persist') +jest.mock('path', () => { + const original = jest.requireActual('path') + + return { + ...original, + resolve: (...args) => { + // TODO: this can be cleaned up once tests are re-worked + if (args.includes('worker/launch.js')) { + return original.resolve( + __dirname, + '../../../../../compiled/main/signers/hot/HotSigner/worker/launch.js' + ) + } + + return original.resolve(...args) + } + } +}) + // Stubs const signers = { add: () => {} } // Util const clean = () => remove(SIGNER_PATH) -let hot, store +let store describe('Seed signer', () => { let signer @@ -24,7 +45,6 @@ describe('Seed signer', () => { clean() - hot = await import('../../../../../main/signers/hot') store = require('../../../../../main/store').default })