Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@brixtol/cryptographer

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@brixtol/cryptographer

Encrypt and decrypt strings, numbers and objects

  • 0.3.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

@brixtol/cryptographer

Cryptographer with IV used for encryption and decryption of various data types with crypto. Uses an aes-256-gcm algorithm and supports multiple ciphers.

Why?

For encryption/decryption of sensitive data sent across the wire and processed within serverless functions. We opened sourced the package which is merely a wrapper for encryption/decryption with Crypto.

Install

pnpm add @brixtol/cryptographer

Usage

import { Cryptographer, md5 } from "@brixtol/cryptographer";

const crypto = Cryptographer(
  secret: "secret"
  , algorithm?: "aes-256-ctr"
  , options?: CipherCCMOptions
);

// Encoding
crypto.encode({ foo: "bar" });

// Decoding, eg: { foo: "bar" }
crypto.decode("12345678910abcdefghijkmnopqrstuvwxyz");

// Create a md5 hash
md5('hello world') // => 5eb63bbbe01eeed093cb22bb8f5acdc3

Ciphers

  • aes-256-cbc
  • aes-256-cbc-hmac-sha1
  • aes-256-cbc-hmac-sha256
  • aes-256-cfb
  • aes-256-cfb1
  • aes-256-cfb8
  • aes-256-ctr
  • aes-256-ofb
  • aes256
  • camellia256

License

Licensed under MIT


We open source!

FAQs

Package last updated on 04 Oct 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc