New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

enjoys_encrypt-decrypt

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

enjoys_encrypt-decrypt

This is custom library alternative of JWT which is used to encrypt/decrypt data for security purposes

  • 1.0.0
  • unpublished
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

encrypt-decrypt-npm-package-enjoys

Developer : Mulayam
Before implementing Please Provide A Secret Key in environment variable (.env File with name) if not this env variable not found then package will use default encryption key.
IN .ENV FILE
ENCRYPTION_KEY = "YOUR SECRET KEY" or also you can do this

OR Manual Pass of ENRCYPTION KEY


`const { ENCRYPTION_KEY } require('@enjoys/encrypt-decrypt') ENCRYPTION_KEY('YOUR SECRET KEY') `
#Documentation
#ENCRYPTION OF DATA `const {MAKE} require('@enjoys/encrypt-decrypt')` ES5 Syntax (CommonJS)
OR
`import {MAKE} from('@enjoys/encrypt-decrypt')` ES6 Syntax
`let NewObj= 'pass your data here' || {user:"demo",password:"12345678"` #
`let EncryptedData = MAKE(NewObj)`
This will return a encrypted/hash random generated string with your data and encryption key.
`Output : 074e48c8e3c0bc19f9e22dd7570037392e5d0bf80cf9dd51bb7808872a511b3`
You can also pass second parameter for its length to make it more secure.The Default length is 16.
`let EncryptedData = MAKE(NewObj,64)`
# DECRYPTION OF DATA

let DecryptData = '074e48c8e3c0bc19f9e22dd7570037392e5d0bf80cf9dd51bb7808872a511b3'
Also can use Destructing Method let {user,password} = EncryptedData

Keywords

FAQs

Package last updated on 18 Feb 2023

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