@fusedb/crypto
v0.0.1
Published
A FUSE middleware to handle data encryption.
Downloads
5
Maintainers
Readme
🧩 FUSE Middleware: Crypto
A FUSE middleware that provides AES encryption to your data
📦 Installation
npm install @fusedb/core
npm install @fusedb/crypto🚀 Usage
const FUSE = require("@fusedb/core");
const JSONDriver = require("@fusedb/json");
const Crypto = require("@fusedb/crypto");
const db = new FUSE({
driver: new JSONDriver({ path: "./data.json" }),
middleware: [
new Crypto({
key: process.env.DB_KEY || "12345678901234567890123456789012",
})
]
});⚙️ Options
| Option | Type | Description |
| ------ | ----- | --------------------------------------------- |
| key | string | A 32 character long string for the encryption key |
✅ Features
- ✅ Works with any FUSE driver
- ✅ Compatible with
.get(),.set(),.bulkSet(), etc. - ✅ AES-256-GCM encryption
📚 Related
🤝 Contributing
Want to make your own middleware?
- Name it like:
fusedb-<name>or@your-org/fusedb-<name> - Follow the Middleware Guidelines
Feel free to share your plugin with the community!
🧾 License
Licensed under the Apache-2.0.
