Skip to content

This is unofficial Node.js porting of TPSecurityUtils included in Piano PHP SDK.

License

Notifications You must be signed in to change notification settings

kodansha/piano-security-utils

Repository files navigation

Piano Security Utils

This is unofficial Node.js porting of TPSecurityUtils.php included in Piano PHP SDK.

Installation

npm install piano-security-utils

or

yarn add piano-security-utils

Usage examples

Decrypt an encrypted webhook data

import { decrypt } from 'piano-security-utils';

const webhookData = '<encrypted webholk data>';
const privateKey = '<your piano private key>';

const result = decrypt(privateKey, webhookData);

Status

The following TPSecurityUtils methods are currently supported:

  • hashCode
  • encrypt
  • urlensafe
  • urldesafe
  • decrypt
  • hashHmacSha1
  • hashHmacSha256
  • hashHmacSha
  • createUserRef

About

This is unofficial Node.js porting of TPSecurityUtils included in Piano PHP SDK.

Resources

License

Stars

Watchers

Forks

Packages

No packages published