Module libpasta::primitives [] [src]

Primitive in libpasta refers to the raw hashing algorithms as implemented in many libraries.

The main algorithms here are re-exported for general use. Each algorithm has a new and default function. The former can be provided parameters and creates a new dynamic instance of that parameter set. Whereas the latter refers to a statically referenced parameter set.

All implementations are wrapped in a Primitive struct, which in effect works like a trait, since it derefs to a PrimitiveImpl. This means that whether using a new or default parameter set, the overall behaviour is equivalent.

Structs

Argon2

Parameter set for Argon2.

Bcrypt

bcrypt parameter set.

Hmac

Password storage strengthening using HMAC.

Pbkdf2

Struct holding PBKDF2 parameters.

Primitive

Password hashing primitives

RingPbkdf2

Struct holding PBKDF2 parameters.

Scrypt

Struct holding scrypt parameters.

Traits

PrimitiveImpl

Trait defining the functionality of a hashing primitive.