# @jluboff/cryptofile

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

Latest version **1.0.0** (published 2022-01-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install @jluboff/cryptofile
pnpm add @jluboff/cryptofile
yarn add @jluboff/cryptofile
bun add @jluboff/cryptofile
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2022-01-18 |
| First published | 2022-01-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 13.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Jason Luboff |
| Maintainers | jluboff |
| Keywords | encrypt, decrypt, nodejs, typescript |

## Links

- npm: https://www.npmjs.com/package/@jluboff/cryptofile
- Repository: https://github.com/JLuboff/CryptoFile
- Homepage: https://github.com/JLuboff/CryptoFile#readme
- Issues: https://github.com/JLuboff/CryptoFile/issues
- npm.io page: https://npm.io/package/@jluboff/cryptofile

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2022-01-18

## README

# CyrptoFile

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

## Installation
    npm install cryptofile

## Usage
Typescript
```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](https://github.com/JLuboff/CyrptoFile/issues).
Include issue, expected behavior, and how to replicate the issue.

## License
[MIT License](https://github.com/JLuboff/CyrptoFile/blob/main/LICENSE)

---
_Source: https://npm.io/package/@jluboff/cryptofile · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
