Creates a new EncryptionHelper instance.
Password or key material for encryption
Optionalcrypto: CryptoInterfaceOptional custom crypto implementation (defaults to WebCrypto API)
Key derivation mode:
Encrypts a string using AES-256-GCM.
Each encryption uses a unique random IV (Initialization Vector), so encrypting the same data twice produces different ciphertext.
Plaintext string to encrypt
Encrypted data as hex string in format: "iv|ciphertext"
Decrypts a string that was encrypted with the encrypt() method.
Encrypted data in "iv|ciphertext" hex format
Decrypted plaintext string
Helper class for encrypting and decrypting data using AES-256-GCM.
Features:
Example