Mercurial > prosody-modules
annotate mod_auth_http_async/README.md @ 6317:7b693a5539ad
mod_auth_http_async: Update documentation
The required async APIs were included in 0.10.0, but at the time of this
writing we only consider 0.12.x and later supported.
The fallback sync API would have made it work with even earlier
versions, but I don't remember specifically and it doesn't matter.
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Tue, 02 Sep 2025 21:32:01 +0200 |
| parents | fe081789f7b5 |
| children |
| rev | line source |
|---|---|
|
1933
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
1 --- |
|
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
2 labels: |
|
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
3 - Stage-Alpha |
|
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
4 ... |
|
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
5 |
| 1888 | 6 Introduction |
| 7 ============ | |
| 8 | |
|
6317
7b693a5539ad
mod_auth_http_async: Update documentation
Kim Alvefur <zash@zash.se>
parents:
5975
diff
changeset
|
9 This is an authentication module that does an asynchronous |
| 1888 | 10 HTTP call to verify username and password. |
| 11 | |
| 12 Details | |
| 13 ======= | |
| 14 | |
| 15 When a user attempts to authenticate to Prosody, this module takes the | |
| 16 username and password and does a HTTP GET request with [Basic | |
| 17 authentication][rfc7617] to the configured `http_auth_url`. | |
| 18 | |
| 19 Configuration | |
| 20 ============= | |
| 21 | |
|
6317
7b693a5539ad
mod_auth_http_async: Update documentation
Kim Alvefur <zash@zash.se>
parents:
5975
diff
changeset
|
22 After installing, enable the module by setting `authentication` to `"http_async"`. |
|
7b693a5539ad
mod_auth_http_async: Update documentation
Kim Alvefur <zash@zash.se>
parents:
5975
diff
changeset
|
23 |
|
7b693a5539ad
mod_auth_http_async: Update documentation
Kim Alvefur <zash@zash.se>
parents:
5975
diff
changeset
|
24 The only setting is `http_auth_url` which should contain the URL endpoint where the authentication query is sent to. It can contain `$host` and |
|
7b693a5539ad
mod_auth_http_async: Update documentation
Kim Alvefur <zash@zash.se>
parents:
5975
diff
changeset
|
25 `$user` which are substituted for the current VirtualHost and the authenticating username, respectively. |
|
7b693a5539ad
mod_auth_http_async: Update documentation
Kim Alvefur <zash@zash.se>
parents:
5975
diff
changeset
|
26 |
|
1933
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
27 ``` lua |
| 1888 | 28 VirtualHost "example.com" |
| 29 authentication = "http_async" | |
| 30 http_auth_url = "http://example.com/auth" | |
| 31 ``` | |
| 32 | |
|
1933
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
33 Compatibility |
|
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
34 ============= |
|
afba0821f058
mod_auth_http_async/README: Add compatibility info
Kim Alvefur <zash@zash.se>
parents:
1888
diff
changeset
|
35 |
|
6317
7b693a5539ad
mod_auth_http_async: Update documentation
Kim Alvefur <zash@zash.se>
parents:
5975
diff
changeset
|
36 Should work with Prosody 0.10.x and later. |
