mirror of
https://git.um-react.app/um/um-react.git
synced 2025-11-28 03:23:02 +00:00
fix: support files that were not encrypted (e.g. kgma), close #36
This commit is contained in:
14
src/decrypt-worker/crypto/transparent/transparent.ts
Normal file
14
src/decrypt-worker/crypto/transparent/transparent.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import type { CryptoBase } from '../CryptoBase';
|
||||
|
||||
export class TransparentCrypto implements CryptoBase {
|
||||
cryptoName = 'Transparent';
|
||||
checkByDecryptHeader = true;
|
||||
|
||||
async decrypt(buffer: ArrayBuffer): Promise<Blob> {
|
||||
return new Blob([buffer]);
|
||||
}
|
||||
|
||||
public static make() {
|
||||
return new TransparentCrypto();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user