Returns
Type | Description |
---|---|
[]byte | A 32-byte encryption key suitable for use with encrypted indexes |
error | Any error that occurred during key generation |
Security
The generated key is cryptographically secure and suitable for production use:- Uses Go’s
crypto/rand
package for secure random number generation - Provides 256 bits of entropy (32 bytes)
- Compatible with AES-256 encryption used by CyborgDB
This key must be persisted securely. For more information, see Managing Encryption Keys.