Bug 2354963 (CVE-2025-27831)

Summary: CVE-2025-27831 Ghostscript: Text buffer overflow with long characters
Product: [Other] Security Response Reporter: OSIDB Bzimport <bzimport>
Component: vulnerabilityAssignee: Product Security DevOps Team <prodsec-dev>
Status: NEW --- QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: alexander.neumann
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
A flaw was found in Artifex Ghostscript. The DOCXWRITE TXTWRITE device has a text buffer overflow via long characters to devices/vector/doc_common.c.
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 2355007, 2355008    
Bug Blocks:    
Attachments:
Description Flags
Demo exploit document which opens Gnome calculator on Fedora 41 none

Description OSIDB Bzimport 2025-03-25 21:01:48 UTC
An issue was discovered in Artifex Ghostscript before 10.05.0. The DOCXWRITE TXTWRITE device has a text buffer overflow via long characters to devices/vector/doc_common.c.

Comment 2 Alexander Neumann 2025-04-04 08:00:17 UTC
Why is this issue only rated a medium risk? It is highly critical: receiving a document via email and opening it with LibreOffice directly leads to embedded code being executed!

The needed exploit code is public, I'll attached a demo.odt document for you to try, it only opens Gnome Calculator.

For Fedora 41 (stable) there's already a patched version of Ghostscript in testing, can you please expedite the move to stable? Thank you very much!

Comment 3 Alexander Neumann 2025-04-04 08:00:51 UTC
Created attachment 2083389 [details]
Demo exploit document which opens Gnome calculator on Fedora 41