Socket
Socket
Sign inDemoInstall

browserify-des

Package Overview
Dependencies
5
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

browserify-des

browserify-des ===


Version published
Maintainers
1
Weekly downloads
8,011,846
decreased by-8.82%

Weekly downloads

Package description

What is browserify-des?

The browserify-des package is a module that allows you to use DES (Data Encryption Standard) encryption and decryption in your Browserify projects. It is a browser-friendly version of the DES algorithm, which is a symmetric-key algorithm for the encryption of electronic data.

What are browserify-des's main functionalities?

DES Encryption

This feature allows you to encrypt data using the DES algorithm. The code sample demonstrates how to create a DES cipher in ECB mode, encrypt a text message, and output the encrypted data in hexadecimal format.

const crypto = require('crypto');
const browserifyDES = require('browserify-des');

const key = Buffer.from('0123456789abcdef', 'hex');
const data = Buffer.from('Hello, World!');

const cipher = browserifyDES.createCipheriv('des-ecb', key, null);
let encrypted = cipher.update(data, 'utf8', 'hex');
encrypted += cipher.final('hex');

console.log('Encrypted:', encrypted);

DES Decryption

This feature allows you to decrypt data that was previously encrypted using the DES algorithm. The code sample shows how to create a DES decipher in ECB mode, decrypt the encrypted hexadecimal data, and output the original text message.

const crypto = require('crypto');
const browserifyDES = require('browserify-des');

const key = Buffer.from('0123456789abcdef', 'hex');
const encryptedData = 'e5fa44f2b31c1fb553b6021e7360d07d';

const decipher = browserifyDES.createDecipheriv('des-ecb', key, null);
let decrypted = decipher.update(encryptedData, 'hex', 'utf8');
decrypted += decipher.final('utf8');

console.log('Decrypted:', decrypted);

Other packages similar to browserify-des

Readme

Source

browserify-des

Build Status

DES for browserify

FAQs

Last updated on 10 Jul 2018

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc