Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update #1791

Merged
merged 3 commits into from
Feb 19, 2024
Merged

update #1791

Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Prev Previous commit
chore: update
  • Loading branch information
helloplhm-qwq committed Feb 19, 2024
commit 34768bb4b18dd3f62269fce95d90a418dc9a4204
12 changes: 1 addition & 11 deletions src/renderer/utils/musicSdk/kw/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -193,19 +193,9 @@ const createAesDecrypt = (buffer, mode, key, iv) => {
return Buffer.concat([cipher.update(buffer), cipher.final()])
}

const strToUint8Array = str => {
const length = Math.floor(str.length / 2)
const bArr = new Uint8Array(length)
for (let i = 0; i < length; i++) {
const i2 = i * 2
bArr[i] = parseInt(str.substring(i2, i2 + 2), 16)
}
return bArr
}

export const wbdCrypto = {
aesMode: 'aes-128-ecb',
aesKey: strToUint8Array('7057273DC7FA29BF39442D72DD5E8CE4'),
aesKey: Buffer.from([112, 87, 39, 61, 199, 250, 41, 191, 57, 68, 45, 114, 221, 94, 140, 228], 'binary'),
aesIv: '',
appId: 'y67sprxhhpws',
decodeData(base64Result) {
Expand Down