SecurityContext

CVE-2023-26490: mailcow - Command Injection

  • Cve: CVE-2023-26490
  • Name: mailcow - Command Injection
  • Description: mailcow is a dockerized email package, with multiple containers linked in one bridged network. The Sync Job feature - which can be made available to standard users by assigning them the necessary permission - suffers from a shell command injection. A malicious user can abuse this vulnerability to obtain shell access to the Docker container running dovecot. The imapsync Perl script implements all the necessary functionality for this feature, including the XOAUTH2 authentication mechanism. This code path creates a shell command to call openssl. However, since different parts of the specified user password are included without any validation, one can simply execute additional shell commands. Notably, the default ACL for a newly-created mailcow account does not include the necessary permission. The Issue has been fixed within the 2023-03 Update (March 3rd 2023). As a temporary workaround the Syncjob ACL can be removed from all mailbox users, preventing from creating or changing existing Syncjobs.
  • Impact: Attackers can execute arbitrary shell commands inside the container, potentially leading to full container compromise and server control.
  • Remediation: Update mailcow to the 2023-03 version or later, and remove Syncjob ACLs from mailbox users as a temporary workaround.
  • Vulnerability type: command_injection
  • Vulnerability impact: remote_code_execution
  • Requirement type: logged_in
  • Requirements: Attacker needs permission to create or modify SyncJobs
  • Labels source: projectdiscovery
  • Severity: high
  • Cvss score: 8.8
  • Cvss vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
  • Epss score: 0.0222
  • Epss percentile: 0.83131
  • Assignee: [email protected]
  • Published at: 2023-03-04T00:15:15Z
  • Age in days: 1361
  • Modified at: 2026-06-17T05:43:27Z
  • Patch available: yes
  • Public exploits total: 1
  • References total: 2
  • Products total: 1
  • Oss: yes
  • Projects total: 1
  • Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2023-26490
  • Nvd status: modified
  • Checked, none or zero: known exploited entries, nuclei templates, public exploits capped, rejected by nvd
  • Not known: hackerone

Cwe

IdName
CWE-78Improper Neutralization of Special Elements used in an OS Command

Public exploits

UrlSourceAdded date
https://github.com/mailcow/mailcow-dockerized/security/advisories/GHSA-3j2f-wf52-cjg7nvd2023-03-04

References

UrlSourceTags
https://github.com/mailcow/mailcow-dockerized/security/advisories/GHSA-3j2f-wf52-cjg7nvdExploit, Third Party Advisory
https://github.com/mailcow/mailcow-dockerized/releases/tag/2023-03nvdRelease Notes

Products

ProductAffectedPlatform boundSourcesUrl
mailcow:mailcow:_dockerized< 2023-03nonvd/v1/products/mailcow/mailcow:_dockerized

Projects

RepositoryLink kindsIndexedUrl
mailcow/mailcow-dockerizedreleases, security_advisoryyes/v1/repositories/mailcow/mailcow-dockerized

Index

  • Checked, none or zero: repositories, repositories high signal, packages

Exploitation

  • Public exploit: yes
  • Public exploit count: 1
  • Public exploit first date: 2023-03-04
  • Remote: yes
  • Authentication required: yes
  • Checked, none or zero: known exploited, known exploited by, exploitation seen, initial access
  • Not known: known exploited since, vulncheck known exploited since, nuclei template, initial access since, hackerone reports, exposed hosts