Versions in this module Expand all Collapse all v0 v0.0.1 Apr 18, 2025 Changes in this version + type Cryptus interface + Argon2 func(plainText, salt string, extra ...KdfConfig) string + DecryptAes func(cipherText, secret, nonce string) (string, error) + DecryptChacha20 func(cipherText, secret, nonce string) (string, error) + DecryptRsa func(cipherText, privateKey string) (string, error) + EncryptAes func(plainText, secret, nonce string) (string, error) + EncryptChacha20 func(plainText, secret, nonce string) (string, error) + EncryptRsa func(plainText, publicKey string) (string, error) + GenerateNonce func(size int) ([]byte, error) + GenerateNonceString func(size int) string + GenerateRsaKeyPair func(size int) (string, string, error) + ParseRSAPrivateKeyFromPEM func(privateKeyPEM string) (*rsa.PrivateKey, error) + ParseRSAPublicKeyFromPEM func(publicKeyPEM string) (*rsa.PublicKey, error) + Pbkdf2 func(plainText, salt string, extra ...KdfConfig) string + RandomSixDigits func() string + Sha256 func(value string) string + func New() Cryptus + type KdfConfig struct + func NewKdfConfig(options ...KdfOption) KdfConfig + func (k KdfConfig) Iterations() int64 + func (k KdfConfig) Length() int64 + func (k KdfConfig) Memory() int64 + func (k KdfConfig) Threads() int64 + type KdfOption func(*KdfConfig) + func WithIterations(val int64) KdfOption + func WithLength(val int64) KdfOption + func WithMemory(val int64) KdfOption + func WithThreads(val int64) KdfOption