public abstract class KeyGenerator extends Object:
Abstract base class for symmetric key generators.
The primary public AES API is exposed through AESKeyGenerator.
import klyn.cryptography generator as KeyGenerator = AESKeyGenerator() generator.initialize(256) print(generator.generateKey())
| Modifier and Type | Member | Description |
|---|---|---|
| public readonly | algorithmalgorithm as String |
Canonical algorithm name. |
| Modifier and Type | Member | Description |
|---|---|---|
| public | generateKeygenerateKey() as String throws CryptoException: |
Generates a ready-to-use encoded secret key. |
| public static | getInstancegetInstance(algorithm as String) as KeyGenerator throws CryptoException: |
Compatibility factory for dynamic algorithm selection. |
| public | initinit(sizeBits as Int) as Void throws CryptoException: |
Short alias for `initialize`. |
| public | initializeinitialize(sizeBits as Int) as Void throws CryptoException: |
Configures the generated key size. |
| public override | toStringtoString() as String: |
No summary. |