Simple JSON encryption/decryption for browser and server communications
This package works with Node.js, Bun, BrowsersIt is unknown whether this package works with Cloudflare Workers, Deno




JSR Score
100%
Published
2 months ago (1.0.1)
Encrypts a JSON object using a simple insertion method
- btoa (base64 encode) the stringified JSON
- Generate a random n-digit key
- Insert the key at a random position in the encoded string
- Append the key length and insertion position at the end
Add Package
deno add jsr:@codesordinate/json-encrypt
Import symbol
import * as json_encrypt from "@codesordinate/json-encrypt";
Import directly with a jsr specifier
import * as json_encrypt from "jsr:@codesordinate/json-encrypt";
Add Package
pnpm i jsr:@codesordinate/json-encrypt
pnpm dlx jsr add @codesordinate/json-encrypt
Import symbol
import * as json_encrypt from "@codesordinate/json-encrypt";
Add Package
yarn add jsr:@codesordinate/json-encrypt
yarn dlx jsr add @codesordinate/json-encrypt
Import symbol
import * as json_encrypt from "@codesordinate/json-encrypt";
Add Package
vlt install jsr:@codesordinate/json-encrypt
Import symbol
import * as json_encrypt from "@codesordinate/json-encrypt";
Add Package
npx jsr add @codesordinate/json-encrypt
Import symbol
import * as json_encrypt from "@codesordinate/json-encrypt";
Add Package
bunx jsr add @codesordinate/json-encrypt
Import symbol
import * as json_encrypt from "@codesordinate/json-encrypt";