{"package":"apple-notes-mcp","version":"2.6.12","known":true,"status":"done","discovered_at":1790179901024,"has_install_script":true,"report_url":"https://andymal.com/packages/apple-notes-mcp/2.6.12","verdict":"clean","action":"allow","confidence":0.85,"summary":"Install hook is benign (pnpm lockfile enforcement). Entry file spawns osascript and sqlite3 to interact with Apple Notes — expected for this domain. No network egress, no credential reads, no persistence observed in the lab.","intent":"MCP server for Apple Notes on macOS — creates, searches, reads, updates, and deletes notes via AppleScript/Apple Notes automation. Nothing more.","capabilities":[],"iocs":{"domains":[],"urls":[],"ips":[],"paths":[],"hashes":["d056e6eec1400ba19ab8463f5f1f85d5ba5efa02"]},"analyzed_at":1790269301770,"detonated":true,"model":"yolo","findings":[{"title":"Benign preinstall hook","detail":"Checks for .git directory and npm_config_user_agent; exits with error if not using pnpm. Does not download, decode, or execute anything.","severity":"info","location":"package.json:77"},{"title":"AppleScript execution for Apple Notes","detail":"build/index.js calls execFileSync('osascript') and execFileSync('sqlite3') to query and modify the Apple Notes SQLite database — standard macOS automation pattern.","severity":"info","location":"build/index.js:38841, build/index.js:39016"},{"title":"ajv new Function (false positive)","detail":"build/index.js:2953 uses new Function() — this is the bundled ajv JSON schema validator compiling validation functions, not dynamic code execution of untrusted input.","severity":"info","location":"build/index.js:2953"},{"title":"whatwg-url percent-decoding (false positive)","detail":"build/index.js:3332,3353,3393,3866 decode URI percent-encoded characters via String.fromCharCode/unescape — standard URL parsing, not obfuscation.","severity":"info","location":"build/index.js:3332,3353,3393,3866"}],"lab":{"ok":true,"lab_version":2,"duration_ms":2555,"lab_ip":"10.77.0.151","hooks":[{"name":"preinstall","command":");const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\n\\n  corepack enable && pnpm install --frozen-lockfile\\n');process.exit(1)}\"","exit":0,"timed_out":false,"seconds":1,"stdout_tail":"\n> apple-notes-mcp@2.6.12 preinstall\n> node -e \"const fs=require('fs');const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\n\\n  corepack enable && pnpm install --frozen-lockfile\\n');process.exit(1)}\"\n\n","stderr_tail":""},{"name":"require","command":"node -e require(pkg)","exit":0,"timed_out":false,"seconds":0,"stdout_tail":"","stderr_tail":"require failed: require() cannot be used on an ESM graph with top-level await. Use import() instead. To see where the top-level await comes from, use --experimental-print-required-tla.\n  From /work/pkg/[eval] \n  Requiring /work/pkg/build/index.js \n"}],"process_count":6,"processes":["npm run-script preinstall --if-present --ignore-scripts=false","node /usr/local/bin/npm run-script preinstall --if-present --ignore-scripts=false","sh -c node -e \"const fs=require('fs');const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\\n\\\n","node -e const fs=require('fs');const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\\n\\\n  corepac","timeout -s KILL 30 node -e try{require(\"/work/pkg\")}catch(e){console.error(\"require failed:\",e&&e.message)}","node -e try{require(\"/work/pkg\")}catch(e){console.error(\"require failed:\",e&&e.message)}"],"network":{"connects":[],"dns":[],"http":[],"tls":[],"tcp":[]},"files_written":[],"files_deleted":[],"canary_reads":[],"canary_leaks":[],"persistence":[],"notes":[]},"static":{"manifest":{"name":"apple-notes-mcp","version":"2.6.12","description":"MCP server for Apple Notes - create, search, update, and manage notes via Claude and other AI assistants","scripts":{"preinstall":"node -e \"const fs=require('fs');const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\n\\n  corepack enable && pnpm install --frozen-lockfile\\n');process.exit(1)}\"","build":"tsc --noEmit && esbuild src/index.ts --bundle --platform=node --format=esm --target=node20 --outfile=build/index.js --banner:js=\"import { createRequire as __createRequire } from 'node:module'; const require = __createRequire(import.meta.url);\"","start":"node build/index.js","dev":"tsc --watch","test":"vitest run","test:watch":"vitest","test:coverage":"vitest run --coverage","test:integration":"vitest run --config vitest.integration.config.ts","test:all":"vitest run && vitest run --config vitest.integration.config.ts","lint":"eslint src","lint:fix":"eslint src --fix","format":"prettier --write src","format:check":"prettier --check src","typecheck":"tsc --noEmit","sync:skills":"node scripts/sync-skills.mjs","version":"node scripts/sync-plugin-version.mjs && git add .claude-plugin .agents/plugins codex .antigravity-plugin"},"install_hooks":{"preinstall":"node -e \"const fs=require('fs');const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\n\\n  corepack enable && pnpm install --frozen-lockfile\\n');process.exit(1)}\""},"bin":{"apple-notes-mcp":"build/index.js"},"main":"build/index.js","dependencies":["@modelcontextprotocol/sdk","turndown","zod"],"author":"Rob Sweet <rob@superiortech.io>","repository":"git+https://github.com/sweetrb/apple-notes-mcp.git","homepage":"https://github.com/sweetrb/apple-notes-mcp#readme","license":"MIT","hasInstallScript":true},"files":[{"path":"build/index.js","size":1502161,"kind":"text","score":1,"hits":["credential_harvest","code_execution","obfuscation","reconnaissance"],"role":"entry"},{"path":"docs/NODE-RUNTIME-AND-TCC-PERMISSIONS.md","size":4511,"kind":"text","score":0.9191666666666667,"hits":["network_egress","download_execute","agent_config_tamper"]},{"path":"docs/STABILITY-PERF-AUDIT-2026-06-19.md","size":10087,"kind":"text","score":0.4512333333333334,"hits":["code_execution","crypto_wallet"]},{"path":"README.md","size":53228,"kind":"text","score":0.4175,"hits":["agent_config_tamper","inj:instruction_to_ai","inj:system_impersonation","inj:conceal_from_user"]},{"path":"package.json","size":3027,"kind":"text","score":0.10033333333333333,"hits":["install_hook_shell"]},{"path":"docs/APPLESCRIPT-LIMITATIONS.md","size":4211,"kind":"text","score":0,"hits":[]},{"path":"docs/FULL-DISK-ACCESS.md","size":3298,"kind":"text","score":0,"hits":[]},{"path":"docs/JXA_RESEARCH.md","size":4700,"kind":"text","score":0,"hits":[]},{"path":"LICENSE","size":1066,"kind":"text","score":0,"hits":[]}],"file_count":9,"unpacked_size":1586289,"findings":[{"title":"Install hook with shell download/eval","detail":"preinstall: node -e \"const fs=require('fs');const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\n\\n  corepack enable && pnpm install --frozen-lockfile\\n');process.exit(1)}\"","severity":"high","location":"package.json"},{"title":"Reads or writes AI agent configuration, skills or instruction files","detail":"otes-mcp/blob/main/.antigravity-plugin/mcp_config.json) to `~/.gemini/config/mcp_config.json` (or via Antigravity's MCP settings).","severity":"high","location":"README.md:92"},{"title":"Reads or writes AI agent configuration, skills or instruction files","detail":"to Claude Desktop** (`~/Library/Application Support/Claude/claude_desktop_config.json`): ```json { \"mcpServers\": { \"apple-notes\": { \"","severity":"high","location":"README.md:101"},{"title":"Reads or writes AI agent configuration, skills or instruction files","detail":"ub.com/sweetrb/apple-notes-mcp/blob/main/skills/apple-notes/SKILL.md#attachment-safe-updates) guidance. --- #### `delete-note`","severity":"high","location":"README.md:420"},{"title":"Reads or writes AI agent configuration, skills or instruction files","detail":"` #### Running from a clone in Claude Code (project-scope `.mcp.json`) This repo ships a `.mcp.json` at its root so that, when","severity":"high","location":"README.md:1009"},{"title":"Dumps the whole environment (API keys live there)","detail":"BYTES = 25 * 1024 * 1024; function maxAttachmentBytes(env = process.env) { const raw = env.APPLE_NOTES_MCP_MAX_ATTACHMENT_BYTES;","severity":"high","location":"build/index.js:39188"},{"title":"Dumps the whole environment (API keys live there)","detail":"MAGE_BYTES = 256 * 1024; function maxInlineImageBytes(env = process.env) { const raw = env.APPLE_NOTES_MCP_MAX_INLINE_IMAGE_BYTES;","severity":"high","location":"build/index.js:41801"},{"title":"Dumps the whole environment (API keys live there)","detail":"edir as homedir6 } from \"os\"; function fileConfigPath(env = process.env) { const override = env.APPLE_NOTES_MCP_CONFIG_FILE; if","severity":"high","location":"build/index.js:41974"},{"title":"Dumps the whole environment (API keys live there)","detail":"notes-mcp\", \"config.json\"); } function loadFileConfig(env = process.env, path4 = fileConfigPath(env)) { const applied = []; try","severity":"high","location":"build/index.js:41979"},{"title":"Executes commands or dynamic code","detail":"code.process(sourceCode, sch); const makeValidate = new Function(`${names_1.default.self}`, `${names_1.default.scope}`, sourc","severity":"medium","location":"build/index.js:2953"},{"title":"Executes commands or dynamic code","detail":"} }); } }; // src/utils/applescript.ts import { execFileSync } from \"child_process\"; var DEFAULT_TIMEOUT_MS = 3e4; var D","severity":"medium","location":"build/index.js:38671"},{"title":"Executes commands or dynamic code","detail":"// src/utils/applescript.ts import { execFileSync } from \"child_process\"; var DEFAULT_TIMEOUT_MS = 3e4; var DEFAULT_MAX_BUFFER_BYTE","severity":"medium","location":"build/index.js:38671"},{"title":"Executes commands or dynamic code","detail":"t attemptStart = Date.now(); try { const output = execFileSync(\"osascript\", [\"-\"], { input: preparedScript,","severity":"medium","location":"build/index.js:38841"},{"title":"Obfuscated or encoded code","detail":"malizedHex = hex.toUpperCase(); const decoded = String.fromCharCode(parseInt(normalizedHex, 16)); if (decodeUnreser","severity":"high","location":"build/index.js:3332"},{"title":"Obfuscated or encoded code","detail":"malizedHex = hex.toUpperCase(); const decoded = String.fromCharCode(parseInt(normalizedHex, 16)); if (decoded !== \"","severity":"high","location":"build/index.js:3353"},{"title":"Obfuscated or encoded code","detail":"} if (component.host !== void 0) { let host = unescape(component.host); if (!isIPv4(host)) { cons","severity":"high","location":"build/index.js:3393"},{"title":"Obfuscated or encoded code","detail":"(parsed.scheme !== void 0) { parsed.scheme = unescape(parsed.scheme); } if (parsed.host !=","severity":"high","location":"build/index.js:3866"},{"title":"System reconnaissance","detail":"HECKLIST_STYLE_TYPE = 103; var NOTES_DB_PATH = path.join( os.homedir(), \"Library/Group Containers/group.com.apple.notes/NoteStor","severity":"low","location":"build/index.js:39010"},{"title":"Network activity","detail":"rwin-arm64 mkdir -p ~/mcp-runtime && cd ~/mcp-runtime curl -O https://nodejs.org/dist/$VER/node-$VER-$ARCH.tar.gz cu","severity":"medium","location":"docs/NODE-RUNTIME-AND-TCC-PERMISSIONS.md:60"},{"title":"Network activity","detail":"l -O https://nodejs.org/dist/$VER/node-$VER-$ARCH.tar.gz curl -O https://nodejs.org/dist/$VER/SHASUMS256.txt grep \" no","severity":"medium","location":"docs/NODE-RUNTIME-AND-TCC-PERMISSIONS.md:61"},{"title":"Download-and-execute chain","detail":"rwin-arm64 mkdir -p ~/mcp-runtime && cd ~/mcp-runtime curl -O https://nodejs.org/dist/$VER/node-$VER-$ARCH.tar.gz curl -O https://nodejs.org/dist/$VER/S","severity":"critical","location":"docs/NODE-RUNTIME-AND-TCC-PERMISSIONS.md:60"},{"title":"Download-and-execute chain","detail":"l -O https://nodejs.org/dist/$VER/node-$VER-$ARCH.tar.gz curl -O https://nodejs.org/dist/$VER/SHASUMS256.txt grep \" node-$VER-$ARCH.t","severity":"critical","location":"docs/NODE-RUNTIME-AND-TCC-PERMISSIONS.md:61"},{"title":"Reads or writes AI agent configuration, skills or instruction files","detail":"aude Desktop, edit `~/Library/Application Support/Claude/claude_desktop_config.json` and set this server's `command` to the absolute path:","severity":"high","location":"docs/NODE-RUNTIME-AND-TCC-PERMISSIONS.md:76"},{"title":"Executes commands or dynamic code","detail":"| Status | |---|---------|------|-------|--------| | H1 | `execSync` has no `maxBuffer` cap | High | [#16](https://github.com/s","severity":"medium","location":"docs/STABILITY-PERF-AUDIT-2026-06-19.md:16"},{"title":"Executes commands or dynamic code","detail":"en full regression + docs + merge. --- ## High ### H1 — `execSync` has no `maxBuffer` cap → ENOBUFS on large output (S) `src/","severity":"medium","location":"docs/STABILITY-PERF-AUDIT-2026-06-19.md:42"},{"title":"Executes commands or dynamic code","detail":"/utils/applescript.ts:324` and `src/utils/jxa.ts:103` call `execSync` with no `maxBuffer`, inheriting Node's 1 MB default. `expo","severity":"medium","location":"docs/STABILITY-PERF-AUDIT-2026-06-19.md:43"},{"title":"Executes commands or dynamic code","detail":"-note-content` on long notes can exceed it. Over the limit `execSync` throws and the catch path returns `[]`/`null` — a silent,","severity":"medium","location":"docs/STABILITY-PERF-AUDIT-2026-06-19.md:47"},{"title":"Crypto wallet targeting or address swapping","detail":":326-345`). A note titled \"Groceries, etc.\" splits into two phantom notes. **This is a real data-corruption-on-ordinary-input b","severity":"high","location":"docs/STABILITY-PERF-AUDIT-2026-06-19.md:64"},{"title":"Install hook runs a script","detail":"ix\", \"prettier --write\" ] }, \"scripts\": { \"preinstall\": \"node -e \\\"const fs=require('fs');const ua=process.env.npm_config_us","severity":"medium","location":"package.json:77"}],"injection_findings":[{"title":"Text addresses an AI agent directly","detail":"le-notes-mcp ``` ### Using the Plugin Marketplace Install as a Claude Code plugin for automatic configuration and enhanced AI beh","severity":"high","location":"README.md:50"},{"title":"Impersonates a system or operator message","detail":"does **not** support nested defaults like `${CLAUDE_PLUGIN_ROOT:-${CLAUDE_PROJECT_DIR:-.}}`, so a single entrypoint string c","severity":"high","location":"README.md:1021"},{"title":"Asks the agent to hide actions from its user","detail":"tes` to see available notes ### Note creation/update fails silently with backslashes - Content containing `\\` characters requir","severity":"critical","location":"README.md:1186"},{"title":"Asks the agent to hide actions from its user","detail":"o macOS TCC treats each new build as a brand-new binary and silently drops the grants you already made. The fix is to run this s","severity":"critical","location":"README.md:1253"}],"hits":{"agent_config_tamper":6,"credential_harvest":4,"code_execution":10,"obfuscation":5,"reconnaissance":1,"network_egress":2,"download_execute":2,"crypto_wallet":1,"install_hook_shell":1},"iocs":{"urls":["https://modelcontextprotocol.io/","https://api.securityscorecards.dev/projects/github.com/sweetrb/apple-notes-mcp/badge","https://scorecard.dev/viewer/?uri=github.com/sweetrb/apple-notes-mcp","https://modelcontextprotocol.io","https://claude.com/product/claude-code","https://hermes-agent.nousresearch.com/","https://antigravity.google/","https://www.superiortech.io","http://json-schema.org/draft-07/schema#","http://json-schema.org/draft-07/schema","http://json-schema.org/schema","https://mathiasbynens.be/demo/url-regex","https://www.safaribooksonline.com/library/view/regular-expressions-cookbook/9780596802837/ch07s16.html","https://spec.openapis.org/oas/v3.0.0#data-types","http://www.whatwg.org/specs/web-apps/current-work/multipage/webappapis.html#event-handlers","http://www.whatwg.org/specs/web-apps/current-work/multipage/elements.html#interactive-content-0"],"domains":["modelcontextprotocol.io","api.securityscorecards.dev","scorecard.dev","claude.com","hermes-agent.nousresearch.com","antigravity.google","www.superiortech.io","json-schema.org","mathiasbynens.be","www.safaribooksonline.com","spec.openapis.org","www.whatwg.org","superiortech.io","notes.app","claude.app","terminal.app","code.app","iterm.app","htmlelement.click","group.com","mail.app"],"ips":[]},"score":1,"priority":140,"hints":["install hook preinstall: node -e \"const fs=require('fs');const ua=process.env.npm_config_user_agent||'';if(fs.existsSync('.git')&&!ua.startsWith('pnpm')){console.error('\\nThis repo uses pnpm. npm/yarn resolve dependencies off-lockfile and the committed bundle will mismatch CI.\\n\\n  corepack enable && pnpm install --frozen-lockfile\\n');process.exit(1)}\"","untrusted hosts referenced: modelcontextprotocol.io, api.securityscorecards.dev, scorecard.dev, claude.com, hermes-agent.nousresearch.com, antigravity.google, www.superiortech.io, json-schema.org, mathiasbynens.be, www.safaribooksonline.com, spec.openapis.org, www.whatwg.org, superiortech.io, notes.app, claude.app","capability hits: code_execution×10, agent_config_tamper×6, obfuscation×5, credential_harvest×4, network_egress×2, download_execute×2, reconnaissance×1, crypto_wallet×1, install_hook_shell×1","4 prompt-injection / hidden-text hints in docs","tarball sha1 d056e6eec1400ba19ab8463f5f1f85d5ba5efa02"],"entry_files":["build/index.js"],"large_or_binary":[]},"tarball":"https://registry.npmjs.org/apple-notes-mcp/-/apple-notes-mcp-2.6.12.tgz","source":"feed"}