/

CVE-2026-108746

Severity:

HIGH RISK

(8.8)

Incorrect Authorization (CWE-863) in Vearch Role Management

CVE-2026-108746

Deferred

Vulnerability type

Category:

Incorrect Authorization

CWE:

CWE-863

Impact:

Authorization Bypass and Privilege Escalation

Severity:

HIGH RISK

(8.8)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

Vearch contains an authorization flaw in role resource checks that can disregard stored read-only or no-access privilege levels. An authenticated non-root user may modify or delete documents beyond their assigned permissions and potentially grant their role stronger privileges through the role management API.

Vearch contains an authorization flaw in role resource checks that can disregard stored read-only or no-access privilege levels. An authenticated non-root user may modify or delete documents beyond their assigned permissions and potentially grant their role stronger privileges through the role management API.

Affected context

The vulnerability affects Vearch deployments using the affected role-based access control logic. It becomes risky when an authenticated non-root account has access to resources listed in a role and the authorization check fails to honor the stored privilege level for those resources. The role management endpoint may further increase exposure when such users can update role definitions.

The vulnerability affects Vearch deployments using the affected role-based access control logic. It becomes risky when an authenticated non-root account has access to resources listed in a role and the authorization check fails to honor the stored privilege level for those resources. The role management endpoint may further increase exposure when such users can update role definitions.

Exploit preconditions

  • Attack surface: Vearch document and role management APIs
  • Required access: An authenticated non-root user with access to a role or its associated resources
  • Trigger point: Resource operations or role updates evaluated by Role.HasPermissionForResources
  • Why exploitation is possible: The authorization logic may ignore stored ReadOnly or None privilege values, allowing operations or privilege changes beyond the user's intended authorization
  • Attack surface: Vearch document and role management APIs
  • Required access: An authenticated non-root user with access to a role or its associated resources
  • Trigger point: Resource operations or role updates evaluated by Role.HasPermissionForResources
  • Why exploitation is possible: The authorization logic may ignore stored ReadOnly or None privilege values, allowing operations or privilege changes beyond the user's intended authorization

Why this happens

The underlying bug is an authorization decision that does not faithfully enforce the privilege state stored for each resource. When a role check treats listed resources as permitted without distinguishing read-only, no-access, and write-capable levels, an authenticated user can cross an intended authorization boundary. This behavior maps to CWE-863: Incorrect Authorization, because access-control logic fails to apply the configured permissions consistently.

The underlying bug is an authorization decision that does not faithfully enforce the privilege state stored for each resource. When a role check treats listed resources as permitted without distinguishing read-only, no-access, and write-capable levels, an authenticated user can cross an intended authorization boundary. This behavior maps to CWE-863: Incorrect Authorization, because access-control logic fails to apply the configured permissions consistently.

Potential impact

  • Unauthorized document creation or modification may occur
  • Unauthorized document deletion could occur
  • A user may grant a role stronger write-read privileges
  • Privilege escalation toward cluster administrator access may be possible
  • Data integrity, availability, and confidentiality could be affected
  • Unauthorized document creation or modification may occur
  • Unauthorized document deletion could occur
  • A user may grant a role stronger write-read privileges
  • Privilege escalation toward cluster administrator access may be possible
  • Data integrity, availability, and confidentiality could be affected

General mitigation guidance

Mitigation generally focuses on making authorization decisions explicit, consistent, and deny-by-default.

Common defensive patterns include:

  • Enforcing None, read-only, and read-write permissions distinctly for every resource
  • Centralizing authorization checks so all API operations use the same policy evaluation
  • Requiring separate, strongly protected administrative privileges for role modification
  • Reducing trust in client-supplied role or privilege values and deriving access from server-side policy
  • Applying least privilege to service accounts and administrative identities
  • Auditing role changes and rejecting requests that would exceed the caller's authority

Mitigation generally focuses on making authorization decisions explicit, consistent, and deny-by-default.

Common defensive patterns include:

  • Enforcing None, read-only, and read-write permissions distinctly for every resource
  • Centralizing authorization checks so all API operations use the same policy evaluation
  • Requiring separate, strongly protected administrative privileges for role modification
  • Reducing trust in client-supplied role or privilege values and deriving access from server-side policy
  • Applying least privilege to service accounts and administrative identities
  • Auditing role changes and rejecting requests that would exceed the caller's authority

How teams detect issues like this

Organizations can look for this class of issue through:

  • Static analysis and code review of permission comparisons, enum handling, and default-allow branches
  • Tests covering every resource privilege state, especially read-only and explicit no-access cases
  • Authorization policy checks ensuring users cannot grant permissions they do not possess
  • API monitoring for unexpected document writes, deletes, or role privilege changes by non-administrative accounts
  • Automated security review tools that flag inconsistent or bypassable access-control logic

Organizations can look for this class of issue through:

  • Static analysis and code review of permission comparisons, enum handling, and default-allow branches
  • Tests covering every resource privilege state, especially read-only and explicit no-access cases
  • Authorization policy checks ensuring users cannot grant permissions they do not possess
  • API monitoring for unexpected document writes, deletes, or role privilege changes by non-administrative accounts
  • Automated security review tools that flag inconsistent or bypassable access-control logic

Sources

SourceLink
github.comgithub.com/vearch/vearch
github.comgithub.com/vearch/vearch/blob/bae78b189ff0ab1d8ac659c6acaeeb5f630db33f/internal/entity/user.go#L300-L313
github.comgithub.com/vearch/vearch/blob/bae78b189ff0ab1d8ac659c6acaeeb5f630db33f/internal/master/services/role_service.go#L180-L229
hackmd.iohackmd.io/@haind/vearch-rbac-privilege-level-ignored-authz-bypass
vulncheck.comvulncheck.com/advisories/vearch-3.5.2-through-3.5.9-incorrect-authorization-via-role-haspermissionforresources

Frequently asked

questions

An authenticated non-root user may be able to exploit it when their role references affected resources and the authorization logic fails to enforce the configured privilege level.

It generally requires access to the Vearch APIs that perform document operations or role management. The exact exposure depends on deployment network controls and API authentication settings.

Ensure every authorization decision honors the server-side privilege assigned to each resource, uses deny-by-default behavior, and separately protects role-management operations.

Maintain centralized RBAC enforcement, test all permission states and escalation paths, restrict administrative privileges, and monitor sensitive role and data operations.

An authenticated non-root user may be able to exploit it when their role references affected resources and the authorization logic fails to enforce the configured privilege level.

It generally requires access to the Vearch APIs that perform document operations or role management. The exact exposure depends on deployment network controls and API authentication settings.

Ensure every authorization decision honors the server-side privilege assigned to each resource, uses deny-by-default behavior, and separately protects role-management operations.

Maintain centralized RBAC enforcement, test all permission states and escalation paths, restrict administrative privileges, and monitor sensitive role and data operations.

Find out what's already
exploitable in your codebase.