/

CVE-2026-56780

Severity:

HIGH RISK

(7.5)

IDOR (CWE-639) in Modoboa account password reset

CVE-2026-56780

Deferred

Vulnerability type

Category:

Insecure Direct Object Reference

CWE:

CWE-639

Impact:

Account Takeover and Privilege Escalation

Severity:

HIGH RISK

(7.5)

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

Modoboa contains an insecure direct object reference in its password reset API, allowing domain administrators to arbitrarily change other users' passwords by manipulating the account identifier.

When a domain admin can call the PUT /api/v1/accounts/{pk}/password/ endpoint without proper object-level checks, they may reset superadmin passwords and fully take over privileged accounts.

Affected context

This vulnerability occurs in Modoboa deployments that expose the REST API for account management and rely on domain administrator roles for routine user operations.

It becomes relevant when the system trusts the path parameter {pk} in PUT /api/v1/accounts/{pk}/password/ without verifying ownership or permissible target scope.

In such setups, any domain admin capable of invoking this endpoint against arbitrary account IDs can reach beyond their intended administrative boundary.

Exploit preconditions

  • Attack surface: Authenticated HTTP access to the Modoboa REST API
  • Required access: Domain administrator credentials or a compromised domain admin account
  • Trigger point: Invoking PUT /api/v1/accounts/{pk}/password/ with the {pk} of a higher-privileged or unrelated user
  • Why exploitation is possible: The endpoint authorizes the caller based solely on their role, without enforcing object-level access control to restrict which accounts' passwords they may change

Why this happens

The issue stems from missing object-level authorization checks on a sensitive account password change endpoint.

The API trusts the user-supplied {pk} parameter and only performs high-level role verification, failing to confirm that a domain admin is allowed to operate on the targeted account.

This aligns with CWE-639: Insecure Direct Object Reference, where an attacker gains unauthorized access by directly referencing internal identifiers that are insufficiently protected by access control logic.

Potential impact

  • Domain administrators may reset superadmin passwords and assume full platform control
  • Unauthorized takeover of arbitrary user accounts within the system
  • Escalation from domain-level admin to global administrator privileges
  • Disruption of email services and configuration tampering across domains
  • Exposure or manipulation of sensitive user data managed by Modoboa

General mitigation guidance

Mitigation focuses on enforcing robust, object-level access control for all endpoints that act on specific account resources.

Common defensive patterns include:

  • Validating that the authenticated caller is permitted to change the password for the targeted account, based on ownership, domain boundaries, or explicit delegation rules
  • Centralizing authorization logic so that ID-based resource access decisions are consistent and auditable across APIs
  • Treating internal identifiers (such as account primary keys) as sensitive references that require strict access checks, not just high-level role checks
  • Applying least-privilege principles to administrative roles so that their powers are restricted to clearly defined scopes (e.g., per-domain limits) by default

How teams detect issues like this

Effective detection typically combines design-time and runtime approaches:

  • Static analysis or custom linting rules that flag direct use of resource identifiers in controller or view code where no object-level permission check is visible
  • Code review practices that require explicit verification of per-object authorization for endpoints handling account management and password changes
  • Centralized access control frameworks or policies that enforce resource-scoped permissions automatically and log all privileged operations
  • Monitoring audit logs for anomalies, such as domain admins changing passwords for accounts outside their domain or for global administrator accounts

Sources

SourceLink
github.comgithub.com/modoboa/modoboa/commit/a1878c4920a6e47c3217c6ff1ed4a8753c202661
github.comgithub.com/modoboa/modoboa/pull/4038
vulncheck.comvulncheck.com/advisories/modoboa-insecure-direct-object-reference-in-account-password-change-api

Frequently asked

questions

Exploitation is limited to users with domain administrator privileges or attackers who compromise such accounts, but within that scope it can affect any user account referenced by the vulnerable API.

An attacker must authenticate as a domain administrator or gain equivalent credentials to call the password reset endpoint with arbitrary account identifiers.

Implement strict object-level access control that verifies whether the caller is authorized to modify the specific account targeted by {pk}, ideally using a centralized authorization layer tied to domain ownership and role definitions.

Design APIs with resource-scoped permission checks by default, avoid trusting raw identifiers from clients, enforce least privilege for administrative roles, and embed access control reviews and automated checks into the development and code review process.

Find out what's already
exploitable in your codebase.