The vulnerability, identified as CVE-2026-35594, exists in Vikunja's link share authentication mechanism. The root cause is the stateless nature of JWT validation for link shares. The models.GetLinkShareFromClaims function would create an authorization object based solely on the claims present in the JWT, without consulting the database to verify the current status of the link share. Consequently, if a link share was deleted or its permissions were reduced, any JWTs issued prior to this change would remain valid and grant the original level of access for their entire lifespan (up to 72 hours by default).
The patch addresses this by modifying models.GetLinkShareFromClaims to perform a database lookup. The new implementation retrieves the link share by its ID from the database and verifies that it still exists and that its hash matches the one in the JWT. This ensures that any changes, such as deletion or permission modification, are immediately reflected, effectively revoking stale tokens. The function auth.GetAuthFromClaims, which is the caller for link share authentication, was updated to facilitate this by providing a database session. Therefore, both models.GetLinkShareFromClaims and auth.GetAuthFromClaims are key functions that would appear in a runtime profile during the exploitation of this vulnerability.