docs(auth): warn about a wrong or too-wide trusted proxy list
CI / Format and clippy (pull_request) Successful in 6m12s
CI / Dependency audit (pull_request) Successful in 15s
CI / Docker image (build and smoke test) (pull_request) Successful in 9m3s
CI / Tests (Linux) (pull_request) Successful in 15m33s

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Lucas RayanandClaude Opus 5.5 committed 2026-11-05 07:01:16 -03:00
1 parent 9ef86ac425
commit 4f3091d963
4 files changed
+9 -2

No files matched your search

+3
View File
@@ -44,6 +44,9 @@ reproduction when a private channel is available.
and `acaua auth reset` clears the budget; an attacker still running can spend it and `acaua auth reset` clears the budget; an attacker still running can spend it
again. Up to 100 guesses a day per account remain possible, so long passwords again. Up to 100 guesses a day per account remain possible, so long passwords
matter, and MFA remains recommended for analysts. matter, and MFA remains recommended for analysts.
These limits trust the client address: a wrong `ACAUA_TRUSTED_PROXIES` makes every
client look like one address, which removes the cap and can share lockouts, and a
too-wide one lets clients forge `X-Forwarded-For`.
Crossing the budget writes one `login.budget_exhausted` audit event per account Crossing the budget writes one `login.budget_exhausted` audit event per account
per 24 hours; a username with no account writes none. The audit log has no rotation yet: failed logins add to it, so watch per 24 hours; a username with no account writes none. The audit log has no rotation yet: failed logins add to it, so watch
its size on an exposed instance. Budgets of real accounts survive a restart; its size on an exposed instance. Budgets of real accounts survive a restart;
+4
View File
@@ -45,6 +45,10 @@ mínima quando o canal privado estiver estabelecido.
continuam funcionando, e `acaua auth reset` zera a cota; um atacante ainda ativo continuam funcionando, e `acaua auth reset` zera a cota; um atacante ainda ativo
pode gastá-la de novo. Continuam possíveis até 100 palpites por dia por conta, pode gastá-la de novo. Continuam possíveis até 100 palpites por dia por conta,
então senhas longas importam, e o MFA continua recomendado para analistas. então senhas longas importam, e o MFA continua recomendado para analistas.
Esses limites confiam no endereço do cliente: um `ACAUA_TRUSTED_PROXIES` errado faz
todos os clientes parecerem um só endereço, o que elimina o limite e pode
compartilhar bloqueios, e um amplo demais permite que clientes forjem
`X-Forwarded-For`.
Esgotar a cota grava um evento de auditoria `login.budget_exhausted` por conta a Esgotar a cota grava um evento de auditoria `login.budget_exhausted` por conta a
cada 24 horas; um usuário inexistente não grava nenhum. O log de auditoria ainda não tem rotação: logins com falha o fazem cada 24 horas; um usuário inexistente não grava nenhum. O log de auditoria ainda não tem rotação: logins com falha o fazem
crescer, então acompanhe o tamanho dele em uma instância exposta. A cota de contas crescer, então acompanhe o tamanho dele em uma instância exposta. A cota de contas
+1 -1
View File
@@ -74,7 +74,7 @@ restart (`docker compose restart acaua`), which prints a new one.
|---|---| |---|---|
| `local` | Plain HTTP, loopback only. `ACAUA_PUBLISH` must be `127.0.0.1` or `[::1]`; the daemon refuses to start if `ACAUA_PUBLISHED` is anything else. Outside a container it also refuses a non-loopback `--bind`; the image sets `ACAUA_RUNTIME=container`, where `ACAUA_PUBLISHED` is the control. | | `local` | Plain HTTP, loopback only. `ACAUA_PUBLISH` must be `127.0.0.1` or `[::1]`; the daemon refuses to start if `ACAUA_PUBLISHED` is anything else. Outside a container it also refuses a non-loopback `--bind`; the image sets `ACAUA_RUNTIME=container`, where `ACAUA_PUBLISHED` is the control. |
| `tls` | The daemon terminates HTTPS. Set `ACAUA_TLS_CERT` and `ACAUA_TLS_KEY` and mount the certificate and key in the container with a compose override; `--bind` must be an `IP:port`. | | `tls` | The daemon terminates HTTPS. Set `ACAUA_TLS_CERT` and `ACAUA_TLS_KEY` and mount the certificate and key in the container with a compose override; `--bind` must be an `IP:port`. |
| `proxy` | An HTTPS reverse proxy sits in front. Set `ACAUA_TRUSTED_PROXIES` to its address as CIDRs. The daemon port must be reachable only by the proxy. A wrong value makes every client appear as one address, which removes the failure budget's protection and can share lockouts between users. | | `proxy` | An HTTPS reverse proxy sits in front. Set `ACAUA_TRUSTED_PROXIES` to its address as CIDRs. The daemon port must be reachable only by the proxy. A wrong value makes every client appear as one address, which removes the failure budget's protection and can share lockouts between users. A too-wide value lets clients forge `X-Forwarded-For` and spend budgets or pose as a known address. |
**Limits worth knowing.** A bare `docker run -p 0.0.0.0:8787:8787` without **Limits worth knowing.** A bare `docker run -p 0.0.0.0:8787:8787` without
`ACAUA_PUBLISHED` is not detected by `local` mode; login still protects the `ACAUA_PUBLISHED` is not detected by `local` mode; login still protects the
+1 -1
View File
@@ -75,7 +75,7 @@ imprime outro.
|---|---| |---|---|
| `local` | HTTP puro, só em loopback. `ACAUA_PUBLISH` deve ser `127.0.0.1` ou `[::1]`; o daemon recusa iniciar se `ACAUA_PUBLISHED` for outro. Fora de container também recusa um `--bind` que não seja loopback; a imagem define `ACAUA_RUNTIME=container`, onde o controle é `ACAUA_PUBLISHED`. | | `local` | HTTP puro, só em loopback. `ACAUA_PUBLISH` deve ser `127.0.0.1` ou `[::1]`; o daemon recusa iniciar se `ACAUA_PUBLISHED` for outro. Fora de container também recusa um `--bind` que não seja loopback; a imagem define `ACAUA_RUNTIME=container`, onde o controle é `ACAUA_PUBLISHED`. |
| `tls` | O daemon termina o HTTPS. Defina `ACAUA_TLS_CERT` e `ACAUA_TLS_KEY` e monte o certificado e a chave no container por um override do compose; `--bind` deve ser `IP:porta`. | | `tls` | O daemon termina o HTTPS. Defina `ACAUA_TLS_CERT` e `ACAUA_TLS_KEY` e monte o certificado e a chave no container por um override do compose; `--bind` deve ser `IP:porta`. |
| `proxy` | Um proxy reverso HTTPS fica na frente. Defina `ACAUA_TRUSTED_PROXIES` com o endereço dele em CIDR. A porta do daemon deve ser acessível somente pelo proxy. Um valor errado faz todos os clientes parecerem um só endereço, o que elimina a proteção da cota de falhas e pode compartilhar bloqueios entre usuários. | | `proxy` | Um proxy reverso HTTPS fica na frente. Defina `ACAUA_TRUSTED_PROXIES` com o endereço dele em CIDR. A porta do daemon deve ser acessível somente pelo proxy. Um valor errado faz todos os clientes parecerem um só endereço, o que elimina a proteção da cota de falhas e pode compartilhar bloqueios entre usuários. Um valor amplo demais permite que clientes forjem `X-Forwarded-For` e gastem cotas ou se passem por um endereço conhecido. |
**Limites que vale conhecer.** Um `docker run -p 0.0.0.0:8787:8787` direto, sem **Limites que vale conhecer.** Um `docker run -p 0.0.0.0:8787:8787` direto, sem
`ACAUA_PUBLISHED`, não é detectado pelo modo `local`; o login continua protegendo `ACAUA_PUBLISHED`, não é detectado pelo modo `local`; o login continua protegendo