| Title | jina-ai reader Latest commit (2026-06-10) Server-Side Request Forgery |
|---|
| Description | A Server-Side Request Forgery vulnerability was identified in jina-ai/reader (GitHub, 11,151 stars), a URL-to-Markdown conversion service. The vulnerability resides in the URL validation pipeline within the crawler and Puppeteer service modules. The Reader service accepts an arbitrary URL from the request path (e.g., GET /https://example.com) and uses Puppeteer to navigate to and render the target page. Two independent weaknesses enable the attack. First, the isValidTLD() function in crawler.ts (line 709-712) validates hostnames by checking only that the hostname contains at least one dot and the last segment is at least two characters long: parts.length > 1 && parts[parts.length-1].length >= 2. This accidentally blocks 127.0.0.1 (last segment "1" has length 1) but permits x.x.x.x (last segment "254" has length 3). All IPv4 addresses ending with an octet of 10 or greater pass the TLD check, including all cloud metadata endpoints and private network ranges. Second, the Puppeteer request interceptor in puppeteer.ts (line 387-394) only blocks requests to hostname "localhost" and hostnames starting with "127.", leaving x.x.x.x, 10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16, and IPv6 equivalents (including ::1) completely accessible. An unauthenticated remote attacker can send curl https://r.jina.ai/http://x.x.x.x/latest/meta-data/ to access AWS cloud metadata, or target any internal IP to scan private networks and services. Where the Reader instance runs on cloud infrastructure with an attached IAM role, the attacker can retrieve temporary security credentials via the metadata endpoint, potentially gaining full cloud account access. CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N (8.6, High). The recommended fix is to replace the isValidTLD() TLD validation with proper RFC 1918/6598/5735 IP range blocking, resolve hostnames to IP addresses before passing them to Puppeteer, and extend the Puppeteer interceptor to cover all private and special-use IP ranges. |
|---|
| Source | ⚠️ https://github.com/orionyan520/cve_report/issues/8 |
|---|
| User | orionyan (UID 98777) |
|---|
| Submission | 06/10/2026 11:57 (2 months ago) |
|---|
| Moderation | 08/03/2026 13:22 (2 months later) |
|---|
| Status | Accepted |
|---|
| VulDB entry | 385566 [jina-ai reader up to 1574bfd380d249c86c82db4dace0d9c8fe17e2b1 Crawler/Puppeteer crawler.ts isValidTLD server-side request forgery] |
|---|
| Points | 20 |
|---|