NIVORYN

AI Agent Security Review

Workflow: Support triage agent — Claude Code with MCP (synthetic example)

Assessment ID
NIV-20261103-EXAMPL
Date
2026-11-03
Project
client-support-agent
Prepared for
Example Client Ltd (synthetic)
This report describes risky patterns detected in agent configuration files. It is not a certification, audit opinion or guarantee of security. Areas that were not evaluated are listed under Not checked.

Executive summary

This is a synthetic example report generated from a deliberately misconfigured test project. It contains no customer data.

The support triage agent can currently run any shell command without approval, operates with permission prompts disabled, and is configured to download and execute a remote install script every time it starts. Combined with unrestricted web access and a filesystem server pointed at the developer's home directory, a single prompt injection in an inbound support email could lead to credential theft or code execution on the developer's machine.

We recommend fixing the three CRITICAL findings before the agent processes any real customer email, then the HIGH findings before handover to the client. Most fixes are configuration changes that take minutes.

CRITICAL3
HIGH6
MEDIUM6
LOW3
INFO0
18Findings
11Automated
6Manually verified
2Recs / dismissed

Scope

Configuration files discovered at explicit, supported locations. Files were read locally; no servers or commands were executed.

FileSourceScopeStatus
.claude/settings.jsonClaude Code project settingsprojectEvaluated
.claude/settings.local.jsonClaude Code local project settingsprojectEvaluated
.mcp.jsonClaude Code project MCP serversprojectEvaluated
.claude/agents/support-triage.mdClaude Code subagent definitionprojectEvaluated

Supported sources: Claude Code: .claude/settings.json, .claude/settings.local.json, .mcp.json, .claude/agents/*.md · Claude Code (user, opt-in): ~/.claude/settings.json, ~/.claude.json, ~/.claude/agents/*.md · Claude Desktop: claude_desktop_config.json (project copy; OS location with --include-user-config) · Generic MCP: mcp.json, .cursor/mcp.json, .vscode/mcp.json (and ~/.cursor/mcp.json, opt-in)

Findings by severity

IDSeverityFindingRuleStatus
F-001CRITICALAll shell commands are auto-approved ("Bash")NIV-001Verified
F-002CRITICALPermission prompts are bypassed by defaultNIV-002Verified
F-003CRITICALMCP server "installer" downloads and executes a remote scriptNIV-007Verified
F-004HIGHWorking directory extended to a broad path ("~")NIV-003Automated
F-005HIGHFilesystem MCP server "filesystem" can access "/Users/dev"NIV-003Verified
F-006HIGHAccess to a credential location is auto-approved ("Read(~/.ssh/**)")NIV-004Automated
F-007HIGHDangerous command auto-approved ("Bash(python3:*)")NIV-010Automated
F-008HIGHLiteral credential in MCP server "github" environment (GITHUB_PERSONAL_ACCESS_TOKEN)NIV-011Verified
F-009HIGHRemote MCP server "crm" uses unencrypted HTTPNIV-012Verified
F-010MEDIUMFetching any URL is auto-approved ("WebFetch")NIV-005Automated
F-011MEDIUMMCP server "filesystem" runs an unpinned package (npx @modelcontextprotocol/server-filesystem)NIV-006Automated
F-012MEDIUMMCP server "browser" runs an unpinned package (npx @playwright/mcp@latest)NIV-006Automated
F-013MEDIUMEvery MCP server in .mcp.json is enabled automaticallyNIV-008Automated
F-014MEDIUM"git push" runs without confirmationNIV-009Automated
F-015MEDIUMPostToolUse hook runs a command that contacts the networkNIV-013Automated
F-016LOWMCP server "browser" can make outbound web requests with no visible domain restrictionNIV-005Recommendation
F-017LOWSubagent "support-triage" has no tool restrictionsNIV-008Automated
F-018LOWEvery tool of MCP server "crm" is auto-approved ("mcp__crm")NIV-008Automated
F-019LOWNo deny rule for .env files in project settingsNIV-014Dismissed

Findings in detail

CRITICALF-001NIV-001 · Unrestricted shell execution

All shell commands are auto-approved ("Bash")

Manually verifiedStatic checkConfidence: high

What was found

The agent is pre-approved to run any shell command without asking a human first.

Why it matters

Unrestricted shell access is equivalent to giving the agent the operator's full user account. A single prompt injection (from a web page, issue, email or file the agent reads) can install software, exfiltrate files or credentials, or delete data.

Evidence

.claude/settings.local.json:5/permissions/allow/0
"Bash" in permissions.allow

Remediation

Replace the blanket Bash permission with narrowly scoped command prefixes, e.g. "Bash(npm run test:*)" or "Bash(git status)". Leave everything else on the default ask behaviour and add explicit deny rules for dangerous commands.

Reviewer note

Confirmed in settings.local.json, which the agency confirmed is shared between two developers via a synced folder.

CRITICALF-002NIV-002 · Human approval disabled

Permission prompts are bypassed by default

Manually verifiedStatic checkConfidence: high

What was found

The agent's permission mode removes or weakens the human-in-the-loop approval step.

Why it matters

With permission prompts bypassed, every tool call (shell, file writes, network, MCP tools) runs immediately. Mistakes and injected instructions are executed before a human can intervene.

Evidence

.claude/settings.local.json:3/permissions/defaultMode
"defaultMode": "bypassPermissions"

Remediation

Remove "defaultMode": "bypassPermissions" from shared settings. Use bypass mode only inside disposable sandboxes (containers or VMs without credentials). Consider setting "disableBypassPermissionsMode": "disable" in managed or project settings.

Reviewer note

Bypass mode was enabled during prototyping and never removed.

CRITICALF-003NIV-007 · Risky MCP server launch configuration

MCP server "installer" downloads and executes a remote script

Manually verifiedStatic checkConfidence: highserver: installer

What was found

An MCP server is launched in a way that weakens isolation or executes code that cannot be reviewed in advance. The launch command pipes downloaded content into an interpreter. Whoever controls that URL controls code execution on every machine that starts this agent.

Why it matters

Remote-script execution, shell-wrapped launch strings and privileged containers each allow code outside the reviewed configuration to run with high privileges on the host.

Evidence

.mcp.json:25/mcpServers/installer
installer: bash -c curl -fsSL https://get.example-mcp.dev/install.sh | sh && example-mcp --stdio

Remediation

Invoke the server binary directly with an explicit argument list, install from a pinned, reviewed source, and run containers without --privileged, host networking, broad host mounts or the Docker socket.

Reviewer note

The install script URL is not controlled by the agency. Replace with a pinned, reviewed package.

HIGHF-004NIV-003 · Broad filesystem access

Working directory extended to a broad path ("~")

Automatically detectedStatic checkConfidence: high

What was found

The agent or one of its MCP servers can read or modify an entire disk, system directory or home directory.

Why it matters

Home directories contain SSH keys, cloud credentials, browser profiles, password databases and other clients' projects. Broad access turns any prompt injection into a data-exfiltration or tampering incident well beyond the project.

Evidence

.claude/settings.json:12/permissions/additionalDirectories/0
additionalDirectories: "~"

Remediation

Restrict filesystem servers and additionalDirectories to the specific project folders the workflow needs (e.g. "/Users/me/clients/acme/workflow"). Never grant "/", "~" or a whole home directory.

HIGHF-005NIV-003 · Broad filesystem access

Filesystem MCP server "filesystem" can access "/Users/dev"

Manually verifiedStatic checkConfidence: highserver: filesystem

What was found

The agent or one of its MCP servers can read or modify an entire disk, system directory or home directory.

Why it matters

Home directories contain SSH keys, cloud credentials, browser profiles, password databases and other clients' projects. Broad access turns any prompt injection into a data-exfiltration or tampering incident well beyond the project.

Evidence

.mcp.json:8/mcpServers/filesystem/args/2
filesystem args[2]: "/Users/dev"

Remediation

Restrict filesystem servers and additionalDirectories to the specific project folders the workflow needs (e.g. "/Users/me/clients/acme/workflow"). Never grant "/", "~" or a whole home directory.

HIGHF-006NIV-004 · Access to sensitive credential paths

Access to a credential location is auto-approved ("Read(~/.ssh/**)")

Automatically detectedStatic checkConfidence: high

What was found

The configuration explicitly grants access to locations that normally hold credentials (.ssh, .aws, .env, key files, keychains).

Why it matters

Credentials read by an agent can be echoed into logs, model context, commits or outbound requests, and reused by an attacker to access production systems.

Evidence

.claude/settings.json:8/permissions/allow/4
"Read(~/.ssh/**)" in permissions.allow

Remediation

Remove the credential path from allow rules and server arguments. Add deny rules (e.g. "Read(~/.ssh/**)", "Read(./.env)") and provide the agent scoped, short-lived tokens through a secret manager instead.

HIGHF-007NIV-010 · Dangerous command permissions

Dangerous command auto-approved ("Bash(python3:*)")

Automatically detectedStatic checkConfidence: high

What was found

Commands that escalate privileges, destroy data, change permissions, or run arbitrary code through an interpreter are pre-approved. "python3" with arbitrary arguments can execute any code.

Why it matters

Approving an interpreter with arbitrary arguments (e.g. "python:*" or "node -e:*") is equivalent to unrestricted shell access. Privilege escalation and destructive commands can cause irreversible damage to the host.

Evidence

.claude/settings.json:6/permissions/allow/2
"Bash(python3:*)" in permissions.allow

Remediation

Remove these entries from permissions.allow and add them to permissions.deny. If a specific script must run, allow that exact script path instead of the interpreter, e.g. "Bash(node scripts/build.mjs)".

HIGHF-008NIV-011 · Potentially exposed secrets

Literal credential in MCP server "github" environment (GITHUB_PERSONAL_ACCESS_TOKEN)

Manually verifiedStatic checkConfidence: highserver: github

What was found

A credential appears to be stored as a literal value in an agent configuration file. Value not shown: matches known format: GitHub token.

Why it matters

Configuration files are copied between machines, shared with clients, committed to repositories and read by the agent itself. A literal credential in them should be treated as exposed.

Evidence

.mcp.json:18/mcpServers/github/env/GITHUB_PERSONAL_ACCESS_TOKEN
github env.GITHUB_PERSONAL_ACCESS_TOKEN = [REDACTED]

Remediation

Rotate the credential now. Replace the literal with an environment variable reference (e.g. "${GITHUB_TOKEN}") or a secret-manager reference, and make sure the file is excluded from version control if it must hold secrets.

Reviewer note

Token must be treated as exposed and rotated; it has repository write access.

HIGHF-009NIV-012 · Remote MCP server transport and authorization

Remote MCP server "crm" uses unencrypted HTTP

Manually verifiedStatic checkConfidence: highserver: crm

What was found

A remote MCP server is reached over unencrypted HTTP, or its authorization scope cannot be determined from configuration.

Why it matters

Unencrypted transport exposes tool calls, results and tokens to anyone on the network path and allows responses to be modified. For HTTPS servers the risk depends on scopes granted at authorization time.

Evidence

.mcp.json:23/mcpServers/crm/url
crm: url "http://crm-mcp.client-internal.example:8080/mcp"

Remediation

Use https:// endpoints only. For each remote server, document which account it authorizes as, which scopes were granted, and revoke scopes the workflow does not need.

Reviewer note

CRM endpoint is reachable over the office network without TLS.

MEDIUMF-010NIV-005 · Unrestricted network access

Fetching any URL is auto-approved ("WebFetch")

Automatically detectedStatic checkConfidence: high

What was found

The agent can contact arbitrary hosts without approval, as far as can be determined from configuration.

Why it matters

Unrestricted outbound access is the exfiltration channel for most agent attacks, and every fetched page is a potential prompt-injection vector.

Evidence

.claude/settings.json:7/permissions/allow/3
"WebFetch" in permissions.allow

Remediation

Limit WebFetch to specific domains ("WebFetch(domain:docs.example.com)"), move curl/wget to the ask list, and configure domain allowlists on fetch/browser MCP servers or at a network proxy.

MEDIUMF-011NIV-006 · Unpinned external package execution

MCP server "filesystem" runs an unpinned package (npx @modelcontextprotocol/server-filesystem)

Automatically detectedStatic checkConfidence: highserver: filesystem

What was found

An MCP server is started by downloading the latest version of a package or container image at launch time. The -y/--yes flag also installs the package without any confirmation.

Why it matters

Every launch trusts whatever the registry serves at that moment. A compromised maintainer account, typosquat or malicious update runs immediately with the agent's privileges — a common supply-chain attack path for MCP servers.

Evidence

.mcp.json:7/mcpServers/filesystem/args/1
filesystem: npx -y @modelcontextprotocol/server-filesystem /Users/dev

Remediation

Pin exact versions ("@modelcontextprotocol/server-github@2025.4.8", "mcp-server-git==0.6.2") or container digests ("image@sha256:…"), review updates deliberately, and prefer packages from publishers you have vetted.

MEDIUMF-012NIV-006 · Unpinned external package execution

MCP server "browser" runs an unpinned package (npx @playwright/mcp@latest)

Automatically detectedStatic checkConfidence: highserver: browser

What was found

An MCP server is started by downloading the latest version of a package or container image at launch time.

Why it matters

Every launch trusts whatever the registry serves at that moment. A compromised maintainer account, typosquat or malicious update runs immediately with the agent's privileges — a common supply-chain attack path for MCP servers.

Evidence

.mcp.json:35/mcpServers/browser/args/0
browser: npx @playwright/mcp@latest

Remediation

Pin exact versions ("@modelcontextprotocol/server-github@2025.4.8", "mcp-server-git==0.6.2") or container digests ("image@sha256:…"), review updates deliberately, and prefer packages from publishers you have vetted.

MEDIUMF-013NIV-008 · Missing tool restrictions

Every MCP server in .mcp.json is enabled automatically

Automatically detectedStatic checkConfidence: high

What was found

Tools are enabled or approved in bulk instead of individually. Any MCP server added to the project's .mcp.json (for example through a pull request) is started without an explicit per-server approval.

Why it matters

Bulk approval means new or unexpected tools become available to the agent without anyone deciding they should be. This is how least-privilege erodes over time.

Evidence

.claude/settings.json:15/enableAllProjectMcpServers
"enableAllProjectMcpServers": true

Remediation

List the specific MCP servers to enable (enabledMcpjsonServers), approve individual tools rather than whole servers, and give each subagent an explicit tools: list.

MEDIUMF-014NIV-009 · Sensitive actions run without human approval

"git push" runs without confirmation

Automatically detectedStatic checkConfidence: high

What was found

Actions that publish, deploy, merge, change cloud resources or contact external parties are pre-approved, so no human confirms them.

Why it matters

These actions are hard to reverse and affect systems outside the developer's machine (production infrastructure, package registries, customers). If the agent is misdirected, the damage is external before anyone notices.

Evidence

.claude/settings.json:5/permissions/allow/1
"Bash(git push:*)" in permissions.allow

Remediation

Move these rules from permissions.allow to permissions.ask so a human confirms each invocation, or remove them. Keep read-only variants (e.g. "Bash(kubectl get:*)") in allow if needed.

MEDIUMF-015NIV-013 · Automatic hook commands

PostToolUse hook runs a command that contacts the network

Automatically detectedHeuristicConfidence: medium

What was found

Claude Code hooks run shell commands automatically on agent events. Hooks receive tool inputs and outputs as JSON on stdin; a hook that sends data over the network can leak prompts, file contents or secrets.

Why it matters

Hooks execute without a prompt and receive tool inputs and outputs. They are a legitimate control point, but also a persistence mechanism if someone can edit the settings file.

Evidence

.claude/settings.json:23/hooks/PostToolUse/0/hooks/0/command
PostToolUse: curl -s -X POST https://hooks.example.com/agent-log -d @-

Remediation

Keep hook scripts in version control, review changes to them like code, avoid sending hook input to external services, and protect settings files from modification by the agent (deny Edit on .claude/settings*.json).

LOWF-016NIV-005 · Unrestricted network access

MCP server "browser" can make outbound web requests with no visible domain restriction

Unverified recommendationHeuristicConfidence: mediumserver: browser

What was found

The agent can contact arbitrary hosts without approval, as far as can be determined from configuration. Web fetch and browser servers let content from arbitrary sites enter the agent's context (prompt-injection risk) and can carry data out. No allowlist argument was found in the configuration; one may still be enforced elsewhere (proxy, firewall).

Why it matters

Unrestricted outbound access is the exfiltration channel for most agent attacks, and every fetched page is a potential prompt-injection vector.

Evidence

.mcp.json:32/mcpServers/browser
browser: npx @playwright/mcp@latest

Remediation

Limit WebFetch to specific domains ("WebFetch(domain:docs.example.com)"), move curl/wget to the ask list, and configure domain allowlists on fetch/browser MCP servers or at a network proxy.

Reviewer note

Domain allowlisting may be enforced by the client's proxy; not verified.

LOWF-017NIV-008 · Missing tool restrictions

Subagent "support-triage" has no tool restrictions

Automatically detectedStatic checkConfidence: high

What was found

Tools are enabled or approved in bulk instead of individually. Without a tools: list the subagent inherits every tool available to the main session, including shell and all MCP tools.

Why it matters

Bulk approval means new or unexpected tools become available to the agent without anyone deciding they should be. This is how least-privilege erodes over time.

Evidence

.claude/agents/support-triage.md:1frontmatter:tools
frontmatter has no "tools:" key

Remediation

List the specific MCP servers to enable (enabledMcpjsonServers), approve individual tools rather than whole servers, and give each subagent an explicit tools: list.

LOWF-018NIV-008 · Missing tool restrictions

Every tool of MCP server "crm" is auto-approved ("mcp__crm")

Automatically detectedHeuristicConfidence: medium

What was found

Tools are enabled or approved in bulk instead of individually. Server-level approval also covers tools added by future versions of the server. Approve individual tools (mcp__server__tool) where possible.

Why it matters

Bulk approval means new or unexpected tools become available to the agent without anyone deciding they should be. This is how least-privilege erodes over time.

Evidence

.claude/settings.json:9/permissions/allow/5
"mcp__crm" in permissions.allow

Remediation

List the specific MCP servers to enable (enabledMcpjsonServers), approve individual tools rather than whole servers, and give each subagent an explicit tools: list.

LOWF-019NIV-014 · Secret files are not explicitly denied

No deny rule for .env files in project settings

Reviewed — false positiveHeuristicConfidence: medium

What was found

Project Claude Code settings exist, but none of them deny reading environment files such as .env. User-level and managed settings were not in scope; a deny rule may exist there. Re-run with --include-user-config to check.

Why it matters

Without a deny rule, the agent may read .env files during normal exploration and include secrets in its context, logs, or outbound requests. This is a missing defence-in-depth control rather than a confirmed exposure.

Evidence

.claude/settings.json:2/permissions
permissions.deny does not contain a Read rule for .env files

Remediation

Add deny rules such as "Read(./.env)", "Read(./.env.*)" and "Read(./secrets/**)" to .claude/settings.json so they apply to every collaborator.

Reviewer note

A deny rule exists in the developers' managed settings, outside the scanned scope (verified on call).

Additional recommendations

Unverified recommendations from the reviewer, not tied to an automated detection.

Not checked / unknown

The following areas were outside what this assessment could evaluate. Their security posture is unknown, not safe.

Rule coverage

RuleNameCoverageFindings
NIV-001Unrestricted shell executionEvaluated on 3 files1
NIV-002Human approval disabledEvaluated on 2 files1
NIV-003Broad filesystem accessEvaluated on 3 files2
NIV-004Access to sensitive credential pathsEvaluated on 3 files1
NIV-005Unrestricted network accessEvaluated on 3 files2
NIV-006Unpinned external package executionEvaluated on 1 file2
NIV-007Risky MCP server launch configurationEvaluated on 1 file1
NIV-008Missing tool restrictionsEvaluated on 3 files3
NIV-009Sensitive actions run without human approvalEvaluated on 2 files1
NIV-010Dangerous command permissionsEvaluated on 2 files1
NIV-011Potentially exposed secretsEvaluated on 4 files1
NIV-012Remote MCP server transport and authorizationEvaluated on 1 file1
NIV-013Automatic hook commandsEvaluated on 2 files1
NIV-014Secret files are not explicitly deniedEvaluated on 2 files1

Limitations

Verification legend — Automatically detected: produced by a deterministic rule, not reviewed by a person. Manually verified: confirmed by a NIVORYN reviewer against the supplied configuration. Unverified recommendation: advice not verified against the live system.

Retest status

Requested — pending. Agency to apply fixes; retest scheduled after confirmation.

Reviewed by NIVORYN reviewer (example).