Skip to main content
Module

x/dtils/encryption.ts>encryptAsymmetrically

The best unofficial library of utilities for Deno applications
Go to Latest
function encryptAsymmetrically
import { encryptAsymmetrically } from "https://deno.land/x/dtils@2.4.0/encryption.ts";

Asymmetrically encrypt plainBytes using a base64 encoded publicKey. Function will error if publicKey is not an RSA public key

Parameters

publicKey: string
plainBytes: Uint8Array

Returns

Promise<Uint8Array>