mirror of
https://github.com/caddyserver/website.git
synced 2025-04-26 15:06:17 -04:00
Update docs for 2.6
This commit is contained in:
parent
c67668615e
commit
2ab3061111
12 changed files with 158 additions and 78 deletions
|
@ -19,15 +19,15 @@ After a successful authentication, the `{http.auth.user.id}` placeholder will be
|
|||
|
||||
```caddy-d
|
||||
basicauth [<matcher>] [<hash_algorithm> [<realm>]] {
|
||||
<username> <hashed_password_base64> [<salt_base64>]
|
||||
<username> <hashed_password> [<salt_base64>]
|
||||
...
|
||||
}
|
||||
```
|
||||
|
||||
- **<hash_algorithm>** is the name of the password hashing algorithm (or KDF) used for the hashes in this configuration. Can be `bcrypt` (default) or `scrypt`.
|
||||
- **<hash_algorithm>** is the name of the password hashing algorithm (or KDF) used for the hashes in this configuration. Default: `bcrypt`
|
||||
- **<realm>** is a custom realm name.
|
||||
- **<username>** is a username or user ID.
|
||||
- **<hashed_password_base64>** is the base-64 encoding of the hashed password.
|
||||
- **<hashed_password>** is the password hash.
|
||||
- **<salt_base64>** is the base-64 encoding of the password salt, if an external salt is required.
|
||||
|
||||
|
||||
|
@ -37,7 +37,7 @@ Protect all resources in /secret so only Bob can access them with the password "
|
|||
|
||||
```caddy-d
|
||||
basicauth /secret/* {
|
||||
Bob JDJhJDEwJEVCNmdaNEg2Ti5iejRMYkF3MFZhZ3VtV3E1SzBWZEZ5Q3VWc0tzOEJwZE9TaFlZdEVkZDhX
|
||||
Bob $2a$14$Zkx19XLiW6VYouLHR5NmfOFU0z2GTNmpkT/5qqR7hx4IjWJPDhjvG
|
||||
}
|
||||
```
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue