Documentation
¶
Overview ¶
Package drupal provides verification of passwords hashed using the Drupal 7 password hashing method.
This verifier handles Drupal 7 password hashes that start with $S$ and uses SHA-512 with a custom iteration count and base64 encoding scheme. Note that while more secure than traditional MD5, this is still considered a legacy algorithm for modern applications. See original implementation at https://api.drupal.org/api/drupal/includes!password.inc/function/_password_crypt/7.x
Index ¶
Constants ¶
View Source
const ( Identifier = "$S$" HashLength = 55 Format = "%s%s%s%s" )
View Source
const ( DefaultMinIterations = 1000 DefaultMaxIterations = 500000 )
Variables ¶
View Source
var DefaultValidationOpts = &ValidationOpts{ MinIterations: DefaultMinIterations, MaxIterations: DefaultMaxIterations, }
Functions ¶
This section is empty.
Types ¶
type ValidationOpts ¶ added in v0.12.0
type Verifier ¶
type Verifier struct {
// contains filtered or unexported fields
}
func NewVerifier ¶ added in v0.12.0
func NewVerifier(opts *ValidationOpts) *Verifier
Click to show internal directories.
Click to hide internal directories.