feat: add support for migu3d formats

This commit is contained in:
鲁树人
2023-05-27 00:47:00 +01:00
parent 5680e08c4a
commit 39eefd9117
5 changed files with 25 additions and 6 deletions

View File

@@ -0,0 +1,15 @@
import { transformBlob } from '~/decrypt-worker/util/transformBlob';
import type { CryptoBase } from '../CryptoBase';
export class MiguCrypto implements CryptoBase {
cryptoName = 'Migu3D/Keyless';
checkByDecryptHeader = true;
async decrypt(buffer: ArrayBuffer): Promise<Blob> {
return transformBlob(buffer, (p) => p.make.Migu3D());
}
public static make() {
return new MiguCrypto();
}
}