Documentation ¶
Index ¶
- func CheckPasswordHash(password, hash string) bool
- func CreateAes256GcmAead(key []byte) (cipher.AEAD, error)
- func CreatePasswordHash(password string, p *Argon2IDParams) (encodedHash string, err error)
- func CreatePasswordHashWithDefaultParams(password string) (encodedHash string, err error)
- func DecryptAes256(ciphertextBytes []byte, aead cipher.AEAD) (string, error)
- func EncryptAes256(plaintext string, aead cipher.AEAD) ([]byte, error)
- func HashPassword(password string) (string, error)
- func RandomBytes(byteCount uint32) ([]byte, error)
- func RandomString(byteCount uint32) (string, error)
- func ReadRSAPrivateKey(filename string) (*rsa.PrivateKey, error)
- func ReadRSAPublicKey(filename string) (*rsa.PublicKey, error)
- type Argon2IDParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckPasswordHash ¶
func CreateAes256GcmAead ¶ added in v1.3.0
func CreatePasswordHash ¶ added in v1.4.0
func CreatePasswordHash(password string, p *Argon2IDParams) (encodedHash string, err error)
func CreatePasswordHashWithDefaultParams ¶ added in v1.4.0
func DecryptAes256 ¶ added in v1.3.0
func EncryptAes256 ¶ added in v1.3.0
func HashPassword ¶
func RandomBytes ¶ added in v1.4.0
func RandomString ¶ added in v1.4.0
func ReadRSAPrivateKey ¶
func ReadRSAPrivateKey(filename string) (*rsa.PrivateKey, error)
Types ¶
type Argon2IDParams ¶ added in v1.4.0
type Argon2IDParams struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.