Skip to main content
Vulnerability Database/CVE-2024-39591

CVE-2024-39591: SAP Document Builder Privilege Escalation

CVE-2024-39591 is a privilege escalation vulnerability in SAP Document Builder caused by missing authorization checks. This flaw allows attackers to gain elevated privileges with low confidentiality impact. This article covers technical details, affected versions, security impact, and recommended mitigation strategies.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2024-39591 Overview

CVE-2024-39591 affects SAP Document Builder, where a function module lacks the required authorization checks. An unauthenticated remote attacker can invoke the vulnerable function module to read data they should not be able to access. The flaw is categorized under CWE-862: Missing Authorization and results in a limited loss of confidentiality without affecting integrity or availability.

The vulnerability was disclosed as part of SAP Security Patch Day and is tracked in SAP Note #3477423. It impacts multiple SAP Document Builder component versions deployed on both S/4HANA Foundation (S4FND) and SAP Business Suite Foundation (SAP_BS_FND) stacks.

Critical Impact

Network-reachable attackers without credentials can trigger an unauthorized function module in SAP Document Builder, exposing limited confidential application data.

Affected Products

  • SAP Document Builder on S4FND releases 102, 103, 104, 105, 106, 107, and 108
  • SAP Document Builder on SAP_BS_FND releases 702, 731, 746, 747, and 748
  • SAP S/4HANA and SAP Business Suite systems where the vulnerable Document Builder function module is accessible

Discovery Timeline

  • 2024-08-13 - CVE-2024-39591 published to NVD
  • 2026-06-17 - Last updated in NVD database

Technical Details for CVE-2024-39591

Vulnerability Analysis

SAP Document Builder exposes several Remote Function Call (RFC) enabled function modules used to generate and manage templated business documents. One of these function modules does not perform the authorization checks required by SAP's standard authority-check model. As a result, callers can execute the function without holding the authorization objects normally enforced by the application layer.

The weakness is a Missing Authorization defect [CWE-862]. The function module relies on the assumption that upstream callers enforce access control, but no AUTHORITY-CHECK statement validates the caller's rights before returning data. An attacker reaching the SAP system over the network, for example through an exposed RFC gateway or an application server with the Document Builder component loaded, can invoke the module and retrieve information that should be gated by role-based access control.

Impact is restricted to confidentiality. Integrity and availability are not affected, and the attack does not require privileges or user interaction. The scope remains unchanged, meaning the data exposure is bounded to the vulnerable component.

Root Cause

The root cause is the absence of an authority check inside the affected Document Builder function module. SAP function modules typically guard sensitive operations with AUTHORITY-CHECK OBJECT statements that validate activity codes and object-level permissions. In this module, that enforcement step is missing, so every successful call bypasses the role-based controls defined for Document Builder content.

Attack Vector

The attack vector is network based. An attacker with the ability to issue an RFC or equivalent call to the SAP application server can target the function module directly. No credentials and no user interaction are required. Exploitation discloses application data processed by Document Builder but does not permit modification or denial of service. No public proof-of-concept exploit is listed in the enriched data, and the vulnerability is not present on the CISA Known Exploited Vulnerabilities list.

No verified exploitation code is available. See SAP Note #3477423 for the vendor's technical description of the fix.

Detection Methods for CVE-2024-39591

Indicators of Compromise

  • Unexpected RFC calls targeting SAP Document Builder function modules from unusual source hosts or users
  • Document Builder data retrieval activity by accounts that do not hold the corresponding authorization objects
  • Spikes in anonymous or low-privilege RFC traffic to systems running S4FND or SAP_BS_FND components

Detection Strategies

  • Audit SAP Security Audit Log (SM19/SM20) entries for Document Builder function module invocations and correlate them with user role assignments.
  • Review Gateway logs (gw/logging) for RFC calls that reach Document Builder modules from external or non-whitelisted systems.
  • Baseline normal Document Builder usage patterns and alert on deviations, especially calls originating outside documented business processes.

Monitoring Recommendations

  • Forward SAP audit, Gateway, and RFC logs into a centralized SIEM for cross-system correlation and retention.
  • Monitor for failed authority checks and newly observed RFC callers against SAP application servers hosting Document Builder.
  • Track SAP Note #3477423 patch deployment status across all SAP landscapes to confirm remediation coverage.

How to Mitigate CVE-2024-39591

Immediate Actions Required

  • Apply the fix delivered in SAP Note #3477423 to all affected S4FND and SAP_BS_FND releases.
  • Inventory SAP systems running SAP Document Builder and prioritize patching for internet-adjacent or multi-tenant landscapes.
  • Review user and technical account authorizations that permit RFC access to Document Builder function modules and remove unnecessary entitlements.

Patch Information

SAP addressed CVE-2024-39591 through SAP Security Patch Day. The corrective note, SAP Note #3477423, introduces the missing authorization check in the affected Document Builder function module. Additional advisories are published on SAP Security Patch Day. Customers should apply the note or the corresponding Support Package to every impacted system.

Workarounds

  • Restrict RFC Gateway access using reginfo and secinfo rules to permit only trusted hosts to call SAP application servers.
  • Enforce least-privilege RFC authorization object S_RFC so that only required users and systems can invoke Document Builder function groups.
  • Segment SAP application servers from untrusted networks and require VPN or jump-host access for administrative RFC traffic until patching is complete.
bash
# Configuration example - restrict RFC access via Gateway ACL
# secinfo entry: allow only specific user/host to call Document Builder FMs
USER=SAP_DOCBUILDER_SVC USER-HOST=app01.internal.example HOST=app01.internal.example
# reginfo entry: deny external program registration by default
P TP=* HOST=internal-hosts ACCESS=internal-hosts CANCEL=internal-hosts
D TP=*

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.