@mcp-b/chrome-devtools-mcp 1.6.3 → 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/build/src/McpContext.js +4 -2
- package/build/src/cli.js +5 -4
- package/build/src/third_party/index.js +1 -1
- package/package.json +13 -13
package/build/src/McpContext.js
CHANGED
|
@@ -916,7 +916,8 @@ export class McpContext {
|
|
|
916
916
|
try {
|
|
917
917
|
const dir = await fs.mkdtemp(path.join(os.tmpdir(), 'chrome-devtools-mcp-'));
|
|
918
918
|
const filename = path.join(dir, `screenshot.${getExtensionFromMimeType(mimeType)}`);
|
|
919
|
-
|
|
919
|
+
// Use mode 0o600 (owner read/write only) for secure temp file creation
|
|
920
|
+
await fs.writeFile(filename, data, { mode: 0o600 });
|
|
920
921
|
return { filename };
|
|
921
922
|
}
|
|
922
923
|
catch (err) {
|
|
@@ -927,7 +928,8 @@ export class McpContext {
|
|
|
927
928
|
async saveFile(data, filename) {
|
|
928
929
|
try {
|
|
929
930
|
const filePath = path.resolve(filename);
|
|
930
|
-
|
|
931
|
+
// Use mode 0o644 (owner read/write, others read) for user-specified paths
|
|
932
|
+
await fs.writeFile(filePath, data, { mode: 0o644 });
|
|
931
933
|
return { filename };
|
|
932
934
|
}
|
|
933
935
|
catch (err) {
|
package/build/src/cli.js
CHANGED
|
@@ -170,10 +170,11 @@ export function parseArguments(version, argv = process.argv) {
|
|
|
170
170
|
.check(args => {
|
|
171
171
|
// We can't set default in the options else
|
|
172
172
|
// Yargs will complain
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
173
|
+
// Note: Use explicit undefined checks since empty strings are valid falsy values
|
|
174
|
+
if (args.channel === undefined &&
|
|
175
|
+
args.browserUrl === undefined &&
|
|
176
|
+
args.wsEndpoint === undefined &&
|
|
177
|
+
args.executablePath === undefined) {
|
|
177
178
|
args.channel = 'dev';
|
|
178
179
|
}
|
|
179
180
|
return true;
|
|
@@ -11,6 +11,6 @@ export { default as debug } from 'debug';
|
|
|
11
11
|
export { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
12
12
|
export { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
|
|
13
13
|
export { SetLevelRequestSchema, ToolListChangedNotificationSchema, } from '@modelcontextprotocol/sdk/types.js';
|
|
14
|
-
export { z as zod } from 'zod
|
|
14
|
+
export { z as zod } from 'zod';
|
|
15
15
|
export { Locator, PredefinedNetworkConditions, CDPSessionEvent, } from 'puppeteer-core';
|
|
16
16
|
export { default as puppeteer } from 'puppeteer-core';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mcp-b/chrome-devtools-mcp",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"description": "MCP server for Chrome DevTools with WebMCP integration for connecting to website MCP tools",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"mcp",
|
|
@@ -48,29 +48,29 @@
|
|
|
48
48
|
"!*.tsbuildinfo"
|
|
49
49
|
],
|
|
50
50
|
"dependencies": {
|
|
51
|
-
"@composio/json-schema-to-zod": "^0.1.
|
|
52
|
-
"@modelcontextprotocol/sdk": "1.
|
|
51
|
+
"@composio/json-schema-to-zod": "^0.1.19",
|
|
52
|
+
"@modelcontextprotocol/sdk": "1.25.2",
|
|
53
53
|
"core-js": "3.47.0",
|
|
54
54
|
"debug": "4.4.3",
|
|
55
|
-
"esbuild": "^0.
|
|
55
|
+
"esbuild": "^0.27.2",
|
|
56
56
|
"puppeteer": "24.32.0",
|
|
57
57
|
"puppeteer-core": "24.32.0",
|
|
58
58
|
"yargs": "18.0.0",
|
|
59
|
-
"zod": "
|
|
59
|
+
"zod": "3.25.76"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
62
|
"@eslint/js": "^9.35.0",
|
|
63
|
-
"@modelcontextprotocol/sdk": "1.
|
|
63
|
+
"@modelcontextprotocol/sdk": "1.25.2",
|
|
64
64
|
"@rollup/plugin-commonjs": "^29.0.0",
|
|
65
65
|
"@rollup/plugin-json": "^6.1.0",
|
|
66
66
|
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
67
|
-
"@stylistic/eslint-plugin": "^5.
|
|
67
|
+
"@stylistic/eslint-plugin": "^5.7.1",
|
|
68
68
|
"@types/debug": "^4.1.12",
|
|
69
69
|
"@types/filesystem": "^0.0.36",
|
|
70
70
|
"@types/node": "^24.3.3",
|
|
71
71
|
"@types/sinon": "^21.0.0",
|
|
72
72
|
"@types/yargs": "^17.0.33",
|
|
73
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
73
|
+
"@typescript-eslint/eslint-plugin": "^8.53.1",
|
|
74
74
|
"@typescript-eslint/parser": "^8.43.0",
|
|
75
75
|
"chrome-devtools-frontend": "1.0.1550444",
|
|
76
76
|
"core-js": "3.47.0",
|
|
@@ -79,17 +79,17 @@
|
|
|
79
79
|
"eslint-import-resolver-typescript": "^4.4.4",
|
|
80
80
|
"eslint-plugin-import": "^2.32.0",
|
|
81
81
|
"globals": "^16.4.0",
|
|
82
|
-
"prettier": "^3.
|
|
82
|
+
"prettier": "^3.8.1",
|
|
83
83
|
"puppeteer": "24.32.0",
|
|
84
84
|
"puppeteer-core": "24.32.0",
|
|
85
85
|
"rollup": "4.53.3",
|
|
86
86
|
"rollup-plugin-cleanup": "^3.2.1",
|
|
87
87
|
"rollup-plugin-license": "^3.6.0",
|
|
88
|
-
"sinon": "^21.0.
|
|
88
|
+
"sinon": "^21.0.1",
|
|
89
89
|
"typescript": "^5.9.2",
|
|
90
|
-
"typescript-eslint": "^8.
|
|
90
|
+
"typescript-eslint": "^8.53.1",
|
|
91
91
|
"yargs": "18.0.0",
|
|
92
|
-
"zod": "
|
|
92
|
+
"zod": "3.25.76"
|
|
93
93
|
},
|
|
94
94
|
"engines": {
|
|
95
95
|
"node": "^20.19.0 || ^22.12.0 || >=23"
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
"mcpName": "io.github.ChromeDevTools/chrome-devtools-mcp"
|
|
104
104
|
},
|
|
105
105
|
"scripts": {
|
|
106
|
-
"build": "tsc && node --experimental-strip-types --no-warnings=ExperimentalWarning scripts/post-build.ts",
|
|
106
|
+
"build": "rm -rf build/vendor build/node_modules build/tsconfig.tsbuildinfo && tsc && node --experimental-strip-types --no-warnings=ExperimentalWarning scripts/post-build.ts",
|
|
107
107
|
"bundle": "npm run clean && npm run build && rollup -c rollup.config.mjs",
|
|
108
108
|
"check-format": "eslint --cache . && prettier --check --cache .;",
|
|
109
109
|
"clean": "node -e \"require('fs').rmSync('build', {recursive: true, force: true})\"",
|