A comprehensive command-line tool for performing various cryptographic operations.
- AES-256-GCM - Symmetric encryption/decryption with authenticated encryption
- ED25519 - Digital signature creation and verification
- bcrypt - Password hashing with salt
- Argon2 - Modern password hashing algorithm
- SHA-256 - Data hashing and verification
- ECDH - Elliptic Curve Diffie-Hellman key exchange
- Clone the repository:
git clone https://github.com/zalaghi-dev/crypto-lab.git
cd crypto-lab- Install dependencies:
pnpm install- Build the project:
pnpm run buildRun without parameters to enter interactive mode:
pnpm run dev:cliThe CLI will guide you through:
- Method selection (AES-256-GCM, ED25519, bcrypt, etc.)
- Operation selection (Encrypt/Decrypt, Sign/Verify, Hash/Verify)
- Data input
- Key/Password input
You can also pass arguments directly:
pnpm run dev:cli [method] [operation] [text] [key]pnpm run dev:cli
# Choose: AES-256-GCM → Encrypt
# Input: "Hello World"
# Password: "mypassword"pnpm run dev:cli
# Choose: ED25519 → Sign
# Input: "Important message"pnpm run dev:cli
# Choose: bcrypt → Hash
# Input: "mypassword"pnpm run build- Build the projectpnpm run dev:cli- Run CLI in development modepnpm run cli- Run CLI with built filespnpm run lint- Run ESLintpnpm run format- Format code with Prettier
src/
├── commands/ # CLI commands
├── services/ # Cryptographic services
├── questions/ # Interactive prompts
├── types/ # TypeScript type definitions
└── main.ts # Application entry point
Unlicensed