1.0.2 • Published 1 year ago

data-decr-encr v1.0.2

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Data Encryption Package

This package provides functions for encrypting and decrypting data using the AES encryption algorithm.

Installation

You can install this package via npm:

npm install data-decr-encr

Usage

const { encryptData, decryptData } = require('data-decr-encr');

// Encrypt data
const encrypted = encryptData('Hello, World!');

// Decrypt data
const decrypted = decryptData(encrypted);

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

API

encryptData(data)

Encrypts the provided data using AES encryption algorithm.

  • data (string): The data to encrypt.

Returns the encrypted data in base64 encoding.

decryptData(encryptedData)

Decrypts the provided encrypted data using AES encryption algorithm.

  • encryptedData (string): The encrypted data in base64 encoding.

Returns the decrypted data.

Contributing

Contributions are welcome! Please feel free to submit a pull request or open an issue if you encounter any problems or have suggestions for improvements.

License

This package is licensed under the MIT License. See the LICENSE file for details.

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago