You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
407 B
17 lines
407 B
6 years ago
|
declare module 'aes-js' {
|
||
|
export class Counter {
|
||
|
constructor(iv: Buffer);
|
||
|
setValue(value: number): void;
|
||
|
setBytes(bytes: Array<number> | Buffer | string): void;
|
||
|
increment(): void;
|
||
|
}
|
||
|
|
||
|
class CTR {
|
||
|
constructor(derivedKey: Buffer, iv: Counter);
|
||
|
encrypt(bytes: Buffer): Uint8Array;
|
||
|
decrypt(bytes: Buffer): Uint8Array;
|
||
|
}
|
||
|
|
||
|
export const ModeOfOperation: { ctr: typeof CTR };
|
||
|
}
|