GHSA-M3M8-MRGQ-HF9H
weed admin HTTP server exposes all write operations unauthenticated by default (CWE-306)
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Fuente: GitHub
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Divulgación | Publicada | GHSA-M3M8-MRGQ-HF9H divulgada · CVSS 9.8 (GitHub) | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Summary
The `weed admin` HTTP server (default port 23646) starts with authentication disabled when `-adminPassword` is not supplied. The flag defaults to an empty string, so every deployment that omits it exposes a fully public REST API. Unauthenticated clients can create S3 users, receive plaintext S3 access keys, delete buckets, delete filer files, and trigger plugin jobs. The server binds `0.0.0.0` by default.
Details
Root cause — `weed/command/admin.go` line 436:
authRequired := *options.adminPassword != ""The flag is declared with an empty-string default:
a.adminPassword = cmdAdmin.Flag.String("adminPassword", "", "admin interface password (if empty, auth is disabled)")When `authRequired` is false, `SetupRoutes` in `weed/admin/handlers/admin_handlers.go` registers all API routes with `enforceWrite = false`:
// No authentication required — all routes are public
api := r.PathPrefix("/api").Subrouter()
h.registerAPIRoutes(api, false)Inside `registerAPIRoutes`, every mutating endpoint passes through:
wrapWrite := func(handler http.HandlerFunc) http.Handler {
if !enforceWrite {
return handler // no auth check
}
return dash.RequireWriteAccess()(handler)
}Unauthenticated write paths (partial):
- POST /api/users — create S3 user
- POST /api/users/{u}/access-keys — issue S3 credentials (plaintext in response)
- PUT /api/users/{u}/policies — attach IAM policy
- DELETE /api/users/{u} — delete S3 user
- DELETE /api/s3/buckets/{bucket} — delete bucket
- DELETE /api/files/delete — delete filer file
- POST /api/plugin/job-types/{type}/run — execute plugin job
This is distinct from CVE-2026-72920 (filer gRPC IAM, fixed in 4.24). That covers the filer gRPC port when jwt.filer_signing.key is unset. This covers the admin HTTP server on port 23646, confirmed in v4.45 (current HEAD, commit 9715480).
PoC
Runtime verification mirroring the exact wrapWrite logic:
--- default (no -adminPassword) ---
authRequired = false
POST /api/users -> 200 (no auth required)
POST /api/users/attacker/access-keys -> 200 (credentials issued without auth)
DELETE /api/s3/buckets/critical-data -> 204 (bucket deleted without auth)
--- with -adminPassword=secret ---
authRequired = true
POST /api/users -> 404 (routes locked behind session middleware)Attack against a live instance started without `-adminPassword`:
- POST /api/users {"username":"attacker"} — creates user without credentials
- POST /api/users/attacker/access-keys {} — returns AccessKeyId + SecretAccessKey in plaintext
- Use the returned credentials against the S3 API
Impact
An unauthenticated attacker who can reach port 23646 can create an S3 user, receive its plaintext access key pair, attach administrator IAM policies, and delete any bucket or filer file. Any cloud instance running `weed admin` without `-adminPassword` and without a host firewall blocking port 23646 is fully exposed.
Remediation
- Require a password — refuse to start when `-adminPassword` is empty, or generate a random one and print it once.
- Localhost-only default — change `addr := fmt.Sprintf(":%d", *options.port)` to `addr := fmt.Sprintf("127.0.0.1:%d", *options.port)`.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H — 9.8 Critical
Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.
Desglose de métricas
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
Gogithub.com/seaweedfs/seaweedfs |
Corregida | latest | — | — |
latestArsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/seaweedfs/seaweedfs/security/advisories/GHSA-m3m8-mrgq-hf9hLas referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
