package crypt

Import Path
	go.pact.im/x/crypt (on go.dev)

Dependency Relation
	imports 11 packages, and imported by 0 packages

Involved Source Files argon2.go builtin.go Package crypt provides a UNIX crypt-style API for password hashing using structured hashes in PHC format. # Built-in functions This package provides the built-in implementations for widely used password hashing algorithms with reasonable default parameter values. ## Argon2 Argon2 implementation supports Argon2i and Argon2id variants, and requires explicit memory, iterations and parallelism parameters. $argon2<variant>[$v=<version>]$m=<memory>,t=<iterations>,p=<parallelism>[$<salt>[$<hash>]]
Package-Level Type Names (total 4, in which 1 are exported)
/* sort exporteds by: | */
Crypter is a UNIX crypt-like API that can be used both for password registration, and for password verification. Crypt computes the hash of password string k using the given hash parameters. Applying Crypt to the returned hash is deterministic, that is, it always returns the same result that is equal to the returned hash. If h contains a salt string without output, then Crypt computes a hash output whose length is the default output length for the specified hash algorithm. The resulting hash contains a strict, deterministic encoding of the used parameters, salt and output. If h does not contain salt (and therefore output), then it generates a new new appropriate salt value as mandated by the specified hash algorithm using the defined default salt length, and then proceeds as in the previous case. If h contains hash function output, then it computes an output with exactly the same length as the one provided in the input. It returns the exact parameters and salt as they were received, and the newly computed output. Basically, it recomputes hash output for password verification. func Argon2() Crypter func Default() Crypter
Package-Level Functions (total 2, both are exported)
Argon2 returns the default Crypter implementation for Argon2i and Argon2id functions.
Default returns the default Crypter implementation.
Package-Level Variables (total 4, none are exported)
Package-Level Constants (total 2, neither is exported)