CVE-2023-30186
ONLYOFFICE DocumentServer vulnerability analysis and mitigation

Overview

A use after free issue was discovered in ONLYOFFICE DocumentServer versions 4.0.3 through 7.3.2. The vulnerability exists in the Docbuilder component which uses a v8 engine to execute JavaScript code inside the process. The vulnerability allows remote attackers to run arbitrary code via a crafted JavaScript file (Gist, NVD).

Technical details

The vulnerability exists in the SaveAlloc and SaveReAlloc functions of the CNativeControl class. When a new v8::ArrayBuffer object is created using SaveAlloc and a data viewer is created for this buffer, the viewer's backing store points to the allocated mpSaveBinary. When SaveReAlloc is subsequently executed, it frees the previous heap chunk pointed to by mpSaveBinary and allocates a new one, but the data viewer's backing store still points to the freed memory location. The vulnerability has been assigned a CVSS v3.1 base score of 9.8 CRITICAL (NVD).

Impact

This vulnerability allows an attacker to manipulate the data viewer to leak or change the content of the freed heap chunk, potentially leading to arbitrary code execution. The vulnerability can be exploited remotely through the /docbuilder API route, though from version 7.2 onwards, an attacker needs to know the generated JWT token to communicate with /docbuilder (Gist).

Mitigation and workarounds

The vulnerability has been patched in a commit that removes the vulnerable functionality from the DesktopEditor/doctrenderer/embed/jsc/jsc_NativeControl.mm file (Core Commit). Users should upgrade to a version containing this fix.

Additional resources


SourceThis report was generated using AI

Related ONLYOFFICE DocumentServer vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2023-30187CRITICAL9.8
  • ONLYOFFICE DocumentServerONLYOFFICE DocumentServer
  • cpe:2.3:a:onlyoffice:document_server
NoYesAug 14, 2023
CVE-2023-30186CRITICAL9.8
  • ONLYOFFICE DocumentServerONLYOFFICE DocumentServer
  • cpe:2.3:a:onlyoffice:document_server
NoYesAug 14, 2023
CVE-2022-48422HIGH7.8
  • ONLYOFFICE DocumentServerONLYOFFICE DocumentServer
  • cpe:2.3:a:onlyoffice:document_server
NoYesMar 19, 2023
CVE-2023-30188HIGH7.5
  • ONLYOFFICE DocumentServerONLYOFFICE DocumentServer
  • cpe:2.3:a:onlyoffice:document_server
NoYesAug 14, 2023
CVE-2023-50883MEDIUM6.1
  • ONLYOFFICE DocumentServerONLYOFFICE DocumentServer
  • cpe:2.3:a:onlyoffice:document_server
NoYesSep 09, 2024

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management