From 1111aaf3b78cc4dab007659db8b6b78e0516013b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=B2=81=E6=A0=91=E4=BA=BA?= Date: Wed, 15 Dec 2021 18:22:05 +0000 Subject: [PATCH] chore: Use QMC2-Crypto with embedded WASM build from 0.0.5-R3 (cherry picked from commit 9448b497ed6b80e41f0e9f731f1ffa1e56fb149a) --- package-lock.json | 15 ++++++++------- package.json | 2 +- src/decrypt/qmcv2.ts | 2 +- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/package-lock.json b/package-lock.json index 8fece58..506e033 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7,10 +7,11 @@ "": { "name": "unlock-music", "version": "v1.9.1", + "hasInstallScript": true, "license": "MIT", "dependencies": { "@babel/preset-typescript": "^7.16.5", - "@jixun/qmc2-crypto": "^0.0.5-R2", + "@jixun/qmc2-crypto": "^0.0.5-R3", "base64-js": "^1.5.1", "browser-id3-writer": "^4.4.0", "core-js": "^3.16.0", @@ -2983,9 +2984,9 @@ } }, "node_modules/@jixun/qmc2-crypto": { - "version": "0.0.5-R2", - "resolved": "https://registry.npmjs.org/@jixun/qmc2-crypto/-/qmc2-crypto-0.0.5-R2.tgz", - "integrity": "sha512-omrsnXSx7BpOCY8Yla+xwil0bYz/4sj3qEFy4hu4JL/ujeWMzASKq9WnW+UHfSnLUw6EGstub+CoSXrFeRDfqQ==" + "version": "0.0.5-R3", + "resolved": "https://registry.npmjs.org/@jixun/qmc2-crypto/-/qmc2-crypto-0.0.5-R3.tgz", + "integrity": "sha512-Wgf0EpmIMY8iKIp56KYR4DkFccSvvTI6Z5MHzW2cpwzDvb2fbTFcEtaVujNd+6A23O+6GfPjiTToiFFf+3pJyw==" }, "node_modules/@mrmlnc/readdir-enhanced": { "version": "2.2.1", @@ -23155,9 +23156,9 @@ } }, "@jixun/qmc2-crypto": { - "version": "0.0.5-R2", - "resolved": "https://registry.npmjs.org/@jixun/qmc2-crypto/-/qmc2-crypto-0.0.5-R2.tgz", - "integrity": "sha512-omrsnXSx7BpOCY8Yla+xwil0bYz/4sj3qEFy4hu4JL/ujeWMzASKq9WnW+UHfSnLUw6EGstub+CoSXrFeRDfqQ==" + "version": "0.0.5-R3", + "resolved": "https://registry.npmjs.org/@jixun/qmc2-crypto/-/qmc2-crypto-0.0.5-R3.tgz", + "integrity": "sha512-Wgf0EpmIMY8iKIp56KYR4DkFccSvvTI6Z5MHzW2cpwzDvb2fbTFcEtaVujNd+6A23O+6GfPjiTToiFFf+3pJyw==" }, "@mrmlnc/readdir-enhanced": { "version": "2.2.1", diff --git a/package.json b/package.json index 0c98831..42d3d4c 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,7 @@ }, "dependencies": { "@babel/preset-typescript": "^7.16.5", - "@jixun/qmc2-crypto": "^0.0.5-R2", + "@jixun/qmc2-crypto": "^0.0.5-R3", "base64-js": "^1.5.1", "browser-id3-writer": "^4.4.0", "core-js": "^3.16.0", diff --git a/src/decrypt/qmcv2.ts b/src/decrypt/qmcv2.ts index 17b00cf..fc7f7d8 100644 --- a/src/decrypt/qmcv2.ts +++ b/src/decrypt/qmcv2.ts @@ -1,4 +1,4 @@ -import QMCCryptoModule from '@jixun/qmc2-crypto'; +import QMCCryptoModule from '@jixun/qmc2-crypto/QMC2-wasm-bundle'; // EOF Magic detection. const DETECTION_SIZE = 40;