{"id":"CVE-2025-58179","aliases":["EUVD-2025-26878","GHSA-qpr4-c339-7vq8"],"status":"published","title":"Astro Cloudflare adapter is vulnerable to Server-Side Request Forgery via /_image endpoint","description":"Astro is a web framework for content-driven websites. Versions 11.0.3 through 12.6.5 are vulnerable to SSRF when using Astro's Cloudflare adapter. When configured with output: 'server' while using the default imageService: 'compile', the generated image optimization endpoint doesn't check the URLs it receives, allowing content from unauthorized third-party domains to be served. a A bug in impacted versions of the @astrojs/cloudflare adapter for deployment on Cloudflare’s infrastructure, allows an attacker to bypass the third-party domain restrictions and serve any content from the vulnerable origin. This issue is fixed in version 12.6.6.","severity":{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-11","score":0.0087,"percentile":0.59218,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":true,"fix_available":true},"cwes":["CWE-918"],"published":"2025-09-04T19:24:11Z","modified":"2026-10-28T02:30:27Z","exploits":[{"source":"nuclei","id":"CVE-2025-58179","title":"Astro Cloudflare Adapter - Server Side Request Forgery","type":"detection template","url":"https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2025/CVE-2025-58179.yaml"},{"source":"pocgithub","id":"shitodcy/CVE-2025-58179-Check","title":"shitodcy/CVE-2025-58179-Check","date":"2025-11-11","url":"https://github.com/shitodcy/CVE-2025-58179-Check"}],"fixes":[{"ecosystem":"npm","package":"@astrojs/cloudflare","fixed_in":["12.6.6"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"npm","package":"@astrojs/cloudflare","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"11.0.3"},{"fixed":"12.6.6"}]}]},{"source":"osv","ecosystem":"npm","package":"@astrojs/cloudflare","ranges":[{"type":"SEMVER","events":[{"introduced":"11.0.3"},{"fixed":"12.6.6"}]}]}],"products":[{"vendor":"astro","product":"\\@astrojs\\/cloudflare"},{"vendor":"withastro","product":"astro"}],"references":[{"url":"https://github.com/withastro/astro/security/advisories/GHSA-qpr4-c339-7vq8","tags":["x_refsource_CONFIRM","Exploit","Vendor Advisory","advisory","web"]},{"url":"https://github.com/withastro/astro/commit/9ecf3598e2b29dd74614328fde3047ea90e67252","tags":["x_refsource_MISC","Patch","fix","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2025-58179","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-qpr4-c339-7vq8"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/58xxx/CVE-2025-58179.json","tags":["advisory"]},{"url":"https://github.com/withastro/astro","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2025-58179","title":"Astro Cloudflare adapter is vulnerable to Server-Side Request Forgery via /_image endpoint","description":"Astro is a web framework for content-driven websites. Versions 11.0.3 through 12.6.5 are vulnerable to SSRF when using Astro's Cloudflare adapter. When configured with output: 'server' while using the default imageService: 'compile', the generated image optimization endpoint doesn't check the URLs it receives, allowing content from unauthorized third-party domains to be served. a A bug in impacted versions of the @astrojs/cloudflare adapter for deployment on Cloudflare’s infrastructure, allows an attacker to bypass the third-party domain restrictions and serve any content from the vulnerable origin. This issue is fixed in version 12.6.6.","status":"published","published":"2025-09-04T23:36:44.393Z","modified":"2025-09-05T14:53:29.299Z","cvss":[{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N","level":"high","assessor":"cna"}],"cwes":["CWE-918"],"updated_at":"2026-11-02T14:32:37.351404Z"}],"euvd":[{"id":"EUVD-2025-26878","description":"Astro is a web framework for content-driven websites. Versions 11.0.3 through 12.6.5 are vulnerable to SSRF when using Astro's Cloudflare adapter. When configured with output: 'server' while using the default imageService: 'compile', the generated image optimization endpoint doesn't check the URLs it receives, allowing content from unauthorized third-party domains to be served. a A bug in impacted versions of the @astrojs/cloudflare adapter for deployment on Cloudflare’s infrastructure, allows an attacker to bypass the third-party domain restrictions and serve any content from the vulnerable origin. This issue is fixed in version 12.6.6.","status":"published","published":"2025-09-04T23:36:44Z","modified":"2025-09-05T14:53:29Z","cvss":[{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N","level":"high"}],"updated_at":"2026-11-02T20:31:46.9428Z"}],"ghsa":[{"id":"GHSA-qpr4-c339-7vq8","title":"Server-Side Request Forgery via /_image endpoint in Astro Cloudflare adapter","description":"### Summary\n\nWhen using Astro's Cloudflare adapter (`@astrojs/cloudflare`) configured with `output: 'server'` while using the default `imageService: 'compile'`, the generated image optimization endpoint doesn't check the URLs it receives, allowing content from unauthorized third-party domains to be served.\n\n### Details\n\nOn-demand rendered sites built with Astro include an `/_image` endpoint, which returns optimized versions of images.\n\nThe `/_image` endpoint is restricted to processing local images bundled with the site and also supports remote images from domains the site developer has manually authorized (using the [`image.domains`](https://docs.astro.build/en/reference/configuration-reference/#imagedomains) or [`image.remotePatterns`](https://docs.astro.build/en/reference/configuration-reference/#imageremotepatterns) options).\n\nHowever, a bug in impacted versions of the `@astrojs/cloudflare` adapter for deployment on Cloudflare’s infrastructure, allows an attacker to bypass the third-party domain restrictions and serve any content from the vulnerable origin.\n\n### PoC\n\n1. Create a new minimal Astro project (`astro@5.13.3`)\n\n2. Configure it to use the Cloudflare adapter (`@astrojs/cloudflare@12.6.5`) and server output:\n\n   ```js\n   // astro.config.mjs\n   import { defineConfig } from 'astro/config';\n   import cloudflare from '@astrojs/cloudflare';\n\n   export default defineConfig({\n     output: 'server',\n     adapter: cloudflare(),\n   });\n   ```\n\n3. Deploy to Cloudflare Pages or Workers\n\n4. Append `/_image?href=https://placehold.co/600x400` to the deployment URL.\n\n7. This will serve the placeholder image from the unauthorised `placehold.co` domain.\n\n### Impact\n\nAllows a non-authorized third-party to create URLs on an impacted site’s origin that serve unauthorized content. This includes the risk of server-side request forgery (SSRF) and by extension cross-site scripting (XSS) if a user follows a link to a maliciously crafted URL.","status":"published","published":"2025-09-04T19:24:11Z","modified":"2025-09-05T16:10:43Z","cvss":[{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N","level":"high"}],"cwes":["CWE-918"],"updated_at":"2026-11-02T14:38:57.074217Z"}],"nvd":[{"id":"CVE-2025-58179","description":"Astro is a web framework for content-driven websites. Versions 11.0.3 through 12.6.5 are vulnerable to SSRF when using Astro's Cloudflare adapter. When configured with output: 'server' while using the default imageService: 'compile', the generated image optimization endpoint doesn't check the URLs it receives, allowing content from unauthorized third-party domains to be served. a A bug in impacted versions of the @astrojs/cloudflare adapter for deployment on Cloudflare’s infrastructure, allows an attacker to bypass the third-party domain restrictions and serve any content from the vulnerable origin. This issue is fixed in version 12.6.6.","status":"published","published":"2025-09-05T00:15:32.087Z","modified":"2026-06-17T09:44:01.297Z","cvss":[{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N","level":"high","assessor":"secondary"},{"version":"3.1","score":6.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N","level":"medium","assessor":"primary"}],"cwes":["CWE-918"],"updated_at":"2026-11-02T14:11:27.145738Z"}],"osv":[{"id":"CVE-2025-58179","title":"Astro Cloudflare adapter is vulnerable to Server-Side Request Forgery via /_image endpoint","description":"Astro is a web framework for content-driven websites. Versions 11.0.3 through 12.6.5 are vulnerable to SSRF when using Astro's Cloudflare adapter. When configured with output: 'server' while using the default imageService: 'compile', the generated image optimization endpoint doesn't check the URLs it receives, allowing content from unauthorized third-party domains to be served. a A bug in impacted versions of the @astrojs/cloudflare adapter for deployment on Cloudflare’s infrastructure, allows an attacker to bypass the third-party domain restrictions and serve any content from the vulnerable origin. This issue is fixed in version 12.6.6.","status":"published","published":"2025-09-04T23:36:44.393Z","modified":"2026-10-28T02:30:27.656339875Z","cvss":[{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N","level":"high"}],"cwes":["CWE-918"],"updated_at":"2026-11-02T15:44:51.190588Z"},{"id":"GHSA-qpr4-c339-7vq8","title":"Server-Side Request Forgery via /_image endpoint in Astro Cloudflare adapter","description":"### Summary\n\nWhen using Astro's Cloudflare adapter (`@astrojs/cloudflare`) configured with `output: 'server'` while using the default `imageService: 'compile'`, the generated image optimization endpoint doesn't check the URLs it receives, allowing content from unauthorized third-party domains to be served.\n\n### Details\n\nOn-demand rendered sites built with Astro include an `/_image` endpoint, which returns optimized versions of images.\n\nThe `/_image` endpoint is restricted to processing local images bundled with the site and also supports remote images from domains the site developer has manually authorized (using the [`image.domains`](https://docs.astro.build/en/reference/configuration-reference/#imagedomains) or [`image.remotePatterns`](https://docs.astro.build/en/reference/configuration-reference/#imageremotepatterns) options).\n\nHowever, a bug in impacted versions of the `@astrojs/cloudflare` adapter for deployment on Cloudflare’s infrastructure, allows an attacker to bypass the third-party domain restrictions and serve any content from the vulnerable origin.\n\n### PoC\n\n1. Create a new minimal Astro project (`astro@5.13.3`)\n\n2. Configure it to use the Cloudflare adapter (`@astrojs/cloudflare@12.6.5`) and server output:\n\n   ```js\n   // astro.config.mjs\n   import { defineConfig } from 'astro/config';\n   import cloudflare from '@astrojs/cloudflare';\n\n   export default defineConfig({\n     output: 'server',\n     adapter: cloudflare(),\n   });\n   ```\n\n3. Deploy to Cloudflare Pages or Workers\n\n4. Append `/_image?href=https://placehold.co/600x400` to the deployment URL.\n\n7. This will serve the placeholder image from the unauthorised `placehold.co` domain.\n\n### Impact\n\nAllows a non-authorized third-party to create URLs on an impacted site’s origin that serve unauthorized content. This includes the risk of server-side request forgery (SSRF) and by extension cross-site scripting (XSS) if a user follows a link to a maliciously crafted URL.","status":"published","published":"2025-09-04T19:24:11Z","modified":"2025-09-05T16:10:42Z","cvss":[{"version":"3.1","score":7.2,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N","level":"high"}],"cwes":["CWE-918"],"updated_at":"2026-11-02T15:46:54.760124Z"}]}}
