Atlas / MCP servers / praneshasp / Foundry

FoundryBLOCK

mcp/praneshasp/foundry-1

An experimental MCP Server for foundry built for Solidity devs

Verdict
BLOCK
Grade
D
Trust score
69 /100
Exposed tools
16 11r · 5w · 0d
Transport
stdio
License
MIT
Stars
253
01

Overview

From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.

A simple, lightweight and fast MCP (Model Context Protocol) server that provides Solidity development capabilities using the Foundry toolchain (Forge, Cast, and Anvil).

Overview

This server connects LLM assistants to the Foundry ecosystem, enabling them to:

  • Interact with nodes (local Anvil instances or remote RPC endpoints)
  • Analyze smart contracts and blockchain data
  • Perform common EVM operations using Cast
  • Manage, deploy, and execute Solidity code and scripts
  • Work with a persistent Forge workspace

Features

Network Interaction

  • Start and manage local Anvil instances
  • Connect to any remote network (just specify the RPC)
  • Get network/chain information

Contract Interaction

  • Call contract functions (read-only)
  • Send transactions to contracts (if PRIVATE_KEY is configured)
  • Get transaction receipts
  • Read contract storage
  • Analyze transaction traces
  • Retrieve contract ABIs and sources from block explorers

Solidity Development

  • Maintain a dedicated Forge workspace
  • Create and edit Solidity files
  • Install dependencies
  • Run Forge scripts
  • Deploy contracts

Utility Functions

  • Calculate contract addresses
  • Check contract bytecode size
  • Estimate gas costs
  • Convert between units (hex to decimals, etc.,)
  • Generate wallets
  • Get event logs
  • Lookup function and event signatures

Smart Contract Analysis (Heimdall)

  • Disassemble EVM bytecode into human-readable opcodes
  • Decode raw calldata without requiring ABI
  • Decompile EVM bytecode to Solidity source code and ABI
  • Generate visual control flow graphs for EVM bytecode
  • Detailed transaction inspection with calldata decoding and trace analysis

Usage

The server is designed to be used as an MCP tool provider for MCP Clients. When connected to a client, it enables the clients(claude desktop, cursor, client, etc.,) to perform Solidity and onchain operations directly.

Requirements

  • [N
Read from source at commit 2f8359351517OBSERVED · 2026-10-06
02

Connect

Built from this server's own package name, version and transport as found in its source — not copied from anyone's documentation, so it cannot drift against a page we do not control. Replace the environment placeholders with a token scoped to the least it needs.

claude-code
claude mcp add foundry-mcp-server --env PRIVATE_KEY=${PRIVATE_KEY} -- npx -y @pranesh.asp/[email protected]
claude-desktop
{
  "mcpServers": {
    "foundry-mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@pranesh.asp/[email protected]"
      ],
      "env": {
        "PRIVATE_KEY": "${PRIVATE_KEY}"
      }
    }
  }
}
03

Exposed tools (16)

11 read · 5 write · 0 destructive.

ToolRiskDescription
anvil_startwriteStart a new Anvil instance (local Ethereum node)
anvil_statusreadCheck if Anvil is running and get its status
anvil_stopwriteStop a running Anvil instance
cast_balancereadCheck the ETH balance of an address
cast_callreadCall a contract function (read-only)
cast_chainreadGet information about the current chain
cast_receiptreadGet the transaction receipt
cast_sendwriteSend a transaction to a contract function
convert_eth_unitsreadConvert between Ethereum units (wei, gwei, ether)
create_solidity_filewriteCreate or update a Solidity file in the workspace
forge_scriptwriteRun a Forge script from the workspace
heimdall_cfgreadGenerate visual control flow graph for EVM bytecode using Heimdall
heimdall_decodereadDecode raw calldata without requiring ABI using Heimdall
heimdall_decompilereadDecompile EVM bytecode to Solidity source code and ABI using Heimdall
heimdall_disassemblereadDisassemble EVM bytecode into human-readable opcodes using Heimdall
heimdall_inspectreadDetailed inspection of Ethereum transactions including calldata decoding, trace analysis, and log visualization using Heimdall
04

Trust audit

BLOCKgrade D · trust 69/100 Do not install this without reading the findings. The audit found something that could harm you or your machine.

LayerWhat it checksResult
L0Provenance & inventoryWARN
L1Static analysis of the codeFAIL
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfacePASS
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
declared (5 observation(s))
Network
declared (3 observation(s))
Shell
declared (1 observation(s))
Dependencies
not all pinned
Secrets in source
none-found

Findings (11)

HIGHCode injection · code.eval_exec · CWE-78, CWE-94, CWE-95
src/tools/anvil/start.ts:65
const child = exec(command, (error, stdout, stderr) => {
Why it matters. evaluates text as code
Fix. remove; use a parser or a dispatch table
HIGHNetwork egress · net.tls_off · CWE-200, CWE-319
src/tools/forge/script.ts:20
async ({ scriptPath, sig = "run()", rpcUrl, broadcast = false, verify = false }) => {
Why it matters. certificate verification is disabled
Fix. leave verification on
MEDIUMInventory / provenance · inv.binary · CWE-1104
bun.lockb
bun.lockb
Why it matters. a compiled or binary member cannot be reviewed from source
Fix. ship source, or explain the binary in the README
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
src/tools/anvil/start.ts:4
import { checkFoundryInstalled, FOUNDRY_PATHS, FOUNDRY_NOT_INSTALLED_ERROR } from "../../utils/command.js";
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
src/tools/anvil/start.ts:5
import { getAnvilInfo } from "../../utils/rpc.js";
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
src/tools/anvil/status.ts:2
import { getAnvilInfo } from "../../utils/rpc.js";
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
src/tools/anvil/stop.ts:5
import { getAnvilInfo } from "../../utils/rpc.js";
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
src/tools/cast/balance.ts:3
import { checkFoundryInstalled, executeCommand, FOUNDRY_PATHS, FOUNDRY_NOT_INSTALLED_ERROR } from "../../utils/command.js";
LOWSupply chain · supply.unpinned · CWE-829, CWE-1357
package.json
@modelcontextprotocol/sdk, @pranesh.asp/foundry-mcp-server, dotenv, typescript, zod, @types/bun
Why it matters. 6 dependency range(s) float
Fix. pin exact versions or ship a lockfile
LOWSupply chain · prompt.pipe_to_shell · CWE-829, CWE-1357
README.md:75
curl -L https://foundry.paradigm.xyz | bash
INFOInventory / provenance · inv.oversize · CWE-1104
assets/analysis_gif.gif
assets/analysis_gif.gif
Why it matters. 7169186 bytes not read

Gates applied: no_behavioural_pass.

Audited 2026-10-06 · audit v0.4.1 · source sha 2f8359351517full audit observations/trust-audit/mcp-server/praneshasp__foundry-1.json · Report an issue / request a re-scan
05

Audit history

Every audit this server has had. A grade with a past is a grade somebody is still checking.

DateSourceVerdictGradeScoreChange
2026-10-062f8359351517BLOCKD69first audit
06

Questions

What is the Foundry MCP server?

An experimental MCP Server for foundry built for Solidity devs

What tools does Foundry expose?

16 in total: 11 read-only, 5 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.

Is Foundry safe to connect to an agent?

No — not without reading the findings first. The audit graded it D (69/100) and found 2 critical or high issues in the source. Each one is listed on this page with the file and line it is on.

What credentials does Foundry need?

It reads PRIVATE_KEY from the environment. Give it a token scoped to the least it needs — an agent that can be talked into calling a tool can be talked into calling it with your credentials.

How does Foundry run?

It speaks stdio, so it runs as a local process your client starts. It is published on npm as @pranesh.asp/foundry-mcp-server at 0.1.5.

How current is this page?

The grade is for one exact copy of the source (2f8359351517), read on 2026-10-06. The repository is watched and re-audited when it changes.

Advertisement