@dollhousemcp/mcp-server 1.6.10 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/README.github.md +1036 -0
- package/README.md +165 -1668
- package/README.md.backup +298 -0
- package/README.npm.md +298 -0
- package/dist/cache/CollectionIndexCache.d.ts.map +1 -1
- package/dist/cache/CollectionIndexCache.js +2 -2
- package/dist/collection/CollectionBrowser.d.ts.map +1 -1
- package/dist/collection/CollectionBrowser.js +6 -3
- package/dist/collection/CollectionIndexManager.d.ts.map +1 -1
- package/dist/collection/CollectionIndexManager.js +4 -2
- package/dist/collection/GitHubClient.d.ts.map +1 -1
- package/dist/collection/GitHubClient.js +5 -1
- package/dist/generated/version.d.ts +2 -2
- package/dist/generated/version.d.ts.map +1 -1
- package/dist/generated/version.js +3 -3
- package/dist/index.d.ts +0 -19
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +87 -98
- package/dist/persona/export-import/index.d.ts +1 -3
- package/dist/persona/export-import/index.d.ts.map +1 -1
- package/dist/persona/export-import/index.js +2 -3
- package/dist/portfolio/PortfolioRepoManager.d.ts +1 -1
- package/dist/portfolio/PortfolioRepoManager.d.ts.map +1 -1
- package/dist/portfolio/PortfolioRepoManager.js +118 -33
- package/dist/security/contentValidator.js +8 -8
- package/dist/server/tools/PersonaTools.d.ts.map +1 -1
- package/dist/server/tools/PersonaTools.js +36 -76
- package/dist/server/types.d.ts +0 -2
- package/dist/server/types.d.ts.map +1 -1
- package/dist/server/types.js +1 -1
- package/dist/tools/portfolio/PortfolioElementAdapter.d.ts.map +1 -1
- package/dist/tools/portfolio/PortfolioElementAdapter.js +3 -1
- package/package.json +9 -3
- package/dist/persona/export-import/PersonaSharer.d.ts +0 -81
- package/dist/persona/export-import/PersonaSharer.d.ts.map +0 -1
- package/dist/persona/export-import/PersonaSharer.js +0 -678
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dollhousemcp/mcp-server",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"description": "DollhouseMCP - A Model Context Protocol (MCP) server that enables dynamic AI persona management from markdown files, allowing Claude and other compatible AI assistants to activate and switch between different behavioral personas.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -18,7 +18,11 @@
|
|
|
18
18
|
"clean": "rm -rf dist",
|
|
19
19
|
"rebuild": "npm run clean && npm run build",
|
|
20
20
|
"setup": "npm install && npm run build",
|
|
21
|
-
"
|
|
21
|
+
"build:readme": "node scripts/build-readme.js",
|
|
22
|
+
"build:readme:npm": "node scripts/build-readme.js --target=npm",
|
|
23
|
+
"build:readme:github": "node scripts/build-readme.js --target=github",
|
|
24
|
+
"prepublishOnly": "npm run build:readme:npm && cp README.md README.md.backup 2>/dev/null || true && cp README.npm.md README.md && BUILD_TYPE=npm npm run build",
|
|
25
|
+
"postpublish": "if [ -f README.md.backup ]; then mv README.md.backup README.md; else echo 'No backup found, README.md unchanged'; fi",
|
|
22
26
|
"test": "cross-env \"NODE_OPTIONS=--experimental-vm-modules --no-warnings\" jest --config test/jest.config.cjs",
|
|
23
27
|
"test:watch": "cross-env \"NODE_OPTIONS=--experimental-vm-modules --no-warnings\" jest --config test/jest.config.cjs --watch",
|
|
24
28
|
"test:coverage": "cross-env \"NODE_OPTIONS=--experimental-vm-modules --no-warnings\" jest --config test/jest.config.cjs --coverage",
|
|
@@ -57,7 +61,9 @@
|
|
|
57
61
|
"qa:simple": "node scripts/qa-simple-test.js",
|
|
58
62
|
"update:version": "node scripts/update-version.mjs",
|
|
59
63
|
"version:bump": "node scripts/update-version.mjs",
|
|
60
|
-
"version:check": "node scripts/update-version.mjs --dry-run"
|
|
64
|
+
"version:check": "node scripts/update-version.mjs --dry-run",
|
|
65
|
+
"tools:count": "node scripts/count-tools.js",
|
|
66
|
+
"tools:list": "node scripts/count-tools.js --json"
|
|
61
67
|
},
|
|
62
68
|
"keywords": [
|
|
63
69
|
"mcp",
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Persona sharing functionality via URLs
|
|
3
|
-
*
|
|
4
|
-
* SECURITY FIX IMPLEMENTED (Defense-in-Depth Validation):
|
|
5
|
-
* 1. CRITICAL: Added validate-before-return pattern in all import methods
|
|
6
|
-
* 2. HIGH: Content security validation using ContentValidator before data return
|
|
7
|
-
* 3. MEDIUM: Size validation to prevent memory exhaustion attacks
|
|
8
|
-
* 4. MEDIUM: Structure validation to prevent malformed data processing
|
|
9
|
-
* 5. DEFENSE-IN-DEPTH: Multiple validation layers before PersonaImporter processing
|
|
10
|
-
*
|
|
11
|
-
* This provides defense-in-depth security by validating content at the earliest
|
|
12
|
-
* possible point before any data is returned to calling code or file operations.
|
|
13
|
-
*/
|
|
14
|
-
import { Persona } from '../../types/persona.js';
|
|
15
|
-
import { GitHubClient } from '../../collection/GitHubClient.js';
|
|
16
|
-
export interface ShareResult {
|
|
17
|
-
success: boolean;
|
|
18
|
-
url?: string;
|
|
19
|
-
gistId?: string;
|
|
20
|
-
expiresAt?: string;
|
|
21
|
-
message: string;
|
|
22
|
-
}
|
|
23
|
-
export declare class PersonaSharer {
|
|
24
|
-
private githubClient;
|
|
25
|
-
private currentUser;
|
|
26
|
-
private exporter;
|
|
27
|
-
private githubRateLimiter;
|
|
28
|
-
constructor(githubClient: GitHubClient, currentUser: string | null);
|
|
29
|
-
/**
|
|
30
|
-
* Share a persona via GitHub Gist
|
|
31
|
-
*/
|
|
32
|
-
sharePersona(persona: Persona, expiryDays?: number): Promise<ShareResult>;
|
|
33
|
-
/**
|
|
34
|
-
* Import a persona from a share URL
|
|
35
|
-
* SECURITY FIX: Validate ALL content before returning any data
|
|
36
|
-
*/
|
|
37
|
-
importFromUrl(url: string): Promise<{
|
|
38
|
-
success: boolean;
|
|
39
|
-
data?: any;
|
|
40
|
-
message: string;
|
|
41
|
-
}>;
|
|
42
|
-
/**
|
|
43
|
-
* Create a GitHub Gist
|
|
44
|
-
*/
|
|
45
|
-
private createGist;
|
|
46
|
-
/**
|
|
47
|
-
* Create a base64 URL (fallback)
|
|
48
|
-
*/
|
|
49
|
-
private createBase64Url;
|
|
50
|
-
/**
|
|
51
|
-
* Import from GitHub Gist
|
|
52
|
-
*/
|
|
53
|
-
private importFromGist;
|
|
54
|
-
/**
|
|
55
|
-
* Validate URL for security (prevent SSRF attacks)
|
|
56
|
-
*/
|
|
57
|
-
private validateShareUrl;
|
|
58
|
-
/**
|
|
59
|
-
* Import from base64 URL
|
|
60
|
-
*/
|
|
61
|
-
private importFromBase64Url;
|
|
62
|
-
/**
|
|
63
|
-
* Extract Gist ID from GitHub URL
|
|
64
|
-
*/
|
|
65
|
-
private extractGistId;
|
|
66
|
-
/**
|
|
67
|
-
* Format share success message
|
|
68
|
-
*/
|
|
69
|
-
private formatShareSuccess;
|
|
70
|
-
/**
|
|
71
|
-
* SECURITY FIX: Validate persona data before any processing
|
|
72
|
-
* This provides defense-in-depth validation before content reaches file operations
|
|
73
|
-
*/
|
|
74
|
-
private validatePersonaData;
|
|
75
|
-
/**
|
|
76
|
-
* ENHANCED SECURITY FIX: Comprehensive Content-Type validation
|
|
77
|
-
* Strengthens MIME type validation with comprehensive security checks
|
|
78
|
-
*/
|
|
79
|
-
private validateContentType;
|
|
80
|
-
}
|
|
81
|
-
//# sourceMappingURL=PersonaSharer.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"PersonaSharer.d.ts","sourceRoot":"","sources":["../../../src/persona/export-import/PersonaSharer.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAEjD,OAAO,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAWhE,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,OAAO,CAAC;IACjB,GAAG,CAAC,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