Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/tgcrypto/mod.ts>ctr256

Wasm port of pyrogram/tgcrypto
Go to Latest
function ctr256
import { ctr256 } from "https://deno.land/x/tgcrypto@0.3.3/mod.ts";

Performs CTR-256 encryption/decryption.

Parameters

data: Uint8Array

The data, larger than a byte

key: Uint8Array

32-byte encryption key

iv: Uint8Array

16-byte initialization vector

state: Uint8Array

1-byte state