{"schema":"threatline.record/2","record":{"id":"CVE-2026-84321","aliases":["GHSA-wq4w-vwvq-q3x9","GO-2026-6801"],"summary":"Nginx UI: Standalone short tokens survive administrative revocation in cache and authenticate again after account re-enable","details":"### Summary\nStandalone short tokens issued for WebSocket and explicit-token authentication can survive administrative revocation in cache. If the same account is later re-enabled before the cache entry expires, the deleted short token becomes valid again.\n\n### Details\n`GenerateShortToken()` creates an `AuthToken` row that contains only `ShortToken` and no long `Token`. `DeleteUserTokens()` removes database rows, but when clearing caches it only invalidates entries where `authToken.Token != \"\"`. This leaves standalone short-token cache entries behind. `GetTokenUserByShortToken()` checks that cache first and then loads the user by ID, so the stale short token becomes usable again if the account status is restored to `true`.\n\nRelevant code paths:\n- [internal/user/user.go](/home/kali/Desktop/bounty/nginx-ui/internal/user/user.go:43)\n- [internal/user/user.go](/home/kali/Desktop/bounty/nginx-ui/internal/user/user.go:118)\n- [internal/user/user.go](/home/kali/Desktop/bounty/nginx-ui/internal/user/user.go:204)\n- [api/user/short_token.go](/home/kali/Desktop/bounty/nginx-ui/api/user/short_token.go:13)\n- [internal/middleware/middleware.go](/home/kali/Desktop/bounty/nginx-ui/internal/middleware/middleware.go:82)\n\n### PoC\nThis was verfied locally in an isolated environment with a temporary package-level harness that exercised the real token issuance, revocation, cache, and re-authentication paths.\n\nWhat the executed test did:\n1. Created an enabled user in a temporary SQLite database.\n2. Called the real `GenerateShortToken(user.ID)` function to issue a standalone short token.\n3. Verified that the token authenticated successfully and was present in the short-token cache.\n4. Disabled the user and called the real `DeleteUserTokens(user.ID)` function.\n5. Verified that the database token rows were removed.\n6. Verified that the short-token cache entry still existed after `DeleteUserTokens`.\n7. Re-enabled the same user.\n8. Reused the previously deleted short token via the real `GetTokenUserByShortToken()` path and observed successful authentication.\n\nObserved result from the actual local verification:\n- The database token rows were removed during revocation.\n- The short-token cache entry remained present.\n- Re-enabling the user restored successful authentication through the stale short token.\n\n### Impact\nAny deployment using standalone short tokens is affected. If a short token is stolen, administrative disable/delete-token handling may not fully revoke it. Re-enabling the account within the cache lifetime restores access for the stale token to any HTTP or WebSocket routes that accept short-token authentication.","categories":["Web servers"],"product":"github.com/0xJacky/Nginx-UI","vendor":"0xJacky","ecosystem":"go","affected_ranges":[{"source":"GitHub Advisory Database","source_url":"https://github.com/advisories/GHSA-wq4w-vwvq-q3x9","source_modified_at":"2026-10-15T20:14:02Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"go","name":"github.com/0xJacky/Nginx-UI"},"range":"< 1.9.10-0.20260703131214-23d1934099b0"},{"source":"CVE List","source_url":"https://www.cve.org/CVERecord?id=CVE-2026-84321","source_modified_at":"2026-10-13T15:50:29.123Z","fetched_at":"2026-10-23T18:45:31.882637Z","product":"nginx-ui","vendor":"0xJacky","versions":[{"version":"< 2.4.1","status":"affected"}],"defaultStatus":null},{"source":"OSV","source_url":"https://osv.dev/vulnerability/GHSA-wq4w-vwvq-q3x9","source_modified_at":"2026-10-19T21:41:20.936879864Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"Go","name":"github.com/0xJacky/Nginx-UI","purl":"pkg:golang/github.com/0xJacky/Nginx-UI"},"ranges":[{"events":[{"introduced":"0"},{"fixed":"1.9.10-0.20260703131214-23d1934099b0"}],"type":"SEMVER"}],"versions":[]}],"fixed_versions":[{"source":"GitHub Advisory Database","source_url":"https://github.com/advisories/GHSA-wq4w-vwvq-q3x9","source_modified_at":"2026-10-15T20:14:02Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"go","name":"github.com/0xJacky/Nginx-UI"},"version":"1.9.10-0.20260703131214-23d1934099b0"},{"source":"OSV","source_url":"https://osv.dev/vulnerability/GHSA-wq4w-vwvq-q3x9","source_modified_at":"2026-10-19T21:41:20.936879864Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"Go","name":"github.com/0xJacky/Nginx-UI","purl":"pkg:golang/github.com/0xJacky/Nginx-UI"},"version":"1.9.10-0.20260703131214-23d1934099b0"}],"cvss":5.4,"severity":"Medium","kev":{"listed":false},"epss":{"probability":0.00209,"percentile":0.10581,"score_date":"2026-10-23"},"published_at":"2026-10-12T20:49:36.955Z","modified_at":"2026-10-19T21:41:20.936879864Z","provenance":[{"source":"GitHub Advisory Database","url":"https://github.com/advisories/GHSA-wq4w-vwvq-q3x9","fetched_at":"2026-10-23T18:42:43.628194Z","source_modified_at":"2026-10-15T20:14:02Z"},{"source":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-84321","fetched_at":"2026-10-23T18:45:31.882637Z","source_modified_at":"2026-10-13T15:50:29.123Z"},{"source":"OSV","url":"https://osv.dev/vulnerability/GHSA-wq4w-vwvq-q3x9","fetched_at":"2026-10-23T18:42:43.628194Z","source_modified_at":"2026-10-19T21:41:20.936879864Z"},{"source":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-84321","fetched_at":"2026-10-23T18:42:43.628194Z","source_modified_at":"2026-10-23"}],"sources":["GitHub Advisory Database","CVE List","OSV","EPSS"],"references":[{"source":"CVE List","url":"https://github.com/0xJacky/nginx-ui/security/advisories/GHSA-wq4w-vwvq-q3x9","tags":["x_refsource_CONFIRM"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-84321","source":"GitHub Advisory Database"},{"source":"CVE List","url":"https://github.com/0xJacky/nginx-ui/commit/23d1934099b05b2a01589b48129dc3d3159d91c2","tags":["x_refsource_MISC"]},{"source":"CVE List","url":"https://github.com/0xJacky/nginx-ui/releases/tag/v2.4.1","tags":["x_refsource_MISC"]},{"url":"https://github.com/advisories/GHSA-wq4w-vwvq-q3x9","source":"GitHub Advisory Database"}],"locations":[],"motoko_assessment":{"status":"requires_architecture_review","automatic_remediation":false},"cve_state":"PUBLISHED","ssvc":{"exploitation":"poc","automatable":"no","technical_impact":"partial","assessed_at":"2026-10-13T15:47:39.126608Z"},"classification":{"method":"product-first software-layer rules","rules_version":"2.1","matched_on":"product","confidence":"heuristic","reviewed":false},"change_timestamp":"2026-10-19T21:41:20.936879864Z","content_hash":"cc8676d97b37df698e0cff4de43b8f897ed304bcd9a2ca28ee4486f3e49c2102"}}
