riverrun / comeonin

Password hashing specification for the Elixir programming language

Home Page:https://hex.pm/packages/comeonin

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Length of Hash

thiamsantos opened this issue · comments

What is the length of the hash generated by Pbkdf2? I need this to set the size of the database field.

It depends on the options you use, but for the default options, it is 131. You can check it in the Elixir shell (run iex -S mix):

Comeonin.Pbkdf2.hashpwsalt("") |> byte_size()
131
Comeonin.Pbkdf2.hashpwsalt("", digest: :sha256) |> byte_size()
88

Thanks!