Skip to content

Vikunja: Write-level project members can delete admin-tier link shares through an unloaded permission check

Moderate severity GitHub Reviewed Published Oct 3, 2026 in go-vikunja/vikunja • Updated Oct 9, 2026

Package

gomod code.vikunja.io/api (Go)

Affected versions

>= 0.13.0, <= 2.6.0

Patched versions

None

Description

Summary

A project member with Write permission can delete an admin-tier link share on that project. The deletion authorization check reads the permission from an object populated only with URL IDs, rather than from the stored share. Its zero value is Read, so the check falls through to project Write permission instead of requiring Admin.

Details

Affected endpoints:

  • DELETE /api/v1/projects/{project}/shares/{share}
  • DELETE /api/v2/projects/{project}/shares/{share}

Older v1 releases used /lists/{list}/shares/{share} before lists were renamed to projects.

In pkg/routes/api/v2/link_sharing.go:156, the delete handler passes &models.LinkSharing{ID: in.ID, ProjectID: in.ProjectID} to handler.DoDelete. The v1 generic handler likewise binds the URL IDs without loading the stored share.

pkg/web/handler/core.go:185 calls CanDelete before Delete. LinkSharing.CanDelete delegates to canDoLinkShare in pkg/models/link_sharing_permissions.go. That helper loads the project but does not load the link share, then evaluates:

if share.Permission == PermissionAdmin {
    return l.IsAdmin(s, a)
}
return l.CanWrite(s, a)

On deletion, share.Permission is its Go zero value, PermissionRead (0), even when the stored share grants PermissionAdmin (2). A Write member therefore passes authorization. LinkSharing.Delete subsequently deletes by share ID and project ID without checking the stored permission.

Create uses the requested permission and correctly rejects Write members creating admin shares. Share listing and by-ID reads are admin-gated in current main. There is no HTTP update route for link shares. Read-only members and link-share principals are rejected on deletion.

Affected versions and verification

The admin-tier check was introduced in commit 56dbb564eae83f2453efd1049f55e9d099b5d346, first included in v0.13, without loading the stored share on deletion. The affected range established by this review is >= 0.13.0, <= 2.6.0; versions before v0.13 have not been assessed here. The v2 route was added in b10768506, first included in v2.4.0.

The reporter states that both API versions were verified live against a local source build at a881ac39eecd07575a5aede8e74727c28d5fd578 on September 7, 2026. Maintainer-side source review confirmed the mechanism in that commit, release v2.6.0, and upstream main at a1a6ca48be142902f09fee62734310cb98a8c414. The live proof of concept was not independently rerun during this triage. No patched version is available at draft creation.

Impact

A Write collaborator can revoke an admin-tier access link on a project they can already write to. New consumers can no longer authenticate with that link. In versions with database-backed link-share JWT validation, deleting the share also immediately invalidates its existing sessions; the reporter observed HTTP 404 for a new hash exchange and HTTP 401 for an existing share token.

This is a bounded integrity and availability impact on external access to that project. It does not disclose data, grant Admin privileges, allow deletion of another project's shares, or permit the attacker to create a replacement admin share. The attacker must know or guess the numeric share ID; IDs are sequential.

Severity: Medium. CWE-863: Incorrect Authorization.

Proof of concept

Use two regular accounts on an instance you control. Let OWNER_TOKEN and WRITER_TOKEN be their session tokens. Create a project as the owner, grant the second account Write permission (permission: 1), and create an admin-tier share as the owner (permission: 2). Let PROJECT_ID and SHARE_ID identify that project and share.

First, verify that the Write member cannot create an admin-tier share:

curl -i -X POST "$BASE/api/v2/projects/$PROJECT_ID/shares" \
  -H "Authorization: Bearer $WRITER_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{"permission":2}'
# Expected and reported: 403

Delete the owner's admin-tier share as the same Write member:

curl -i -X DELETE "$BASE/api/v2/projects/$PROJECT_ID/shares/$SHARE_ID" \
  -H "Authorization: Bearer $WRITER_TOKEN"
# Reported: 204; expected: 403 and the share remains intact

Recreate the admin-tier share as the owner and repeat with the v1 endpoint:

curl -i -X DELETE "$BASE/api/v1/projects/$PROJECT_ID/shares/$SHARE_ID" \
  -H "Authorization: Bearer $WRITER_TOKEN"
# Reported: 200 with {"message":"Successfully deleted."}; expected: 403

With the collaborator downgraded to Read, deletion returns 403. These positive and negative controls were reported as verified live by the reporter.

Recommended fix

For deletion, load the stored share scoped to both the requested share ID and project ID before authorizing. Require project Admin when the stored permission is Admin, and retain the intended Write rule for ordinary read/write shares. Preserve the existing cross-project constraint.

Keep creation authorization based on the requested tier. If update support is added, check both the stored tier and the requested new tier so neither demotion nor promotion can bypass the admin check.

Add regression coverage for a Write member being forbidden to delete an admin-tier share, an Admin being allowed, intended ordinary-share deletion, rejection of Read members and link-share principals, and mismatched project/share IDs. Cover both API versions.

Related advisories

Credit

Reported via mail.

References

@kolaente kolaente published to go-vikunja/vikunja Oct 3, 2026
Published to the GitHub Advisory Database Oct 9, 2026
Reviewed Oct 9, 2026
Last updated Oct 9, 2026

Severity

Moderate

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v4 base metrics

Exploitability Metrics
Attack Vector Network
Attack Complexity Low
Attack Requirements None
Privileges Required None
User interaction None
Vulnerable System Impact Metrics
Confidentiality None
Integrity Low
Availability Low
Subsequent System Impact Metrics
Confidentiality None
Integrity None
Availability None

CVSS v4 base metrics

Exploitability Metrics
Attack Vector: This metric reflects the context by which vulnerability exploitation is possible. This metric value (and consequently the resulting severity) will be larger the more remote (logically, and physically) an attacker can be in order to exploit the vulnerable system. The assumption is that the number of potential attackers for a vulnerability that could be exploited from across a network is larger than the number of potential attackers that could exploit a vulnerability requiring physical access to a device, and therefore warrants a greater severity.
Attack Complexity: This metric captures measurable actions that must be taken by the attacker to actively evade or circumvent existing built-in security-enhancing conditions in order to obtain a working exploit. These are conditions whose primary purpose is to increase security and/or increase exploit engineering complexity. A vulnerability exploitable without a target-specific variable has a lower complexity than a vulnerability that would require non-trivial customization. This metric is meant to capture security mechanisms utilized by the vulnerable system.
Attack Requirements: This metric captures the prerequisite deployment and execution conditions or variables of the vulnerable system that enable the attack. These differ from security-enhancing techniques/technologies (ref Attack Complexity) as the primary purpose of these conditions is not to explicitly mitigate attacks, but rather, emerge naturally as a consequence of the deployment and execution of the vulnerable system.
Privileges Required: This metric describes the level of privileges an attacker must possess prior to successfully exploiting the vulnerability. The method by which the attacker obtains privileged credentials prior to the attack (e.g., free trial accounts), is outside the scope of this metric. Generally, self-service provisioned accounts do not constitute a privilege requirement if the attacker can grant themselves privileges as part of the attack.
User interaction: This metric captures the requirement for a human user, other than the attacker, to participate in the successful compromise of the vulnerable system. This metric determines whether the vulnerability can be exploited solely at the will of the attacker, or whether a separate user (or user-initiated process) must participate in some manner.
Vulnerable System Impact Metrics
Confidentiality: This metric measures the impact to the confidentiality of the information managed by the VULNERABLE SYSTEM due to a successfully exploited vulnerability. Confidentiality refers to limiting information access and disclosure to only authorized users, as well as preventing access by, or disclosure to, unauthorized ones.
Integrity: This metric measures the impact to integrity of a successfully exploited vulnerability. Integrity refers to the trustworthiness and veracity of information. Integrity of the VULNERABLE SYSTEM is impacted when an attacker makes unauthorized modification of system data. Integrity is also impacted when a system user can repudiate critical actions taken in the context of the system (e.g. due to insufficient logging).
Availability: This metric measures the impact to the availability of the VULNERABLE SYSTEM resulting from a successfully exploited vulnerability. While the Confidentiality and Integrity impact metrics apply to the loss of confidentiality or integrity of data (e.g., information, files) used by the system, this metric refers to the loss of availability of the impacted system itself, such as a networked service (e.g., web, database, email). Since availability refers to the accessibility of information resources, attacks that consume network bandwidth, processor cycles, or disk space all impact the availability of a system.
Subsequent System Impact Metrics
Confidentiality: This metric measures the impact to the confidentiality of the information managed by the SUBSEQUENT SYSTEM due to a successfully exploited vulnerability. Confidentiality refers to limiting information access and disclosure to only authorized users, as well as preventing access by, or disclosure to, unauthorized ones.
Integrity: This metric measures the impact to integrity of a successfully exploited vulnerability. Integrity refers to the trustworthiness and veracity of information. Integrity of the SUBSEQUENT SYSTEM is impacted when an attacker makes unauthorized modification of system data. Integrity is also impacted when a system user can repudiate critical actions taken in the context of the system (e.g. due to insufficient logging).
Availability: This metric measures the impact to the availability of the SUBSEQUENT SYSTEM resulting from a successfully exploited vulnerability. While the Confidentiality and Integrity impact metrics apply to the loss of confidentiality or integrity of data (e.g., information, files) used by the system, this metric refers to the loss of availability of the impacted system itself, such as a networked service (e.g., web, database, email). Since availability refers to the accessibility of information resources, attacks that consume network bandwidth, processor cycles, or disk space all impact the availability of a system.
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:L/SC:N/SI:N/SA:N

EPSS score

Weaknesses

Incorrect Authorization

The product performs an authorization check when an actor attempts to access a resource or perform an action, but it does not correctly perform the check. Learn more on MITRE.

CVE ID

No known CVE

GHSA ID

GHSA-fmmf-xq98-g327

Source code

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.