From 525b304ffcb2797860e3c0cb341d5644521f2395 Mon Sep 17 00:00:00 2001 From: Andrew Harvard Date: Mon, 1 Dec 2025 12:45:01 -0500 Subject: [PATCH] [MCP-UI] add CSP for images to proxy HTML (#5931) --- crates/goose-server/src/routes/templates/mcp_ui_proxy.html | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/crates/goose-server/src/routes/templates/mcp_ui_proxy.html b/crates/goose-server/src/routes/templates/mcp_ui_proxy.html index 0cac94a8..f672873f 100644 --- a/crates/goose-server/src/routes/templates/mcp_ui_proxy.html +++ b/crates/goose-server/src/routes/templates/mcp_ui_proxy.html @@ -9,6 +9,7 @@ - script-src: Allow scripts from any origin, inline, eval, wasm, and blob URLs - style-src: Allow styles from any origin and inline styles - font-src: Allow fonts from any origin + - img-src: Allow images from any origin - connect-src: Allow network requests to any origin - frame-src: Allow embedding iframes from any origin (required for proxy functionality) - media-src: Allow audio/video media from any origin @@ -17,7 +18,7 @@ --> + content="default-src 'self'; script-src * 'wasm-unsafe-eval' 'unsafe-inline' 'unsafe-eval' blob:; style-src * 'unsafe-inline'; font-src *; img-src *; connect-src *; frame-src *; media-src *; base-uri 'self'; upgrade-insecure-requests"/> MCP-UI Proxy