Skip to content

handshakejs/handshakejscrypter

Repository files navigation

handshakejscrypter

handshakejscrypter

BuildStatus

Utility to encrypt and decrypt sensitive data for handshakejs. Code largely taken from here.

This library is part of the larger Handshake.js ecosystem.

Usage

package main

import (
  "fmt"
  "github.com/handshakejs/handshakejscrypter"
)

func main() {
  handshakejscrypter.Setup("somesecretsaltthatis32characters") // 32 bytes

  ciphertext := handshakejscrypter.Encrypt("some text to encrypt")
  fmt.Println(ciphertext)

  plaintext := handshakejscrypter.Decrypt(ciphertext)
  fmt.Println(plaintext)
}

About

Utility to encrypt and decrypt sensitive data for handshakejs.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages