New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@jluboff/cryptofile

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

@jluboff/cryptofile

A file/password encryptor/decryptor module written with native NodeJS modules

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

CyrptoFile

A file/password encryptor/decryptor module written with native NodeJS modules

Installation

npm install cryptofile

Usage

Typescript

import CryptoFile from 'cryptofile';

const cryptoFile = new CryptoFile({ secretKey: 'My32CharacterLongSecretKey123456'}) //Secretkey of length 32 must be provided

// Create encrypted password
const encryptedPassword = cryptoFile.encryptPassword() // Optionally provide password of length 32

// Decrypt hashed password
const decryptedPassword = cryptoFile.decryptPassword(encryptedPassword)

// Create encrypted file
const newFilePathWithExtension = await cryptoFile.encryptFile('../path/to/file') // If filepath was not provided in original instantiation, it must be provided

// Decrypt hashed file
const newFilePathLocation = await cryptoFile.decryptFile({filePath: '../path/to/file'}) //If filepath was not provided in original instantiation, it must be provided

Contributions

Contributions are welcome, please submit a PR which will be reviewed.

Reporting Issues

Please report issues/errors to Github's issue tracker: CryptoFile issue tracker. Include issue, expected behavior, and how to replicate the issue.

License

MIT License

Keywords

encrypt

FAQs

Package last updated on 18 Jan 2022

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