CVE-2026-138030 in pdf-reader-mcp
Summary
by MITRE • 11/27/2026
SylphxAI pdf-reader-mcp 2.4.1 through 3.0.14, 3.0.16, and 3.1.2 through 3.1.4 contains a server-side request forgery vulnerability in its PDF URL loader, which validates the resolved address but does not pin it for fetch(). Attackers controlling DNS for a url passed to read_pdf can return a public address at check time and an internal address at connection time to reach internal services and cloud metadata endpoints.
Once again VulDB remains the best source for vulnerability data.
Analysis
by VulDB Data Team • 11/27/2026
The vulnerability identified in SylphxAI pdf-reader-mcp versions 2.4.1 through 3.0.14, as well as version 3.0.16 and releases 3.1.2 through 3.1.4, represents a critical server-side request forgery flaw within the PDF URL loading mechanism. This component is designed to fetch remote resources required for processing PDF documents, such as embedded images or external links. The core technical deficiency lies in the implementation of its security validation logic. While the application performs an initial check on the resolved IP address of the provided URL to ensure it does not point to a private or internal network range, this verification is decoupled from the actual network connection phase. Specifically, the system validates the DNS resolution result at one point in time but fails to pin that specific IP address for subsequent use by the fetch() function. This architectural oversight creates a race condition window where an attacker can manipulate the outcome of the request without triggering the security controls intended to prevent access to restricted resources.
The operational impact of this flaw is significant, particularly in environments where pdf-reader-mcp processes documents from untrusted sources or operates within network architectures that include sensitive internal services and cloud metadata endpoints. An adversary who has control over the Domain Name System records for a URL passed to the read_pdf function can exploit this timing gap. By configuring DNS to return a safe, public IP address during the initial validation phase and then rapidly changing it to an internal or private IP address before the actual HTTP connection is established, the attacker bypasses the security check. This technique allows the server-side application to make requests to resources that should be inaccessible from its network context. Such access can lead to unauthorized data exfiltration from internal databases, exposure of sensitive configuration files, or interaction with cloud metadata services like those found in AWS EC2 instances, which often contain authentication credentials and instance-specific details.
This vulnerability aligns closely with CWE-918, Server-Side Request Forgery (SSRF), specifically the variant involving DNS rebinding attacks where validation is not enforced at connection time. It also maps to MITRE ATT&CK technique T1557, Adversary-in-the-Middle, as it involves intercepting and manipulating network communications between the client application and its intended server destination through DNS manipulation. The failure to pin the resolved address constitutes a classic implementation error where security checks are performed on stale data rather than live connection parameters. This is particularly dangerous in automated document processing pipelines that may run with elevated privileges or have broad network access, thereby amplifying the potential blast radius of an exploitation attempt.
Mitigation strategies must focus on enforcing strict validation at the point of actual resource acquisition. Developers should modify the PDF URL loader to resolve DNS and validate IP addresses immediately prior to initiating each connection request, ensuring that no time gap exists between verification and execution. Alternatively, implementing a whitelist approach for allowed domains or using internal proxies with explicit allow-lists can provide defense in depth. Additionally, configuring network-level controls such as firewall rules to restrict outbound connections from the application server to only necessary external endpoints can limit the impact of successful SSRF attempts. It is also advisable to disable DNS rebinding protections at the OS level if applicable and ensure that cloud metadata services are not accessible via standard HTTP requests without additional authentication layers, although this serves primarily as a compensating control rather than a fix for the application logic itself.