Skip to content
Closed
Show file tree
Hide file tree
Changes from 49 commits
Commits
Show all changes
74 commits
Select commit Hold shift + click to select a range
b56e1ff
feat(cli): add MCP tool discovery
ericksoa Jul 15, 2026
c610f9a
fix(cli): harden MCP discovery runtime
ericksoa Jul 15, 2026
1b9327a
test(cli): keep timeout setup linear
ericksoa Jul 15, 2026
bf45617
chore(cli): license MCP runtime config
ericksoa Jul 15, 2026
3ab69a3
fix(ci): review Deep Agents CA build arg
ericksoa Jul 15, 2026
214a0cd
perf(sandbox): bundle MCP discovery runtime
ericksoa Jul 15, 2026
018ffc5
fix(ci): use TypeScript runtime builder
ericksoa Jul 15, 2026
28ae5b9
chore: merge current main
ericksoa Jul 15, 2026
3942a81
chore: merge current main
ericksoa Jul 15, 2026
232416d
chore: merge current main
ericksoa Jul 15, 2026
9961ffe
chore: merge current main
ericksoa Jul 15, 2026
8c8fa99
fix(mcp): install bundled discovery runtime in agent images
cv Jul 15, 2026
4ba3ec0
Merge branch 'main' into feat/mcp-status-tools-ericksoa
cv Jul 15, 2026
3fcf804
Merge branch 'main' into feat/mcp-status-tools-ericksoa
cv Jul 15, 2026
e2fabcb
test(e2e): keep MCP bridge suite within size budget
cv Jul 15, 2026
8016097
chore(ci): retry release validation after runner outage
cv Jul 15, 2026
962119f
Merge branch 'main' into feat/mcp-status-tools-ericksoa
cv Jul 15, 2026
d4a8986
fix(cli): accept maximum escaped MCP tool inventory
ericksoa Jul 15, 2026
abf5e4b
test(cli): enforce MCP discovery host output cap
ericksoa Jul 15, 2026
8c23100
Merge branch 'main' into feat/mcp-status-tools-ericksoa
cv Jul 15, 2026
959acc0
chore: refresh PR validation after runner failures
ericksoa Jul 15, 2026
ffb7ad4
fix(sandbox): retry transient supervisor discovery
prekshivyas Jul 15, 2026
67a6cfc
Merge branch 'main' into feat/mcp-status-tools-ericksoa
ericksoa Jul 16, 2026
a26e438
Merge branch 'main' into feat/mcp-status-tools-ericksoa
ericksoa Jul 16, 2026
10e2194
fix(e2e): publish dev compatibility risk evidence
ericksoa Jul 16, 2026
211956a
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 16, 2026
cd064bf
chore(ci): refresh exact-head validation
ericksoa Jul 16, 2026
562fd9b
fix(sandbox): retry transient Docker stop timeout
ericksoa Jul 16, 2026
51f2312
Merge current main into feat/mcp-status-tools-ericksoa-linear
ericksoa Jul 16, 2026
09cf314
chore(ci): retry protected validation
ericksoa Jul 16, 2026
5c446ad
chore(ci): refresh validation after runner outage
ericksoa Jul 16, 2026
0346c90
chore(ci): refresh protected gate state
ericksoa Jul 16, 2026
e8fbfd8
Merge main into feat/mcp-status-tools-ericksoa
ericksoa Jul 16, 2026
1a1b565
chore(ci): retry after hosted runner shutdown
ericksoa Jul 16, 2026
ba78f83
chore(ci): retry protected runner loss
ericksoa Jul 16, 2026
a7a3ee4
Merge branch 'main' into feat/mcp-status-tools-ericksoa
cv Jul 16, 2026
ca4e4fc
fix(sandbox): tolerate stable zombie process entries
ericksoa Jul 16, 2026
01882fd
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 16, 2026
e3f611b
Merge remote-tracking branch 'origin/feat/mcp-status-tools-ericksoa' …
ericksoa Jul 16, 2026
139c1ca
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 16, 2026
6aa1245
fix(mcp): prove bounded discovery cleanup
ericksoa Jul 16, 2026
493bc09
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 16, 2026
37b60c5
chore(mcp): extract unrelated recovery fixes
ericksoa Jul 16, 2026
da82306
fix(mcp): block authenticated tool discovery
ericksoa Jul 16, 2026
8743c54
merge: refresh PR #6904 from main
cv Jul 18, 2026
e1f81b8
test(security): expect isolated Python probes
cv Jul 18, 2026
fb23150
Merge origin/main into feat/mcp-status-tools-ericksoa
prekshivyas Jul 20, 2026
a452336
fix(mcp): enable managed credential discovery
ericksoa Jul 20, 2026
1a66a06
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 20, 2026
459f733
fix(mcp): forward discovery credential placeholder
ericksoa Jul 20, 2026
6774ff9
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 20, 2026
d35dfc9
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 20, 2026
f4653ba
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 20, 2026
63d763e
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 20, 2026
202158a
Merge origin/main into feat/mcp-status-tools-ericksoa
ericksoa Jul 24, 2026
d3d4921
Merge origin/main into feat/mcp-status-tools-ericksoa
ericksoa Jul 24, 2026
3310a78
Merge origin/main into feat/mcp-status-tools-ericksoa
ericksoa Jul 24, 2026
3e1f8dd
test(mcp): assert initialized notification ordering
ericksoa Jul 24, 2026
3a82c5f
Merge origin/main into feat/mcp-status-tools-ericksoa
ericksoa Jul 24, 2026
93bafbc
Merge origin/main into feat/mcp-status-tools-ericksoa
ericksoa Jul 24, 2026
dcbd77e
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 24, 2026
b954f3d
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 24, 2026
dcb9361
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 24, 2026
49d03ec
Merge remote-tracking branch 'origin/main' into feat/mcp-status-tools…
ericksoa Jul 24, 2026
bc5bde3
chore: merge main into feat/mcp-status-tools-ericksoa
ericksoa Jul 24, 2026
c52bd73
chore: sync main into feat/mcp-status-tools-ericksoa
ericksoa Jul 24, 2026
5271ff5
fix(e2e): scope MCP risk evidence to selected agent
ericksoa Jul 24, 2026
1d11b7c
fix(e2e): fail closed on empty selectors
ericksoa Jul 24, 2026
f87ac71
chore: sync main into feat/mcp-status-tools-ericksoa
ericksoa Jul 25, 2026
1b22a57
fix(mcp): align discovery credential names
prekshivyas Jul 25, 2026
d8ea515
Merge branch 'main' into feat/mcp-status-tools-ericksoa
ericksoa Jul 25, 2026
3f798e8
Merge branch 'main' into feat/mcp-status-tools-ericksoa
apurvvkumaria Jul 25, 2026
56e6f8d
test(e2e): update reporter lifecycle fixtures
jyaunches Jul 25, 2026
b7fd458
merge(main): refresh PR 6904 base
jyaunches Jul 25, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 24 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
# Global ARG — must be declared before the first FROM to be visible
# to all FROM directives. Can be overridden via --build-arg.
ARG BASE_IMAGE=ghcr.io/nvidia/nemoclaw/sandbox-base:latest
ARG NEMOCLAW_CORPORATE_CA_B64=

# Stage 1: Build TypeScript plugin from source
FROM node:22-trixie-slim@sha256:2d9f5c76c8f4dd36e8f253bee5d828a83a6c09f36188f0b0414325232e0b175d AS builder
Expand Down Expand Up @@ -38,10 +39,32 @@ COPY src/lib/messaging/channels/ /opt/nemoclaw-root/src/lib/messaging/channels/
RUN ln -s /opt/nemoclaw/node_modules /opt/nemoclaw-root/node_modules \
&& /opt/nemoclaw/node_modules/.bin/tsc -p tsconfig.runtime-preloads.json

# Build the agent-neutral, names-only MCP diagnostic once from a committed
# production lock. The final image copies only the bundled runtime, not its
# build-time dependency tree.
FROM node:22-trixie-slim@sha256:2d9f5c76c8f4dd36e8f253bee5d828a83a6c09f36188f0b0414325232e0b175d AS mcp-tool-discovery-runtime
ARG NEMOCLAW_CORPORATE_CA_B64
ENV AWS_EC2_METADATA_DISABLED=true \
NPM_CONFIG_AUDIT=false \
NPM_CONFIG_FUND=false \
NPM_CONFIG_UPDATE_NOTIFIER=false
WORKDIR /opt/mcp-tool-discovery-runtime
COPY tools/mcp-tool-discovery-runtime/package.json tools/mcp-tool-discovery-runtime/package-lock.json tools/mcp-tool-discovery-runtime/tsconfig.json tools/mcp-tool-discovery-runtime/install-reviewed-runtime.sh tools/mcp-tool-discovery-runtime/*.ts ./
RUN ./install-reviewed-runtime.sh \
&& rm -f ./install-reviewed-runtime.sh

# Stage 3: Runtime image — pull cached base from GHCR
# hadolint ignore=DL3006
FROM ${BASE_IMAGE}
ARG BASE_IMAGE
# OpenShell blocks the link-local EC2 Instance Metadata Service. Keep AWS SDK
# credential chains from attempting an impossible metadata discovery path.
ENV AWS_EC2_METADATA_DISABLED=true
COPY --from=mcp-tool-discovery-runtime /opt/mcp-tool-discovery-runtime/dist/ /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime/
RUN discovery_contract="$(node /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime/mcp-tool-discovery.mjs)" \
&& node -e 'const result = JSON.parse(process.argv[1]); if (result.protocol !== 1 || result.ok !== false || result.detail !== "tool discovery received invalid runtime arguments") process.exit(1);' "$discovery_contract" \
&& discovery_unsafe="$(find -L /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime \( ! -user root -o -perm /022 \) -print -quit)" \
&& test -z "$discovery_unsafe"
# Dependency review evidence for this runtime pin lives in
# docs/security/openclaw-2026.6.10-dependency-review.md.
ARG OPENCLAW_VERSION=2026.6.10
Expand Down Expand Up @@ -71,10 +94,6 @@ COPY agents/openclaw/wechat-runtime/package.json /usr/local/lib/nemoclaw/wechat-
COPY agents/openclaw/wechat-runtime/package-lock.json /usr/local/lib/nemoclaw/wechat-runtime/package-lock.json
COPY scripts/lib/reviewed-npm-archive.mts /scripts/lib/reviewed-npm-archive.mts

# OpenShell blocks the link-local EC2 Instance Metadata Service. Keep AWS SDK
# credential chains from attempting an impossible metadata discovery path.
ENV AWS_EC2_METADATA_DISABLED=true

# OpenClaw 2026.6.10 loads some generated source through jiti. Disable its
# filesystem transform cache so source fragments that mention provider marker
# names do not persist under /tmp/jiti inside the sandbox.
Expand All @@ -85,7 +104,7 @@ ENV JITI_FS_CACHE=false
# here; the RUN below decodes it to a root-owned file that the entrypoint
# appends to the OpenShell trust bundle at runtime. The CA is a public
# certificate, not a secret, so baking it into an image layer is acceptable.
ARG NEMOCLAW_CORPORATE_CA_B64=
ARG NEMOCLAW_CORPORATE_CA_B64

# Decode the host corporate-proxy CA (#6210) to a root-owned, read-only file
# when onboard baked one in. No-op when NEMOCLAW_CORPORATE_CA_B64 is empty. The
Expand Down
21 changes: 20 additions & 1 deletion agents/hermes/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,29 @@
# pre-built Hermes base image. Mirrors the OpenClaw Dockerfile structure.

ARG BASE_IMAGE=ghcr.io/nvidia/nemoclaw/hermes-sandbox-base@sha256:fa05221f5c7bcafea7e263c84e5d06f87e37d1ccb78dc28c113f1a4066aa544c
ARG NEMOCLAW_CORPORATE_CA_B64=

FROM node:22-trixie-slim@sha256:2d9f5c76c8f4dd36e8f253bee5d828a83a6c09f36188f0b0414325232e0b175d AS mcp-tool-discovery-runtime
ARG NEMOCLAW_CORPORATE_CA_B64
ENV NPM_CONFIG_AUDIT=false \
NPM_CONFIG_FUND=false \
NPM_CONFIG_UPDATE_NOTIFIER=false
WORKDIR /opt/mcp-tool-discovery-runtime
COPY tools/mcp-tool-discovery-runtime/package.json tools/mcp-tool-discovery-runtime/package-lock.json tools/mcp-tool-discovery-runtime/tsconfig.json tools/mcp-tool-discovery-runtime/install-reviewed-runtime.sh tools/mcp-tool-discovery-runtime/*.ts ./
RUN ./install-reviewed-runtime.sh \
&& rm -f ./install-reviewed-runtime.sh
RUN chown -R root:root /opt/mcp-tool-discovery-runtime \
&& chmod -R a=rX /opt/mcp-tool-discovery-runtime

# hadolint ignore=DL3006
FROM ${BASE_IMAGE}

COPY --from=mcp-tool-discovery-runtime /opt/mcp-tool-discovery-runtime/dist/ /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime/
RUN discovery_contract="$(node /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime/mcp-tool-discovery.mjs)" \
&& node -e 'const result = JSON.parse(process.argv[1]); if (result.protocol !== 1 || result.ok !== false || result.detail !== "tool discovery received invalid runtime arguments") process.exit(1);' "$discovery_contract" \
&& discovery_unsafe="$(find -L /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime \( ! -user root -o -perm /022 \) -print -quit)" \
&& test -z "$discovery_unsafe"

# Keep the final image contract explicit even when the published base image
# changes independently of this Dockerfile.
RUN set -eu; \
Expand Down Expand Up @@ -286,7 +305,7 @@ ARG NEMOCLAW_DARWIN_VM_COMPAT=0
# here; the RUN below decodes it to a root-owned file that the entrypoint
# appends to the OpenShell trust bundle at runtime. The CA is a public
# certificate, not a secret, so baking it into an image layer is acceptable.
ARG NEMOCLAW_CORPORATE_CA_B64=
ARG NEMOCLAW_CORPORATE_CA_B64
# Total model context window (input + output tokens). Empty by default so
# Hermes auto-detects from the endpoint's /v1/models max_model_len; onboard
# rewrites this ARG (via dockerfile-patch) when it probes a runtime value or
Expand Down
19 changes: 19 additions & 0 deletions agents/langchain-deepagents-code/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,29 @@
# NemoClaw staging supplies a resolved base image reference. Direct Docker builds
# must pass --build-arg BASE_IMAGE=... rather than falling back to a mutable tag.
ARG BASE_IMAGE
ARG NEMOCLAW_CORPORATE_CA_B64=

FROM node:22-trixie-slim@sha256:2d9f5c76c8f4dd36e8f253bee5d828a83a6c09f36188f0b0414325232e0b175d AS mcp-tool-discovery-runtime
ARG NEMOCLAW_CORPORATE_CA_B64
ENV NPM_CONFIG_AUDIT=false \
NPM_CONFIG_FUND=false \
NPM_CONFIG_UPDATE_NOTIFIER=false
WORKDIR /opt/mcp-tool-discovery-runtime
COPY tools/mcp-tool-discovery-runtime/package.json tools/mcp-tool-discovery-runtime/package-lock.json tools/mcp-tool-discovery-runtime/tsconfig.json tools/mcp-tool-discovery-runtime/install-reviewed-runtime.sh tools/mcp-tool-discovery-runtime/*.ts ./
RUN ./install-reviewed-runtime.sh \
&& rm -f ./install-reviewed-runtime.sh
RUN chown -R root:root /opt/mcp-tool-discovery-runtime \
&& chmod -R a=rX /opt/mcp-tool-discovery-runtime

# hadolint ignore=DL3006
FROM ${BASE_IMAGE}

COPY --from=mcp-tool-discovery-runtime /opt/mcp-tool-discovery-runtime/dist/ /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime/
RUN discovery_contract="$(node /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime/mcp-tool-discovery.mjs)" \
&& node -e 'const result = JSON.parse(process.argv[1]); if (result.protocol !== 1 || result.ok !== false || result.detail !== "tool discovery received invalid runtime arguments") process.exit(1);' "$discovery_contract" \
&& discovery_unsafe="$(find -L /usr/local/lib/nemoclaw/mcp-tool-discovery-runtime \( ! -user root -o -perm /022 \) -print -quit)" \
&& test -z "$discovery_unsafe"

USER root

RUN set -eu; \
Expand Down
54 changes: 51 additions & 3 deletions docs/manage-sandboxes/manage-mcp-servers.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
# SPDX-License-Identifier: Apache-2.0
title: "Manage MCP Servers"
sidebar-title: "Manage MCP Servers"
description: "Inspect, probe, rotate, restart, remove, rebuild, and destroy NemoClaw-managed MCP servers."
description-agent: "Explains managed MCP status and credential-resolution probes, credential rotation, restart, removal, rebuild restoration, destroy recovery, and lifecycle locking. Use after an MCP server is registered."
keywords: ["nemoclaw mcp status", "nemoclaw mcp restart", "nemoclaw mcp remove", "mcp credential rotation"]
description: "Inspect advertised tools, probe, rotate, restart, remove, rebuild, and destroy NemoClaw-managed MCP servers."
description-agent: "Explains managed MCP status, advertised tool discovery, credential-resolution probes, credential rotation, restart, removal, rebuild restoration, destroy recovery, and lifecycle locking. Use after an MCP server is registered."
keywords: ["nemoclaw mcp status", "mcp tool discovery", "nemoclaw mcp restart", "nemoclaw mcp remove", "mcp credential rotation"]
content:
type: "how_to"
skill:
Expand All @@ -29,6 +29,54 @@ The `env.missing` field lists recorded host variable names that are currently un
An existing valid provider can remain ready when a host variable is unset because OpenShell retains the credential.
The JSON value `support.mode: "bridge"` identifies the agent's config-adapter capability, not a host-side traffic bridge.

## Discover Advertised Tools

Pass `--tools` with one server name to request the server's advertised tool names:

```bash
$$nemoclaw my-sandbox mcp status github --tools
$$nemoclaw my-sandbox mcp status github --tools --json
```

The shared discovery runtime uses the managed registration's existing OpenShell credential provider and generated policy.
OpenShell injects the credential at the policy boundary; it is not passed to the runtime through arguments, environment values, or an authorization option.
The same runtime and thin adapter ancestry are used across OpenClaw, Hermes, and LangChain Deep Agents Code sandboxes.

Run discovery only against a configured endpoint you trust to advertise names while authenticated.
The endpoint controls every returned tool name and can derive those names from the request or credential it receives; NemoClaw validates and bounds the returned text but cannot prove that an authenticated endpoint did not encode credential-derived data in an otherwise valid name.

A discovery result is a point-in-time list from the configured MCP server, not an attestation of the exact tools visible to the model in an active agent session.
Agent configuration, progressive disclosure, runtime filters, and session state can further limit model-visible tools.

NemoClaw runs the standard MCP `initialize`, `notifications/initialized`, and paginated `tools/list` lifecycle.
It retains and returns tool names only, never prints the other tool-definition fields returned by `tools/list`, and never calls a tool.
The client bounds total time, per-request time, cumulative response bytes, pages, tool count, cursor length, and tool-name length.
It attempts to close the MCP session and transport on both success and failure.
Cleanup errors do not replace the bounded discovery result.

JSON output adds a per-server `toolDiscovery` object without changing the existing status fields:

```json
{
"toolDiscovery": {
"ok": true,
"count": 2,
"tools": ["createJiraIssue", "getJiraIssue"],
"truncated": false
}
}
```

Discovery is opt-in and sends authenticated network traffic to the configured endpoint.
`--tools` requires one server name and suppresses the named-server credential-resolution probe that would otherwise run by default.
Pass `--probe --tools` when you intentionally want both live checks.

An older sandbox image that does not contain the shared discovery client reports that a rebuild is required.
Run `$$nemoclaw my-sandbox rebuild` and retry the command.

A discovery failure sets `toolDiscovery.ok` to `false` and leaves the ordinary provider, policy, environment, and adapter status available.
Bounded partial results set `truncated` to `true` and include a redacted `detail` value.

## Verify Credential Resolution

Provider presence and metadata cannot prove that OpenShell rewrites `openshell:resolve:env:KEY` when a request leaves the sandbox.
Expand Down
22 changes: 21 additions & 1 deletion docs/reference/commands.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2042,15 +2042,35 @@ Identical HTTP 400, 401, or 403 rejections raise a warning that names the hypoth
For HTTP 401 or 403, a confirmed-valid credential means the host is not rewriting placeholders and agent runtimes receive the same auth failure and skip the server; HTTP 400 remains inconclusive because the endpoint may reject the probe request itself.
Every other outcome — differing rejections (an endpoint may reject two different literal bearers differently), endpoints that skip authentication, endpoint outages, policy denials, and unreachable sandboxes — reports as `unknown` rather than blaming the credential rewrite, and a persisted URL that fails the current authenticated-endpoint boundary is never probed.

Pass `--tools` with one server name to request a live tool inventory.
The shared client runs through the managed registration's existing OpenShell credential provider and policy; OpenShell injects the credential at that boundary, and the runtime never accepts it as an argument, environment value, or authorization option.
It performs `initialize`, `notifications/initialized`, and paginated `tools/list`, then attempts to close the MCP session and transport.
Cleanup errors do not replace the bounded discovery result.
It retains and returns deterministic tool names only, never prints the other tool-definition fields returned by `tools/list`, and never calls a tool.
The operation is bounded by total and per-request timeouts plus response-byte, page, tool-count, cursor-length, and tool-name limits.

Use `--tools` only with a configured endpoint you trust to advertise names while authenticated.
The endpoint controls its returned names and can derive them from the request or credential it receives; NemoClaw validates and bounds the text but cannot prove that the endpoint did not encode credential-derived data in an otherwise valid name.

The `toolDiscovery` JSON field contains `ok`, `count`, `tools`, and `truncated`, plus a redacted `detail` on failure or a bounded partial result.
These names are the server's point-in-time advertised tools, not an attestation of the exact tools visible to the model after agent filters, progressive disclosure, or session state.
An older sandbox image without the shared client reports that the sandbox must be rebuilt.

Tool discovery is opt-in and sends authenticated network traffic to the configured endpoint.
Passing `--tools` suppresses the named-server credential-resolution probe that otherwise runs by default.
Pass `--probe --tools` to request both checks explicitly.
An unsuccessful discovery does not remove the ordinary provider, policy, environment, or adapter status from the result.

```bash
$$nemoclaw my-assistant mcp status [server] [--json] [--probe|--no-probe]
$$nemoclaw my-assistant mcp status [server] [--json] [--probe|--no-probe] [--tools]
```

| Flag | Description |
|------|-------------|
| `--json` | Emit status as JSON without credential values |
| `--probe` | Request the wire-level credential-resolution probe for every listed server; entries that fail readiness checks are skipped |
| `--no-probe` | Skip the probe; it defaults on only when a single server is named |
| `--tools` | Request advertised tool names from one trusted configured endpoint through its managed credential provider; suppresses the implicit credential probe unless `--probe` is also passed |

### `$$nemoclaw <name> mcp restart`

Expand Down
7 changes: 4 additions & 3 deletions scripts/check-dcode-profile-import-gate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,16 @@ cd "${repo_root}"
# agents/langchain-deepagents-code/Dockerfile.base,
# test/Dockerfile.dcode-profile-missing-dependencies, and
# agents/langchain-deepagents-code/Dockerfile. Those three reviewed Dockerfiles
# contain no secret-bearing ARGs. Only BASE_IMAGE is passed via --build-arg,
# always as a public, non-secret image reference.
# contain no secret-bearing ARGs. NEMOCLAW_CORPORATE_CA_B64 carries public trust
# anchors and is not passed to this gate. Only BASE_IMAGE is passed via
# --build-arg, always as a public, non-secret image reference.
for dockerfile in \
agents/langchain-deepagents-code/Dockerfile.base \
test/Dockerfile.dcode-profile-missing-dependencies \
agents/langchain-deepagents-code/Dockerfile; do
while IFS= read -r arg_name; do
case "${arg_name}" in
BASE_IMAGE | NEMOCLAW_MODEL | NEMOCLAW_PROVIDER_KEY | NEMOCLAW_UPSTREAM_PROVIDER | NEMOCLAW_UPSTREAM_ENDPOINT_URL | NEMOCLAW_INFERENCE_BASE_URL | NEMOCLAW_INFERENCE_API | NEMOCLAW_TOOL_DISCLOSURE | NEMOCLAW_DCODE_AUTO_APPROVAL | NEMOCLAW_BUILD_ID | NEMOCLAW_DARWIN_VM_COMPAT | NEMOCLAW_PROXY_HOST | NEMOCLAW_PROXY_PORT) ;;
BASE_IMAGE | NEMOCLAW_CORPORATE_CA_B64 | NEMOCLAW_MODEL | NEMOCLAW_PROVIDER_KEY | NEMOCLAW_UPSTREAM_PROVIDER | NEMOCLAW_UPSTREAM_ENDPOINT_URL | NEMOCLAW_INFERENCE_BASE_URL | NEMOCLAW_INFERENCE_API | NEMOCLAW_TOOL_DISCLOSURE | NEMOCLAW_DCODE_AUTO_APPROVAL | NEMOCLAW_BUILD_ID | NEMOCLAW_DARWIN_VM_COMPAT | NEMOCLAW_PROXY_HOST | NEMOCLAW_PROXY_PORT) ;;
*)
echo "ERROR: plain-progress build refuses unreviewed ARG ${arg_name} in ${dockerfile}" >&2
exit 1
Expand Down
8 changes: 8 additions & 0 deletions src/lib/actions/sandbox/mcp-bridge-contracts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,14 @@ export interface McpBridgeStatus {
registered: boolean | null;
detail?: string;
};
/** Names advertised by the MCP endpoint when live discovery is requested. */
toolDiscovery?: {
ok: boolean;
count: number;
tools: string[];
truncated: boolean;
detail?: string;
};
addState?: "prepared" | "preflighted";
addedAt?: string;
updatedAt?: string;
Expand Down
12 changes: 12 additions & 0 deletions src/lib/actions/sandbox/mcp-bridge-render.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,18 @@ export function renderMcpBridgeStatus(
}`,
);
}
const discovery = status.toolDiscovery;
if (discovery) {
console.log(
` tool discovery: ${
discovery.ok ? "successful" : `FAILED${discovery.detail ? ` (${discovery.detail})` : ""}`
}`,
);
console.log(
` tools discovered: ${discovery.count}${discovery.truncated ? " (partial)" : ""}`,
);
for (const tool of discovery.tools) console.log(` - ${tool}`);
}
for (const warning of status.warnings) console.log(` warning: ${warning}`);
}
console.log("");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ describe("MCP credential-resolution probe command security", () => {
buildCredentialResolutionProbeCommand(baseEntry, "deepagents-config")?.command ?? "";

expect(mcporter).toContain("nemoclaw-start node -e");
expect(hermes).toContain("/opt/hermes/.venv/bin/python -c");
expect(deepagents).toContain("/opt/venv/bin/python3 -c");
expect(hermes).toContain("/opt/hermes/.venv/bin/python -I -c");
expect(deepagents).toContain("/opt/venv/bin/python3 -I -c");
for (const command of [mcporter, hermes, deepagents]) {
expect(command).toContain("'/dev/null'");
expect(command).not.toContain("head -c");
Expand Down
Loading
Loading