Skip to content

Commit 72dad49

Browse files
authored
Merge pull request #23 from Beyond-Better/staging
added Content-Security-Policy headers to both response methods in DocsEndpointHandler.ts
2 parents f26c0c6 + 6dea86e commit 72dad49

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

deno.jsonc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@beyondbetter/bb-mcp-server",
3-
"version": "0.1.11",
3+
"version": "0.1.12",
44
"description": "Comprehensive library for building Deno-based MCP servers",
55
"license": "MIT",
66
"copyright": "2025 - Beyond Better <charlie@beyondbetter.app>",

src/lib/server/DocsEndpointHandler.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -640,6 +640,7 @@ export class DocsEndpointHandler {
640640
headers: {
641641
'Content-Type': 'text/html; charset=utf-8',
642642
'Cache-Control': 'public, max-age=3600',
643+
'Content-Security-Policy': "default-src 'self'; style-src 'self' https://cdn.jsdelivr.net 'unsafe-inline'; script-src 'self'; img-src 'self' data:; font-src 'self' data:;",
643644
},
644645
});
645646
}
@@ -671,6 +672,7 @@ export class DocsEndpointHandler {
671672
status,
672673
headers: {
673674
'Content-Type': 'text/html; charset=utf-8',
675+
'Content-Security-Policy': "default-src 'self'; style-src 'self' https://cdn.jsdelivr.net 'unsafe-inline'; script-src 'self'; img-src 'self' data:; font-src 'self' data:;",
674676
},
675677
});
676678
}

0 commit comments

Comments
 (0)