From 1e88108e57025b0e45df925a0fb1ada9d95194fa Mon Sep 17 00:00:00 2001 From: Anh Cao <5773176+anhcao142@users.noreply.github.com> Date: Wed, 9 Dec 2020 02:49:49 +0700 Subject: [PATCH] Add get signatureHash (#10) * Add get signatureHash * Update type * Fix deserialize * Update * Remove recursive package --- hedera.d.ts | 12 ++- lib/constants.js | 2 - lib/cryptoGetAccountBalance.js | 4 +- lib/cryptoGetAccountRecords.js | 4 +- lib/cryptoGetInfo.js | 4 +- lib/protoHelper.js | 10 ++ lib/query.js | 10 +- lib/transaction.js | 42 ++------ lib/transactionId.js | 25 ++--- lib/util.js | 4 +- package.json | 3 +- yarn.lock | 176 +-------------------------------- 12 files changed, 49 insertions(+), 247 deletions(-) diff --git a/hedera.d.ts b/hedera.d.ts index 4886027..7fa7996 100644 --- a/hedera.d.ts +++ b/hedera.d.ts @@ -23,7 +23,8 @@ export declare namespace util { function getTransfers(transaction: {}): { accountId: string, amount: string }[]; function getRecordTransfers(record: {}): { accountId: string, amount: string }[]; function deserializeTx(hex: string): Transaction - function serializeAccountID(accountId: AccountID): string + function serializeAccountID(accountId: AccountID): string; + function serializeTxID(transactionID: TransactionID): string; } export declare interface Duration { @@ -147,9 +148,9 @@ export declare namespace Query { export declare class Query { constructor(options: { nodeAccountId: AccountID | string, operatorId: AccountID | string }); - serialize(): Promise; - static deserialize(hex: string): Promise<{}>; - signTransaction(privateKey: string): Promise; + serialize(): Buffer; + static deserialize(hex: string): {}; + signTransaction(privateKey: string): Query; toObject(): {}; } @@ -161,8 +162,9 @@ export declare interface Transaction { export declare class Transaction { constructor(options: { operatorId: AccountID | string, nodeAccountId: AccountID | string}); + get signatureHash(): Buffer; addSignature(signature: string | Buffer, publicKey: string): Transaction; - serialize(): string; + serialize(): Buffer; static deserialize(hex: string): Transaction; static serializeBody(tx: any): Buffer; toObject(): Transaction; diff --git a/lib/constants.js b/lib/constants.js index 540a5fb..ecb24ca 100644 --- a/lib/constants.js +++ b/lib/constants.js @@ -1,5 +1,3 @@ -const Long = require('long'); - const TRANSACTION_RESPONSE_CODE = { 0: 'OK', // The transaction passed the precheck validations. 1: 'INVALID_TRANSACTION', // For any error not handled by specific error codes listed below. diff --git a/lib/cryptoGetAccountBalance.js b/lib/cryptoGetAccountBalance.js index a735970..faa7e71 100644 --- a/lib/cryptoGetAccountBalance.js +++ b/lib/cryptoGetAccountBalance.js @@ -15,8 +15,8 @@ class CryptoGetAccountBalance extends Query { }; } - static async handleResponse(response) { - const res = await super.handleResponse(response); + static handleResponse(response) { + const res = super.handleResponse(response); return res.cryptogetAccountBalance; } } diff --git a/lib/cryptoGetAccountRecords.js b/lib/cryptoGetAccountRecords.js index 105b7ae..adc0ca7 100644 --- a/lib/cryptoGetAccountRecords.js +++ b/lib/cryptoGetAccountRecords.js @@ -15,8 +15,8 @@ class CryptoGetAccountRecords extends Query { }; } - static async handleResponse(response) { - const res = await super.handleResponse(response); + static handleResponse(response) { + const res = super.handleResponse(response); return res.cryptoGetAccountRecords; } } diff --git a/lib/cryptoGetInfo.js b/lib/cryptoGetInfo.js index 342a18e..577b9fd 100644 --- a/lib/cryptoGetInfo.js +++ b/lib/cryptoGetInfo.js @@ -15,8 +15,8 @@ class CryptoGetInfo extends Query { }; } - static async handleResponse(response) { - const res = await super.handleResponse(response); + static handleResponse(response) { + const res = super.handleResponse(response); return res.cryptoGetInfo; } } diff --git a/lib/protoHelper.js b/lib/protoHelper.js index 3daf5e7..056e73d 100644 --- a/lib/protoHelper.js +++ b/lib/protoHelper.js @@ -23,6 +23,11 @@ function deserialize(msgName, hex) { exports.SignedTransactionProto = { serialize: (obj) => serialize('SignedTransaction', obj), deserialize: (hex) => deserialize('SignedTransaction', hex), + deserializeDeep: (hex) => { + const signedTx = deserialize('SignedTransaction', hex); + const body = this.TransactionBodyProto.deserialize(signedTx.bodyBytes); + return { ...signedTx, body }; + }, }; exports.TransactionBodyProto = { @@ -39,3 +44,8 @@ exports.QueryProto = { serialize: (obj) => serialize('Query', obj), deserialize: (hex) => deserialize('Query', hex), }; + +exports.TransactionIDProto = { + serialize: (obj) => serialize('TransactionID', obj), + deserialize: (hex) => deserialize('TransactionID', hex), +}; diff --git a/lib/query.js b/lib/query.js index ee305b8..13920f6 100644 --- a/lib/query.js +++ b/lib/query.js @@ -1,5 +1,3 @@ -const protobuf = require('protobufjs'); -const path = require('path'); const Long = require('long'); const CryptoTransfer = require('./cryptoTransfer'); const AccountID = require('./accountId'); @@ -25,12 +23,12 @@ class Query { }); } - async serialize() { + serialize() { const queryObj = this.toObject(); return QueryProto.serialize(queryObj); } - static async deserialize(hex) { + static deserialize(hex) { return QueryProto.deserialize(hex); } @@ -86,8 +84,8 @@ class Query { return res; } - async signTransaction(privateKey, publicKey) { - await this.payment.signTransaction(privateKey, publicKey); + signTransaction(privateKey, publicKey) { + this.payment.signTransaction(privateKey, publicKey); return this; } diff --git a/lib/transaction.js b/lib/transaction.js index 6e28c71..5246f28 100644 --- a/lib/transaction.js +++ b/lib/transaction.js @@ -1,14 +1,11 @@ -const protobuf = require('protobufjs'); const forge = require('node-forge'); -const path = require('path'); const Long = require('long'); const duration = require('./duration'); const AccountID = require('./accountId'); -const { SignedTransactionProto, TransactionBodyProto } = require('./protoHelper'); +const { SignedTransactionProto, TransactionBodyProto, TransactionProto } = require('./protoHelper'); const { DEFAULT_TX_FEE, TRANSACTION_RESPONSE_CODE } = require('./constants'); const { ed25519 } = forge; -const txRoot = protobuf.loadSync(path.join(__dirname, '../hedera-proto/Transaction.proto')); class Transaction { constructor({ operatorId, nodeAccountId }) { @@ -40,35 +37,16 @@ class Transaction { }; } - serialize() { - const TransactionProto = txRoot.lookup('proto.Transaction'); - const error = TransactionProto.verify(this.tx); - if (error) throw Error(error); + get signatureHash() { + return TransactionBodyProto.serialize(this.txBody); + } - const message = TransactionProto.create(this.tx); - const buffer = TransactionProto.encode(message).finish(); - return buffer.toString('hex'); + serialize() { + return TransactionProto.serialize(this.tx); } static deserialize(hex) { - let signed; - let body; - const buffer = Buffer.from(hex, 'hex'); - const TransactionProto = txRoot.lookup('proto.Transaction'); - const tx = TransactionProto.decode(buffer); - - const error = TransactionProto.verify(tx); - if (error) return undefined; - - if (tx.signedTransactionBytes) { - signed = SignedTransactionProto.deserialize(tx.signedTransactionBytes); - } - - if (signed.bodyBytes) { - body = TransactionBodyProto.deserialize(signed.bodyBytes); - } - - return body; + return TransactionProto.deserialize(hex); } toObject() { @@ -79,7 +57,7 @@ class Transaction { return this.txBody.transactionID; } - static async handleResponse(response) { + static handleResponse(response) { if (response.nodeTransactionPrecheckCode === 0 || !response.nodeTransactionPrecheckCode) { return TRANSACTION_RESPONSE_CODE[0]; } @@ -108,12 +86,12 @@ class Transaction { } // sign and return tx with signature - async signTransaction(privateKey, publicKey) { + signTransaction(privateKey, publicKey) { if (!this.txBody) { throw Error('Missing transaction body. Must create transaction before adding signature'); } - const signature = await this.constructor.sign(this.txBody, privateKey); + const signature = this.constructor.sign(this.txBody, privateKey); this.addSignature(signature, publicKey); return this; } diff --git a/lib/transactionId.js b/lib/transactionId.js index 333506d..1bc9b9c 100644 --- a/lib/transactionId.js +++ b/lib/transactionId.js @@ -1,9 +1,6 @@ -const path = require('path'); const Long = require('long'); -const protobuf = require('protobufjs'); const AccountID = require('./accountId'); - -const root = protobuf.loadSync(path.join(__dirname, '../hedera-proto/BasicTypes.proto')); +const { TransactionIDProto } = require('./protoHelper'); class TransactionID { constructor(obj) { @@ -43,33 +40,23 @@ class TransactionID { return { transactionValidStart, - accountID: new AccountID(accountId).toObject() + accountID: new AccountID(accountId).toObject(), }; } - static async serialize(transactionId) { - const TransactionIDProto = root.lookup('proto.TransactionID'); + static serialize(transactionId) { const serializeObj = { transactionValidStart: { seconds: Long.fromValue(transactionId.transactionValidStart.seconds), }, accountID: new AccountID(transactionId.accountID).toObject(), }; - const error = TransactionIDProto.verify(serializeObj); - if (error) throw Error(error); - const message = TransactionIDProto.create(serializeObj); - const buffer = TransactionIDProto.encode(message).finish(); - return buffer.toString('hex'); + return TransactionIDProto.serialize(serializeObj).toString('hex'); } - static async deserialize(hex) { - const buffer = Buffer.from(hex, 'hex'); - const TransactionIDProto = root.lookup('proto.TransactionID'); - const transactionId = TransactionIDProto.decode(buffer); - const error = TransactionIDProto.verify(transactionId); - if (error) throw error; - return transactionId; + static deserialize(hex) { + return TransactionIDProto.deserialize(hex); } } diff --git a/lib/util.js b/lib/util.js index 084e103..33a9722 100644 --- a/lib/util.js +++ b/lib/util.js @@ -3,6 +3,7 @@ const Long = require('long'); const Decimal = require('decimal.js'); const AccountID = require('./accountId'); const Transaction = require('./transaction'); +const { SignedTransactionProto } = require('./protoHelper'); const { HBAR_TO_TINYBAR, DECIMALS } = require('./constants'); const { parsePrivateKey, parsePublicKey } = require('../crypto/asn1parser'); @@ -91,7 +92,8 @@ function getTransactionId(transaction) { } function deserializeTx(hex) { - return Transaction.deserialize(hex); + const tx = Transaction.deserialize(hex); + return { ...tx, ...SignedTransactionProto.deserializeDeep(tx.signedTransactionBytes) }; } function serializeAccountID(accountId) { diff --git a/package.json b/package.json index 2b658f0..470f4e7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "hedera-sdk-js", - "version": "0.4.0", + "version": "0.5.0", "description": "Hedera js sdk", "main": "index.js", "scripts": { @@ -15,7 +15,6 @@ "license": "ISC", "dependencies": { "@fidm/asn1": "^1.0.4", - "@hashgraph/sdk": "^0.5.1", "bluebird": "^3.5.5", "decimal.js": "^10.2.0", "grpc": "^1.22.2", diff --git a/yarn.lock b/yarn.lock index d540aa9..732336c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -31,26 +31,6 @@ lodash.camelcase "^4.3.0" protobufjs "^6.8.6" -"@hashgraph/sdk@^0.5.1": - version "0.5.1" - resolved "https://registry.yarnpkg.com/@hashgraph/sdk/-/sdk-0.5.1.tgz#c0d63969eff7fdc6405614de4d4aee25caa2066b" - integrity sha512-QG2lnKUv5kEIE2qf9u3Z+TddMQUbwmbW3D1UGcA2Sd4A2VWuu8kfvxda0E73YyE5tncybsQxqDerzdE/NERESw== - dependencies: - "@improbable-eng/grpc-web" "0.11.0" - "@types/google-protobuf" "^3.7.1" - bignumber.js "^9.0.0" - bip39 "^3.0.2" - google-protobuf "^3.9.1" - grpc "^1.23.3" - tweetnacl "^1.0.1" - -"@improbable-eng/grpc-web@0.11.0": - version "0.11.0" - resolved "https://registry.yarnpkg.com/@improbable-eng/grpc-web/-/grpc-web-0.11.0.tgz#c9d4097b4a947384e3dc0234299d910668a6e7ad" - integrity sha512-SS2YP6iHyZ7TSSuCShnSo9xJyUkNZHEhEPJpTSUcNoULe1LuLEk52OKHY+VW9XB0qXstejpHgZq2Hx+69PThiw== - dependencies: - browser-headers "^0.4.0" - "@protobufjs/aspromise@^1.1.1", "@protobufjs/aspromise@^1.1.2": version "1.1.2" resolved "https://registry.yarnpkg.com/@protobufjs/aspromise/-/aspromise-1.1.2.tgz#9b8b0cc663d669a7d8f6f5d0893a14d348f30fbf" @@ -104,34 +84,11 @@ resolved "https://registry.yarnpkg.com/@protobufjs/utf8/-/utf8-1.1.0.tgz#a777360b5b39a1a2e5106f8e858f2fd2d060c570" integrity sha1-p3c2C1s5oaLlEG+OhY8v0tBgxXA= -"@types/bytebuffer@^5.0.40": - version "5.0.40" - resolved "https://registry.yarnpkg.com/@types/bytebuffer/-/bytebuffer-5.0.40.tgz#d6faac40dcfb09cd856cdc4c01d3690ba536d3ee" - integrity sha512-h48dyzZrPMz25K6Q4+NCwWaxwXany2FhQg/ErOcdZS1ZpsaDnDMZg8JYLMTGz7uvXKrcKGJUZJlZObyfgdaN9g== - dependencies: - "@types/long" "*" - "@types/node" "*" - -"@types/google-protobuf@^3.7.1": - version "3.7.1" - resolved "https://registry.yarnpkg.com/@types/google-protobuf/-/google-protobuf-3.7.1.tgz#69503856e717a4ed2fd0216d4aa3f0bebf5df5df" - integrity sha512-kiLxbqoi2C7NmkGj1ZpkSDyIqj4vqDEIjx7wX+O0GXV6bLX6u/oLz49CwefD0c0vzaKeBdOqmUtI8bC0bBRr0w== - -"@types/long@*", "@types/long@^4.0.0": +"@types/long@^4.0.0": version "4.0.0" resolved "https://registry.yarnpkg.com/@types/long/-/long-4.0.0.tgz#719551d2352d301ac8b81db732acb6bdc28dbdef" integrity sha512-1w52Nyx4Gq47uuu0EVcsHBxZFJgurQ+rTKS3qMHxR1GY2T8c2AJYd6vZoZ9q1rupaDjU0yT+Jc2XTyXkjeMA+Q== -"@types/node@*": - version "12.7.5" - resolved "https://registry.yarnpkg.com/@types/node/-/node-12.7.5.tgz#e19436e7f8e9b4601005d73673b6dc4784ffcc2f" - integrity sha512-9fq4jZVhPNW8r+UYKnxF1e2HkDWOWKM5bC2/7c9wPV835I0aOrVbS/Hw/pWPk2uKrNXQqg9Z959Kz+IYDd5p3w== - -"@types/node@11.11.6": - version "11.11.6" - resolved "https://registry.yarnpkg.com/@types/node/-/node-11.11.6.tgz#df929d1bb2eee5afdda598a41930fe50b43eaa6a" - integrity sha512-Exw4yUWMBXM3X+8oqzJNRqZSwUAaS4+7NdvHqQuFi/d+synz++xmX3QIf+BFqneW8N31R8Ky+sikfZUXq07ggQ== - "@types/node@^10.1.0": version "10.14.6" resolved "https://registry.yarnpkg.com/@types/node/-/node-10.14.6.tgz#9cbfcb62c50947217f4d88d4d274cc40c22625a9" @@ -240,21 +197,6 @@ balanced-match@^1.0.0: resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= -bignumber.js@^9.0.0: - version "9.0.0" - resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-9.0.0.tgz#805880f84a329b5eac6e7cb6f8274b6d82bdf075" - integrity sha512-t/OYhhJ2SD+YGBQcjY8GzzDHEk9f3nerxjtfa6tlMXfe7frs/WozhvCNoGvpM0P3bNf3Gq5ZRMlGr5f3r4/N8A== - -bip39@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/bip39/-/bip39-3.0.2.tgz#2baf42ff3071fc9ddd5103de92e8f80d9257ee32" - integrity sha512-J4E1r2N0tUylTKt07ibXvhpT2c5pyAFgvuA5q1H9uDy6dEGpjV8jmymh3MTYJDLCNbIVClSB9FbND49I6N24MQ== - dependencies: - "@types/node" "11.11.6" - create-hash "^1.1.0" - pbkdf2 "^3.0.9" - randombytes "^2.0.1" - bluebird@^3.5.5: version "3.5.5" resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.5.tgz#a8d0afd73251effbbd5fe384a77d73003c17a71f" @@ -268,11 +210,6 @@ brace-expansion@^1.1.7: balanced-match "^1.0.0" concat-map "0.0.1" -browser-headers@^0.4.0: - version "0.4.1" - resolved "https://registry.yarnpkg.com/browser-headers/-/browser-headers-0.4.1.tgz#4308a7ad3b240f4203dbb45acedb38dc2d65dd02" - integrity sha512-CA9hsySZVo9371qEHjHZtYxV2cFtVj5Wj/ZHi8ooEsrtm4vOnl9Y9HmyYWk9q+05d7K3rdoAE0j3MVEFVvtQtg== - bytebuffer@~5: version "5.0.1" resolved "https://registry.yarnpkg.com/bytebuffer/-/bytebuffer-5.0.1.tgz#582eea4b1a873b6d020a48d58df85f0bba6cfddd" @@ -314,14 +251,6 @@ chownr@^1.1.1: resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.1.1.tgz#54726b8b8fff4df053c42187e801fb4412df1494" integrity sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g== -cipher-base@^1.0.1, cipher-base@^1.0.3: - version "1.0.4" - resolved "https://registry.yarnpkg.com/cipher-base/-/cipher-base-1.0.4.tgz#8760e4ecc272f4c363532f926d874aae2c1397de" - integrity sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q== - dependencies: - inherits "^2.0.1" - safe-buffer "^5.0.1" - cli-cursor@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" @@ -390,29 +319,6 @@ core-util-is@~1.0.0: resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= -create-hash@^1.1.0, create-hash@^1.1.2: - version "1.2.0" - resolved "https://registry.yarnpkg.com/create-hash/-/create-hash-1.2.0.tgz#889078af11a63756bcfb59bd221996be3a9ef196" - integrity sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg== - dependencies: - cipher-base "^1.0.1" - inherits "^2.0.1" - md5.js "^1.3.4" - ripemd160 "^2.0.1" - sha.js "^2.4.0" - -create-hmac@^1.1.4: - version "1.1.7" - resolved "https://registry.yarnpkg.com/create-hmac/-/create-hmac-1.1.7.tgz#69170c78b3ab957147b2b8b04572e47ead2243ff" - integrity sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg== - dependencies: - cipher-base "^1.0.3" - create-hash "^1.1.0" - inherits "^2.0.1" - ripemd160 "^2.0.0" - safe-buffer "^5.0.1" - sha.js "^2.4.8" - cross-spawn@^6.0.5: version "6.0.5" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" @@ -797,11 +703,6 @@ globals@^11.7.0: resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== -google-protobuf@^3.9.1: - version "3.9.1" - resolved "https://registry.yarnpkg.com/google-protobuf/-/google-protobuf-3.9.1.tgz#87e6a16b7fb16405b515a6c6622d5ace45578d86" - integrity sha512-tkz7SVwBktFbqFK3teXFUY/VM57+mbUgV9bSD+sZH1ocHJ7uk7BfEWMRdU24dd0ciUDokreA7ghH2fYFIczQdw== - graceful-fs@^4.1.2: version "4.1.15" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" @@ -846,18 +747,6 @@ grpc@^1.22.2: node-pre-gyp "^0.13.0" protobufjs "^5.0.3" -grpc@^1.23.3: - version "1.23.3" - resolved "https://registry.yarnpkg.com/grpc/-/grpc-1.23.3.tgz#30a013ca2cd7e350b0ffc0034be5380ddef3ae7f" - integrity sha512-7vdzxPw9s5UYch4aUn4hyM5tMaouaxUUkwkgJlwbR4AXMxiYZJOv19N2ps2eKiuUbJovo5fnGF9hg/X91gWYjw== - dependencies: - "@types/bytebuffer" "^5.0.40" - lodash.camelcase "^4.3.0" - lodash.clone "^4.5.0" - nan "^2.13.2" - node-pre-gyp "^0.13.0" - protobufjs "^5.0.3" - has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" @@ -880,14 +769,6 @@ has@^1.0.1, has@^1.0.3: dependencies: function-bind "^1.1.1" -hash-base@^3.0.0: - version "3.0.4" - resolved "https://registry.yarnpkg.com/hash-base/-/hash-base-3.0.4.tgz#5fc8686847ecd73499403319a6b0a3f3f6ae4918" - integrity sha1-X8hoaEfs1zSZQDMZprCj8/auSRg= - dependencies: - inherits "^2.0.1" - safe-buffer "^5.0.1" - hosted-git-info@^2.1.4: version "2.7.1" resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz#97f236977bd6e125408930ff6de3eec6281ec047" @@ -933,7 +814,7 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.1: +inherits@2: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -1126,15 +1007,6 @@ long@~3: resolved "https://registry.yarnpkg.com/long/-/long-3.2.0.tgz#d821b7138ca1cb581c172990ef14db200b5c474b" integrity sha1-2CG3E4yhy1gcFymQ7xTbIAtcR0s= -md5.js@^1.3.4: - version "1.3.5" - resolved "https://registry.yarnpkg.com/md5.js/-/md5.js-1.3.5.tgz#b5d07b8e3216e3e27cd728d72f70d1e6a342005f" - integrity sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg== - dependencies: - hash-base "^3.0.0" - inherits "^2.0.1" - safe-buffer "^5.1.2" - mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" @@ -1441,17 +1313,6 @@ path-type@^2.0.0: dependencies: pify "^2.0.0" -pbkdf2@^3.0.9: - version "3.0.17" - resolved "https://registry.yarnpkg.com/pbkdf2/-/pbkdf2-3.0.17.tgz#976c206530617b14ebb32114239f7b09336e93a6" - integrity sha512-U/il5MsrZp7mGg3mSQfn742na2T+1/vHDCG5/iTI3X9MKUuYUZVLQhyRsg06mCgDBTd57TxzgZt7P+fYfjRLtA== - dependencies: - create-hash "^1.1.2" - create-hmac "^1.1.4" - ripemd160 "^2.0.1" - safe-buffer "^5.0.1" - sha.js "^2.4.8" - pify@^2.0.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" @@ -1520,13 +1381,6 @@ punycode@^2.1.0: resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== -randombytes@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" - integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== - dependencies: - safe-buffer "^5.1.0" - rc@^1.2.7: version "1.2.8" resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" @@ -1599,14 +1453,6 @@ rimraf@2.6.3, rimraf@^2.6.1: dependencies: glob "^7.1.3" -ripemd160@^2.0.0, ripemd160@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/ripemd160/-/ripemd160-2.0.2.tgz#a1c1a6f624751577ba5d07914cbc92850585890c" - integrity sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA== - dependencies: - hash-base "^3.0.0" - inherits "^2.0.1" - run-async@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" @@ -1621,11 +1467,6 @@ rxjs@^6.4.0: dependencies: tslib "^1.9.0" -safe-buffer@^5.0.1, safe-buffer@^5.1.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.0.tgz#b74daec49b1148f88c64b68d49b1e815c1f2f519" - integrity sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg== - safe-buffer@^5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.2" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" @@ -1661,14 +1502,6 @@ set-blocking@~2.0.0: resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= -sha.js@^2.4.0, sha.js@^2.4.8: - version "2.4.11" - resolved "https://registry.yarnpkg.com/sha.js/-/sha.js-2.4.11.tgz#37a5cf0b81ecbc6943de109ba2960d1b26584ae7" - integrity sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ== - dependencies: - inherits "^2.0.1" - safe-buffer "^5.0.1" - shebang-command@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" @@ -1852,11 +1685,6 @@ tslib@^1.9.0: resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a" integrity sha512-qOebF53frne81cf0S9B41ByenJ3/IuH8yJKngAX35CmiZySA0khhkovshKK+jGCaMnVomla7gVlIcc3EvKPbTQ== -tweetnacl@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.1.tgz#2594d42da73cd036bd0d2a54683dd35a6b55ca17" - integrity sha512-kcoMoKTPYnoeS50tzoqjPY3Uv9axeuuFAZY9M/9zFnhoVvRfxz9K29IMPD7jGmt2c8SW7i3gT9WqDl2+nV7p4A== - type-check@~0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72"