CVE-2026-28268
JSON

9.8critical

Vikunja Vulnerable to Account Takeover via Password Reset Token Reuse

Severity
9.8critical CVSS:3.1 by GitHub_M
Exploit likelihood
0.74% (higher than 55% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-rfjg-6m84-crj2GO-2026-4575

Description

Vikunja is an open-source self-hosted task management platform. Versions prior to 2.1.0 have a business logic vulnerability exists in the password reset mechanism of vikunja/api that allows password reset tokens to be reused indefinitely. Due to a failure to invalidate tokens upon use and a critical logic bug in the token cleanup cron job, reset tokens remain valid forever. This allows an attacker who intercepts a single reset token (via logs, browser history, or phishing) to perform a complete, persistent account takeover at any point in the future, bypassing standard authentication controls. Version 2.1.0 contains a patch for the issue.

Affected

Product or packageVersionsReported by
go-vikunja vikunja< 2.1.0CVE List
code.vikunja.io/api (Go)up to 0.24.6, all versionsGitHub Advisory Database, Go Vulnerability Database
vikunja vikunjabefore 2.1.0NVD

All scores

GitHub_M9.8critical CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
GitHub9.8critical CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Classification

CWE-459CWE-640

SSVC (CISA-ADP): exploitation none, automatable yes, technical impact total.

What each source says

CVE List

Vikunja is an open-source self-hosted task management platform. Versions prior to 2.1.0 have a business logic vulnerability exists in the password reset mechanism of vikunja/api that allows password reset tokens to be reused indefinitely. Due to a failure to invalidate tokens upon use and a critical logic bug in the token cleanup cron job, reset tokens remain valid forever. This allows an attacker who intercepts a single reset token (via logs, browser history, or phishing) to perform a complete, persistent account takeover at any point in the future, bypassing standard authentication controls. Version 2.1.0 contains a patch for the issue.

GitHub Advisory Database

Summary A critical business logic vulnerability exists in the password reset mechanism of vikunja/api that allows password reset tokens to be reused indefinitely. Due to a failure to invalidate tokens upon use and a critical logic bug in the token cleanup cron job, reset tokens remain valid forever.

This allows an attacker who intercepts a single reset token (via logs, browser history, or phishing) to perform a complete, persistent account takeover at any point in the future, bypassing standard authentication controls.

Technical Analysis The vulnerability stems from two distinct logic errors in the pkg/user/ package that confirm the tokens are never removed.

  1. Logic Error in Password Reset (No Invalidation) In pkg/user/user_password_reset.go, the ResetPassword function successfully updates the user's password but fails to delete the reset token used to authorize the request. Instead, it attempts to delete a TokenEmailConfirm token, leaving the TokenPasswordReset active.

Vulnerable Code: pkg/user/user_password_reset.go (Lines 36-94)

func ResetPassword(s *xorm.Session, reset *PasswordReset) (userID int64, err error) {
    // ... [Validation and User Lookup] ...

    // Hash the password
    user.Password, err = HashPassword(reset.NewPassword)
    if err != nil {
        return
    }

    // FLAW: Deletes 'TokenEmailConfirm' instead of the current 'TokenPasswordReset'
    err = removeTokens(s, user, TokenEmailConfirm)
    if err != nil {
        return
    }

    // ... [Update User Status and Return] ...
    // The reset token is never removed and remains valid in the DB.
}
  1. Logic Error in Token Cleanup (Inverted Expiry) The background cron job intended to expire old tokens contains an inverted comparison operator. It deletes tokens newer than 24 hours instead of older ones.

Vulnerable Code: pkg/user/token.go (Lines 125-151)

func RegisterTokenCleanupCron() {
    // ...
    err := cron.Schedule("0 * * * *", func() {
        // ...
        // FLAW: "created > ?" selects tokens created AFTER 24 hours ago.
        // This deletes NEW valid tokens and keeps OLD expired tokens forever.
        deleted, err := s.
            Where("created > ? AND (kind = ? OR kind = ?)", 
            time.Now().Add(time.Hour*24*-1), 
            TokenPasswordReset, TokenAccountDeletion).
            Delete(&Token{})
        // ...
    })
}

Impact Persistent Account Takeover: An attacker with a single valid token can reset the victim's password an unlimited number of times.

Bypass of Remediation: Even if the victim notices suspicious activity and changes their password, the attacker can use the same old token to reset it again immediately.

Infinite Attack Window: Because the cleanup cron is broken, the token effectively has a generic TTL of "forever," allowing exploitation months or years after the token was issued.

Remediation

  1. Invalidate Token on Use Update ResetPassword to delete the specific reset token upon successful completion. // Recommended Fix err = removeTokens(s, user, TokenPasswordReset) // Correct TokenKind
  2. Fix Cleanup Logic Update the SQL query in RegisterTokenCleanupCron to target tokens created before the cutoff time. // Recommended Fix Where("created < ? ...", time.Now().Add(time.Hour*24*-1), ...) // Use Less Than (<)

A fix is available at https://github.com/go-vikunja/vikunja/releases/tag/v2.1.0

Go Vulnerability Database

Vikunja Vulnerable to Account Takeover via Password Reset Token Reuse in code.vikunja.io/api

NVD (es)

Vikunja es una plataforma de gestión de tareas de código abierto autoalojada. En las versiones anteriores a la 2.1.0, existe una vulnerabilidad de lógica de negocio en el mecanismo de restablecimiento de contraseña de vikunja/API que permite que los tokens de restablecimiento de contraseña sean reutilizados indefinidamente. Debido a un fallo en la invalidación de tokens tras su uso y a un error de lógica crítico en el trabajo cron de limpieza de tokens, los tokens de restablecimiento permanecen válidos para siempre. Esto permite a un atacante que intercepta un único token de restablecimiento (a través de registros, historial del navegador o phishing) realizar una toma de control de cuenta completa y persistente en cualquier momento en el futuro, eludiendo los controles de autenticación estándar. La versión 2.1.0 contiene un parche para el problema.

References

Sources

SourceRecordLicence
CVE ListCVE-2026-28268 changed 2026-03-03CVE Terms of Use
GitHub Advisory DatabaseGHSA-rfjg-6m84-crj2 changed 2026-03-23CC-BY-4.0
Go Vulnerability DatabaseGO-2026-4575 changed 2026-03-23CC-BY-4.0
NVDCVE-2026-28268 changed 2026-06-17Public domain