doc: add installation example
This commit is contained in:
parent
afac1afbbe
commit
1f58ec30e0
3 changed files with 25 additions and 2 deletions
|
@ -15,7 +15,7 @@ Add `argon2id_elixir` to your list of dependencies in `mix.exs`:
|
|||
```elixir
|
||||
def deps do
|
||||
[
|
||||
{:argon2id_elixir, "~> 0.1.0"}
|
||||
{:argon2id_elixir, "~> 1.1.1"}
|
||||
]
|
||||
end
|
||||
```
|
||||
|
|
|
@ -4,6 +4,29 @@ defmodule Argon2 do
|
|||
|
||||
This module provides a secure way to hash passwords using the Argon2i algorithm.
|
||||
|
||||
## Installation
|
||||
|
||||
Add `argon2` to your list of dependencies in `mix.exs`:
|
||||
|
||||
```
|
||||
def deps do
|
||||
[
|
||||
{:argon2id_elixir, "~> 1.1.1"}
|
||||
]
|
||||
end
|
||||
```
|
||||
|
||||
Ensure you have Rust installed, as it's required for compilation:
|
||||
|
||||
```sh
|
||||
# On Windows
|
||||
winget install Rust.Rust
|
||||
|
||||
# On Unix-like systems (https://rustup.rs/)
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
|
||||
```
|
||||
|
||||
|
||||
## Security Presets
|
||||
|
||||
* `:owasp` (default) - OWASP recommended settings (m=19456, t=2, p=1)
|
||||
|
|
2
mix.exs
2
mix.exs
|
@ -6,7 +6,7 @@ defmodule Argon2.MixProject do
|
|||
def project do
|
||||
[
|
||||
app: :argon2id_elixir,
|
||||
version: "1.1.0",
|
||||
version: "1.1.1",
|
||||
elixir: "~> 1.17",
|
||||
start_permanent: Mix.env() == :prod,
|
||||
deps: deps(),
|
||||
|
|
Loading…
Add table
Reference in a new issue