
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
A powerful and easy-to-use encryption and encoding library with zero dependencies
A powerful, zero-dependency cryptographic library for Node.js, providing military-grade encryption and comprehensive cryptographic operations with TypeScript support.
npm install cryptoflow
import { CryptoFlow } from 'cryptoflow';
// Symmetric Encryption
const key = CryptoFlow.generateKey();
const encrypted = CryptoFlow.encrypt("sensitive data", key);
const decrypted = CryptoFlow.decrypt(encrypted, key);
// Generate Strong Password
const password = CryptoFlow.generatePassword(16, {
numbers: true,
symbols: true,
uppercase: true,
lowercase: true
});
// Generate encryption key
const key = CryptoFlow.generateKey();
// Encrypt data
const encrypted = CryptoFlow.encrypt("sensitive data", key);
// Decrypt data
const decrypted = CryptoFlow.decrypt(encrypted, key);
// Generate RSA key pair
const keyPair = CryptoFlow.generateRSAKeyPair();
// Encrypt with public key
const encrypted = CryptoFlow.rsaEncrypt("secret message", keyPair.publicKey);
// Decrypt with private key
const decrypted = CryptoFlow.rsaDecrypt(encrypted, keyPair.privateKey);
// Sign data
const signature = CryptoFlow.digitalSign(data, privateKey);
// Verify signature
const isValid = CryptoFlow.verifySignature(data, signature, publicKey);
// ECDH Key Exchange
const alice = CryptoFlow.createECDHKeyExchange();
const bob = CryptoFlow.createECDHKeyExchange();
// Compute shared secret
const aliceShared = alice.computeSecret(bob.publicKey);
const bobShared = bob.computeSecret(alice.publicKey);
// aliceShared equals bobShared
// Generate secure password
const password = CryptoFlow.generatePassword(16, {
numbers: true,
symbols: true,
uppercase: true,
lowercase: true
});
// Derive key from password
const derivedKey = await CryptoFlow.deriveKey("user-password");
// Single hash
const hash = CryptoFlow.hash("data");
// Multiple hash algorithms
const multiHash = CryptoFlow.multiHash("data", ["sha256", "sha512"]);
Secure Data Storage
User Authentication
Secure Communication
Digital Signatures
CryptoFlow is written in TypeScript and includes comprehensive type definitions:
interface PasswordOptions {
numbers?: boolean;
symbols?: boolean;
uppercase?: boolean;
lowercase?: boolean;
}
interface RSAKeyPair {
publicKey: string;
privateKey: string;
}
interface KeyDerivationResult {
key: Buffer;
salt: Buffer;
}
Key Management
Error Handling
try {
const encrypted = CryptoFlow.encrypt(data, key);
} catch (error) {
if (error instanceof CryptoFlowException) {
console.error('Encryption failed:', error.message);
}
}
Secure Configuration
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License - see the LICENSE file for details.
FAQs
A powerful and easy-to-use encryption and encoding library with zero dependencies
We found that cryptoflow demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 0 open source maintainers collaborating on the project.
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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.