diff --git a/modules/sdk-coin-apt/package.json b/modules/sdk-coin-apt/package.json index 91a45106c0..cc2dfd9736 100644 --- a/modules/sdk-coin-apt/package.json +++ b/modules/sdk-coin-apt/package.json @@ -42,6 +42,7 @@ "dependencies": { "@bitgo/sdk-core": "^28.14.1", "@bitgo/statics": "^50.9.0", + "@aptos-labs/ts-sdk": "^1.32.0", "bignumber.js": "^9.1.2" }, "devDependencies": { diff --git a/modules/sdk-coin-apt/src/apt.ts b/modules/sdk-coin-apt/src/apt.ts index fa29ecddf5..752b55eb67 100644 --- a/modules/sdk-coin-apt/src/apt.ts +++ b/modules/sdk-coin-apt/src/apt.ts @@ -1,7 +1,9 @@ import { BaseCoin, BitGoBase, + InvalidAddressError, KeyPair, + MPCAlgorithm, ParsedTransaction, ParseTransactionOptions, SignedTransaction, @@ -10,6 +12,8 @@ import { VerifyTransactionOptions, } from '@bitgo/sdk-core'; import { BaseCoin as StaticsBaseCoin } from '@bitgo/statics'; +import { KeyPair as AptKeyPair } from './lib'; +import utils from './lib/utils'; export class Apt extends BaseCoin { protected readonly _staticsCoin: Readonly; @@ -46,28 +50,54 @@ export class Apt extends BaseCoin { return 'Aptos'; } - verifyTransaction(params: VerifyTransactionOptions): Promise { - throw new Error('Method not implemented.'); + /** @inheritDoc */ + supportsTss(): boolean { + return true; + } + + getMPCAlgorithm(): MPCAlgorithm { + return 'eddsa'; } - isWalletAddress(params: VerifyAddressOptions): Promise { + allowsAccountConsolidations(): boolean { + return true; + } + + async verifyTransaction(params: VerifyTransactionOptions): Promise { throw new Error('Method not implemented.'); } + async isWalletAddress(params: VerifyAddressOptions): Promise { + const { address: newAddress } = params; + + if (!this.isValidAddress(newAddress)) { + throw new InvalidAddressError(`invalid address: ${newAddress}`); + } + return true; + } + parseTransaction(params: ParseTransactionOptions): Promise { throw new Error('Method not implemented.'); } generateKeyPair(seed?: Buffer): KeyPair { - throw new Error('Method not implemented.'); + const keyPair = seed ? new AptKeyPair({ seed }) : new AptKeyPair(); + const keys = keyPair.getKeys(); + if (!keys.prv) { + throw new Error('Missing prv in key generation.'); + } + return { + pub: keys.pub, + prv: keys.prv, + }; } isValidPub(pub: string): boolean { - throw new Error('Method not implemented.'); + return utils.isValidPublicKey(pub); } isValidAddress(address: string): boolean { - throw new Error('Method not implemented.'); + return utils.isValidAddress(address); } signTransaction(params: SignTransactionOptions): Promise { diff --git a/modules/sdk-coin-apt/src/lib/constants.ts b/modules/sdk-coin-apt/src/lib/constants.ts new file mode 100644 index 0000000000..4cbd0c5c11 --- /dev/null +++ b/modules/sdk-coin-apt/src/lib/constants.ts @@ -0,0 +1,4 @@ +export const APT_ADDRESS_LENGTH = 64; +export const APT_TRANSACTION_ID_LENGTH = 64; +export const APT_BLOCK_ID_LENGTH = 64; +export const APT_SIGNATURE_LENGTH = 128; diff --git a/modules/sdk-coin-apt/src/lib/keyPair.ts b/modules/sdk-coin-apt/src/lib/keyPair.ts index bb4449c74a..bde7338743 100644 --- a/modules/sdk-coin-apt/src/lib/keyPair.ts +++ b/modules/sdk-coin-apt/src/lib/keyPair.ts @@ -1,23 +1,42 @@ -import { DefaultKeys, Ed25519KeyPair } from '@bitgo/sdk-core'; +import { DefaultKeys, Ed25519KeyPair, KeyPairOptions } from '@bitgo/sdk-core'; +import utils from './utils'; export class KeyPair extends Ed25519KeyPair { + /** + * Public constructor. By default, creates a key pair with a random master seed. + * + * @param { KeyPairOptions } source Either a master seed, a private key, or a public key + */ + constructor(source?: KeyPairOptions) { + super(source); + } + /** @inheritdoc */ getKeys(): DefaultKeys { - throw new Error('Method not implemented.'); + const result: DefaultKeys = { pub: this.keyPair.pub }; + if (this.keyPair.prv) { + result.prv = this.keyPair.prv; + } + return result; } /** @inheritdoc */ recordKeysFromPrivateKeyInProtocolFormat(prv: string): DefaultKeys { + // We don't use private keys for APT since it's implemented for TSS. throw new Error('Method not implemented.'); } /** @inheritdoc */ recordKeysFromPublicKeyInProtocolFormat(pub: string): DefaultKeys { - throw new Error('Method not implemented.'); + if (!utils.isValidPublicKey(pub)) { + throw new Error(`Invalid Public Key ${pub}`); + } + + return { pub }; } /** @inheritdoc */ getAddress(): string { - throw new Error('Method not implemented.'); + return utils.getAddressFromPublicKey(this.keyPair.pub); } } diff --git a/modules/sdk-coin-apt/src/lib/utils.ts b/modules/sdk-coin-apt/src/lib/utils.ts index b0cdef2405..824796bc72 100644 --- a/modules/sdk-coin-apt/src/lib/utils.ts +++ b/modules/sdk-coin-apt/src/lib/utils.ts @@ -1,34 +1,48 @@ -import { BaseUtils } from '@bitgo/sdk-core'; +import { AuthenticationKey, Ed25519PublicKey } from '@aptos-labs/ts-sdk'; +import { BaseUtils, isValidEd25519PublicKey, isValidEd25519SecretKey } from '@bitgo/sdk-core'; +import { APT_ADDRESS_LENGTH, APT_BLOCK_ID_LENGTH, APT_SIGNATURE_LENGTH, APT_TRANSACTION_ID_LENGTH } from './constants'; export class Utils implements BaseUtils { /** @inheritdoc */ isValidAddress(address: string): boolean { - throw new Error('Method not implemented.'); + return this.isValidHex(address, APT_ADDRESS_LENGTH); } /** @inheritdoc */ isValidBlockId(hash: string): boolean { - throw new Error('Method not implemented.'); + return this.isValidHex(hash, APT_BLOCK_ID_LENGTH); } /** @inheritdoc */ isValidPrivateKey(key: string): boolean { - throw new Error('Method not implemented.'); + return isValidEd25519SecretKey(key); } /** @inheritdoc */ isValidPublicKey(key: string): boolean { - throw new Error('Method not implemented.'); + return isValidEd25519PublicKey(key); } /** @inheritdoc */ isValidSignature(signature: string): boolean { - throw new Error('Method not implemented.'); + return this.isValidHex(signature, APT_SIGNATURE_LENGTH); } /** @inheritdoc */ isValidTransactionId(txId: string): boolean { - throw new Error('Method not implemented.'); + return this.isValidHex(txId, APT_TRANSACTION_ID_LENGTH); + } + + isValidHex(value: string, length: number) { + const regex = new RegExp(`^(0x|0X)[a-fA-F0-9]{${length}}$`); + return regex.test(value); + } + + getAddressFromPublicKey(publicKey: string): string { + const aptosPublicKey = new Ed25519PublicKey(Buffer.from(publicKey, 'hex')); + const authKey = AuthenticationKey.fromPublicKey({ publicKey: aptosPublicKey }); + const accountAddress = authKey.derivedAddress(); + return accountAddress.toString(); } } diff --git a/yarn.lock b/yarn.lock index 9e57c748b3..4bad039fa8 100644 --- a/yarn.lock +++ b/yarn.lock @@ -25,6 +25,38 @@ resolved "https://registry.npmjs.org/@api-ts/response/-/response-1.0.0.tgz#7d11fd7602a271d7964723da5f8f66cc6566b93f" integrity sha512-OTrMH5yyxNzzkC3fZPcz7KFN2j8A9ZD8YhwiYxy8zGKkE5aOJ4wWQO+q44H5mQLi3txD8AlvwQfkbpo3KyCmGw== +"@aptos-labs/aptos-cli@^1.0.2": + version "1.0.2" + resolved "https://registry.npmjs.org/@aptos-labs/aptos-cli/-/aptos-cli-1.0.2.tgz#91bd1368cf808f715d102822b7d4032388cdad79" + integrity sha512-PYPsd0Kk3ynkxNfe3S4fanI3DiUICCoh4ibQderbvjPFL5A0oK6F4lPEO2t0MDsQySTk2t4vh99Xjy6Bd9y+aQ== + dependencies: + commander "^12.1.0" + +"@aptos-labs/aptos-client@^0.1.1": + version "0.1.1" + resolved "https://registry.npmjs.org/@aptos-labs/aptos-client/-/aptos-client-0.1.1.tgz#cbcd2a73bad252e344318baec32ecc54d8136ee0" + integrity sha512-kJsoy4fAPTOhzVr7Vwq8s/AUg6BQiJDa7WOqRzev4zsuIS3+JCuIZ6vUd7UBsjnxtmguJJulMRs9qWCzVBt2XA== + dependencies: + axios "1.7.4" + got "^11.8.6" + +"@aptos-labs/ts-sdk@^1.32.0": + version "1.33.0" + resolved "https://registry.npmjs.org/@aptos-labs/ts-sdk/-/ts-sdk-1.33.0.tgz#4da4501d04ad38381630b06d7d8a29bc4b3f1855" + integrity sha512-svdlPH5r2dlSue2D9WXaaTslsmX18WLytAho6IRZJxQjEssglk64I6c1G9S8BTjRQj/ug6ahTwp6lx3eWuyd8Q== + dependencies: + "@aptos-labs/aptos-cli" "^1.0.2" + "@aptos-labs/aptos-client" "^0.1.1" + "@noble/curves" "^1.4.0" + "@noble/hashes" "^1.4.0" + "@scure/bip32" "^1.4.0" + "@scure/bip39" "^1.3.0" + eventemitter3 "^5.0.1" + form-data "^4.0.0" + js-base64 "^3.7.7" + jwt-decode "^4.0.0" + poseidon-lite "^0.2.0" + "@babel/code-frame@7.12.11": version "7.12.11" resolved "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.12.11.tgz#f4ad435aa263db935b8f10f2c552d23fb716a63f" @@ -3284,6 +3316,13 @@ dependencies: "@noble/hashes" "1.5.0" +"@noble/curves@~1.7.0": + version "1.7.0" + resolved "https://registry.npmjs.org/@noble/curves/-/curves-1.7.0.tgz#0512360622439256df892f21d25b388f52505e45" + integrity sha512-UTMhXK9SeDhFJVrHeUJ5uZlI6ajXg10O6Ddocf9S6GjbSBVZsJo88HzKwXznNfGpMTRDyJkqMjNDPYgf0qFWnw== + dependencies: + "@noble/hashes" "1.6.0" + "@noble/hashes@1.2.0", "@noble/hashes@~1.2.0": version "1.2.0" resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz#a3150eeb09cc7ab207ebf6d7b9ad311a9bdbed12" @@ -3304,6 +3343,16 @@ resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.5.0.tgz#abadc5ca20332db2b1b2aa3e496e9af1213570b0" integrity sha512-1j6kQFb7QRru7eKN3ZDvRcP13rugwdxZqCjbiAVZfIJwgj2A65UmT4TgARXGlXgnRkORLTDTrO19ZErt7+QXgA== +"@noble/hashes@1.6.0": + version "1.6.0" + resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.6.0.tgz#d4bfb516ad6e7b5111c216a5cc7075f4cf19e6c5" + integrity sha512-YUULf0Uk4/mAA89w+k3+yUYh6NrEvxZa5T6SY3wlMvE2chHkxFUUIDI8/XW1QSC357iA5pSnqt7XEhvFOqmDyQ== + +"@noble/hashes@~1.6.0": + version "1.6.1" + resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.6.1.tgz#df6e5943edcea504bac61395926d6fd67869a0d5" + integrity sha512-pq5D8h10hHBjyqX+cfBm0i8JUXJ0UhczFc4r74zbuT9XgewFo2E3J1cOaGtdZynILNmQ685YWGzGE1Zv6io50w== + "@noble/secp256k1@1.6.3", "@noble/secp256k1@1.7.1", "@noble/secp256k1@2.0.0", "@noble/secp256k1@~1.7.0": version "1.6.3" resolved "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.6.3.tgz#7eed12d9f4404b416999d0c87686836c4c5c9b94" @@ -4390,6 +4439,11 @@ resolved "https://registry.npmjs.org/@scure/base/-/base-1.1.9.tgz#e5e142fbbfe251091f9c5f1dd4c834ac04c3dbd1" integrity sha512-8YKhl8GHiNI/pU2VMaofa2Tor7PJRAjwQLBBuilkJ9L5+13yVbC7JO/wS7piioAvPSwR3JKM1IJ/u4xQzbcXKg== +"@scure/base@~1.2.1": + version "1.2.1" + resolved "https://registry.npmjs.org/@scure/base/-/base-1.2.1.tgz#dd0b2a533063ca612c17aa9ad26424a2ff5aa865" + integrity sha512-DGmGtC8Tt63J5GfHgfl5CuAXh96VF/LD8K9Hr/Gv0J2lAoRGlPOMpqMpMbCTOoOJMZCk2Xt+DskdDyn6dEFdzQ== + "@scure/bip32@1.1.5": version "1.1.5" resolved "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz#d2ccae16dcc2e75bc1d75f5ef3c66a338d1ba300" @@ -4417,6 +4471,15 @@ "@noble/hashes" "~1.5.0" "@scure/base" "~1.1.7" +"@scure/bip32@^1.4.0": + version "1.6.0" + resolved "https://registry.npmjs.org/@scure/bip32/-/bip32-1.6.0.tgz#6dbc6b4af7c9101b351f41231a879d8da47e0891" + integrity sha512-82q1QfklrUUdXJzjuRU7iG7D7XiFx5PHYVS0+oeNKhyDLT7WPqs6pBcM2W5ZdwOwKCwoE1Vy1se+DHjcXwCYnA== + dependencies: + "@noble/curves" "~1.7.0" + "@noble/hashes" "~1.6.0" + "@scure/base" "~1.2.1" + "@scure/bip39@1.1.1": version "1.1.1" resolved "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz#b54557b2e86214319405db819c4b6a370cf340c5" @@ -4441,6 +4504,14 @@ "@noble/hashes" "~1.5.0" "@scure/base" "~1.1.8" +"@scure/bip39@^1.3.0": + version "1.5.0" + resolved "https://registry.npmjs.org/@scure/bip39/-/bip39-1.5.0.tgz#c8f9533dbd787641b047984356531d84485f19be" + integrity sha512-Dop+ASYhnrwm9+HA/HwXg7j2ZqM6yk2fyLWb5znexjctFY3+E+eU8cIWI0Pql0Qx4hPZCijlGq4OL71g+Uz30A== + dependencies: + "@noble/hashes" "~1.6.0" + "@scure/base" "~1.2.1" + "@sideway/address@^4.1.5": version "4.1.5" resolved "https://registry.npmjs.org/@sideway/address/-/address-4.1.5.tgz#4bc149a0076623ced99ca8208ba780d65a99b9d5" @@ -6723,6 +6794,15 @@ axios@0.27.2: follow-redirects "^1.14.9" form-data "^4.0.0" +axios@1.7.4: + version "1.7.4" + resolved "https://registry.npmjs.org/axios/-/axios-1.7.4.tgz#4c8ded1b43683c8dd362973c393f3ede24052aa2" + integrity sha512-DukmaFRnY6AzAALSH4J2M3k6PkaC+MfaAGdEERRWcC9q3/TWQwLpHR8ZRLKTdQ3aBDL64EdluRDjJqKw+BPZEw== + dependencies: + follow-redirects "^1.15.6" + form-data "^4.0.0" + proxy-from-env "^1.1.0" + axios@^0.21.2: version "0.21.4" resolved "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz#c67b90dc0568e5c1cf2b0b858c43ba28e2eda575" @@ -8115,6 +8195,11 @@ combined-stream@^1.0.6, combined-stream@^1.0.8, combined-stream@~1.0.6: dependencies: delayed-stream "~1.0.0" +commander@^12.1.0: + version "12.1.0" + resolved "https://registry.npmjs.org/commander/-/commander-12.1.0.tgz#01423b36f501259fdaac4d0e4d60c96c991585d3" + integrity sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA== + commander@^2.20.0, commander@^2.20.3: version "2.20.3" resolved "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" @@ -11586,7 +11671,7 @@ got@9.6.0: to-readable-stream "^1.0.0" url-parse-lax "^3.0.0" -got@^11.8.5: +got@^11.8.5, got@^11.8.6: version "11.8.6" resolved "https://registry.npmjs.org/got/-/got-11.8.6.tgz#276e827ead8772eddbcfc97170590b841823233a" integrity sha512-6tfZ91bOr7bOXnK7PRDCGBLa1H4U080YHNaAQ2KsMGlLEzRbk44nsZF2E1IeRc3vtJHPVbKCYgdFbaGO2ljd8g== @@ -11907,7 +11992,18 @@ html-minifier-terser@^6.0.2: tapable "^1.1.3" util.promisify "1.0.0" -"html-webpack-plugin-5@npm:html-webpack-plugin@^5", html-webpack-plugin@^5.5.0: +"html-webpack-plugin-5@npm:html-webpack-plugin@^5": + version "5.6.3" + resolved "https://registry.npmjs.org/html-webpack-plugin/-/html-webpack-plugin-5.6.3.tgz#a31145f0fee4184d53a794f9513147df1e653685" + integrity sha512-QSf1yjtSAsmf7rYBV7XX86uua4W/vkhIt0xNXKbsi2foEeW7vjJQz4bhnpL3xH+l1ryl1680uNv968Z+X6jSYg== + dependencies: + "@types/html-minifier-terser" "^6.0.0" + html-minifier-terser "^6.0.2" + lodash "^4.17.21" + pretty-error "^4.0.0" + tapable "^2.0.0" + +html-webpack-plugin@^5.5.0: version "5.6.3" resolved "https://registry.npmjs.org/html-webpack-plugin/-/html-webpack-plugin-5.6.3.tgz#a31145f0fee4184d53a794f9513147df1e653685" integrity sha512-QSf1yjtSAsmf7rYBV7XX86uua4W/vkhIt0xNXKbsi2foEeW7vjJQz4bhnpL3xH+l1ryl1680uNv968Z+X6jSYg== @@ -12917,7 +13013,7 @@ joycon@^3.1.1: resolved "https://registry.npmjs.org/joycon/-/joycon-3.1.1.tgz#bce8596d6ae808f8b68168f5fc69280996894f03" integrity sha512-34wB/Y7MW7bzjKRjUKTa46I2Z7eV62Rkhva+KkopW7Qvv/OSWBqvkSY7vusOPrNuZcUG3tApvdVgNB8POj3SPw== -js-base64@^3.7.2, js-base64@^3.7.4: +js-base64@^3.7.2, js-base64@^3.7.4, js-base64@^3.7.7: version "3.7.7" resolved "https://registry.npmjs.org/js-base64/-/js-base64-3.7.7.tgz#e51b84bf78fbf5702b9541e2cb7bfcb893b43e79" integrity sha512-7rCnleh0z2CkXhH67J8K1Ytz0b2Y+yxTPL+/KOJoa20hfnVQ/3/T6W/KflYI4bRHRagNeXeU2bkNGI3v1oS/lw== @@ -13178,6 +13274,11 @@ just-extend@^6.2.0: resolved "https://registry.npmjs.org/just-extend/-/just-extend-6.2.0.tgz#b816abfb3d67ee860482e7401564672558163947" integrity sha512-cYofQu2Xpom82S6qD778jBDpwvvy39s1l/hrYij2u9AMdQcGRpaBu6kY4mVhuno5kJVi1DAz4aiphA2WI1/OAw== +jwt-decode@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/jwt-decode/-/jwt-decode-4.0.0.tgz#2270352425fd413785b2faf11f6e755c5151bd4b" + integrity sha512-+KJGIyHgkGuIq3IEBNftfhW/LfWhXUIY6OmyVWjliu5KH1y0fw7VQ8YndE2O4qZdMSd9SqbnC8GOcZEy0Om7sA== + karma-chrome-launcher@^3.1.0: version "3.2.0" resolved "https://registry.npmjs.org/karma-chrome-launcher/-/karma-chrome-launcher-3.2.0.tgz#eb9c95024f2d6dfbb3748d3415ac9b381906b9a9" @@ -15887,6 +15988,11 @@ pngjs@^5.0.0: resolved "https://registry.npmjs.org/pngjs/-/pngjs-5.0.0.tgz#e79dd2b215767fd9c04561c01236df960bce7fbb" integrity sha512-40QW5YalBNfQo5yRYmiw7Yz6TKKVr3h6970B2YE+3fQpsWcrbj1PzJgxeJ19DRQjhMbKPIuMY8rFaXc8moolVw== +poseidon-lite@^0.2.0: + version "0.2.1" + resolved "https://registry.npmjs.org/poseidon-lite/-/poseidon-lite-0.2.1.tgz#7ad98e3a3aa5b91a1fd3a61a87460e9e46fd76d6" + integrity sha512-xIr+G6HeYfOhCuswdqcFpSX47SPhm0EpisWJ6h7fHlWwaVIvH3dLnejpatrtw6Xc6HaLrpq05y7VRfvDmDGIog== + possible-typed-array-names@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.0.0.tgz#89bb63c6fada2c3e90adc4a647beeeb39cc7bf8f" @@ -18308,7 +18414,16 @@ string-argv@^0.3.1: resolved "https://registry.npmjs.org/string-argv/-/string-argv-0.3.2.tgz#2b6d0ef24b656274d957d54e0a4bbf6153dc02b6" integrity sha512-aqD2Q0144Z+/RqG52NeHEkZauTAUWJO8c6yTftGJKO3Tja5tUgIfmIl6kExvhtxSDP7fXB6DvzkfMpCd/F3G+Q== -"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: +"string-width-cjs@npm:string-width@^4.2.0": + version "4.2.3" + resolved "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: version "4.2.3" resolved "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== @@ -18380,7 +18495,7 @@ string_decoder@~1.1.1: dependencies: safe-buffer "~5.1.0" -"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1: +"strip-ansi-cjs@npm:strip-ansi@^6.0.1": version "6.0.1" resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== @@ -18394,6 +18509,13 @@ strip-ansi@^3.0.1: dependencies: ansi-regex "^2.0.0" +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + strip-ansi@^7.0.1: version "7.1.0" resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45" @@ -20217,7 +20339,7 @@ workerpool@6.2.0: resolved "https://registry.npmjs.org/workerpool/-/workerpool-6.2.0.tgz#827d93c9ba23ee2019c3ffaff5c27fccea289e8b" integrity sha512-Rsk5qQHJ9eowMH28Jwhe8HEbmdYDX4lwoMWshiCXugjtHqMD9ZbiqSDLxcsfdqsETPzVUtX5s1Z5kStiIM6l4A== -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0: +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": version "7.0.0" resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== @@ -20235,6 +20357,15 @@ wrap-ansi@^6.0.1, wrap-ansi@^6.2.0: string-width "^4.1.0" strip-ansi "^6.0.0" +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + wrap-ansi@^8.1.0: version "8.1.0" resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz#56dc22368ee570face1b49819975d9b9a5ead214"