Medium, CVSS 6.5GoPublished
GoDoxy has a Path Traversal Vulnerability in its File API
CVE-2026-33528 · GHSA-4753-cmc8-8j9v
- Affected
- Go github.com/yusing/godoxy < 0.27.5
- Fixed in
- 0.27.5· Vendor fix available
- Issue
- The file content API endpoint at /api/v1/file/content is vulnerable to path traversal. The filename query parameter is passed directly to path.Join(common.ConfigBasePath, filename) where ConfigBasePath = "config" (a relative path). No sanitization or validation is applied beyond checking that the field is non-empty (binding:"required"). An authenticated attacker can use ../ sequences to read or write files outside the intended config/ directory, including TLS private keys, OAuth refresh tokens, and any file accessible to the container's UID. Root Cause File: internal/api/v1/file/get.go, lines 68-73: - common.ConfigBasePath = "config" — relative path, not absolute - path.Join("config", "../certs/key.pem") normalizes to "certs/key.pem" — escaping config/ - No call to strings.HasPrefix, filepath.Rel, or any containment check exists - The format:"filename" struct tag is an OpenAPI/Swagger annotation only, not enforced by the validator Proof of Concept Environment - GoDoxy v0.27.4…
Recommended action: Upgrade to 0.27.5 or later, then redeploy and verify.A vendor fix does not resolve your finding until you verify it in your own systems.