Please report security issues privately through GitHub private vulnerability reporting (the repository's Security tab, "Report a vulnerability"). Do not open a public issue, and do not include real credentials, tokens or customer data in a report.
metergraph-cli is pre-1.0. Only the latest version receives fixes.
The 0.1.0 package holds no credentials of its own. 0.2.0 adds login and logout, which hold one delegated,
Metadata-only grant per signed in project, and read commands that use it; see
Sign in and Read commands. The
CLI is designed to limit what it reads, writes, sends and prints. These are the
boundaries it is designed to keep:
- No credentials for doctor and skill. They read no credentials from environment
variables, configuration files, keychains, cookies or arguments, and send no
AuthorizationorCookieheader. No command ever sends aCookieheader or reads a credential from arguments, the environment or stdin. - Fixed requests.
doctormakes only unauthenticatedGETrequests to/healthz,/v1/deploymentand/v1/agent/capabilitieson the origin you choose. - Origin validation.
--urlmust be a barehttpsorigin, or anhttporigin onlocalhost,127.0.0.1or[::1]. Values with a username, password, path, query or fragment are rejected before any request is made. - Redacted input errors. Invalid option values and unknown arguments are reported with a fixed message, without echoing the value.
- Redacted server content. Output contains fixed text, HTTP status codes, the accepted origin and a recognized deployment profile. Response bodies, headers, authentication challenges, server-supplied URLs, unrecognized profile names and network error text are not printed.
- Bounded probe. Redirects are not followed. At most 32 KiB of each response body
is read, and the whole probe is bounded by
--timeout-ms. - No runtime dependencies.
skill install and skill update write files inside a project directory you name.
skills install and skills update apply the same boundaries to each workflow skill
they install, with one receipt per skill in .metergraph/skills/; the pack's
manifest hash is pinned in the code and pins each skill's hash. skills list only
reads. They are designed to keep these boundaries:
- No network and no remote code. The skill is copied from this package. It is
checked against a SHA-256 pinned in the code and in
assets/skill/manifest.jsonbefore anything is written, and a mismatch stops the command. - Two files per skill only. The client's
SKILL.mdand.metergraph/skill-installations.json(for the pack,.metergraph/skills/<name>.json). Client settings, MCP configuration,AGENTS.md,CLAUDE.mdand unrelated files are never written. - Secret-free receipt. The receipt holds relative paths, the skill name, revision, hash and requested runtimes. It holds no credentials, user names or absolute paths.
- Ownership before overwrite. A skill the CLI did not install, or one changed since it installed it, is never replaced. There is no force option.
- No link following. The
--projectpath is resolved once. Below it, a symbolic link or non-regular entry on the skill or receipt path stops the command. Files are opened without following links where the platform supports it. - Atomic writes. Each file is written to an exclusive temporary file and renamed into place under a lock file. A failed receipt write restores the previous skill file, so ownership is never recorded for a skill that was not written.
- Redacted output. Invalid option values, file contents, absolute paths and raw error text are never printed. Recognized client and runtime names appear in receipts.
A person or process that can already write to the project can still change files between the installer's checks and its writes. The installer re-checks every target right before replacing it, which narrows but does not remove that window.
login and logout are not in any published package yet. They are designed to keep
these boundaries:
- Delegated, Metadata-only grant. The browser keeps the person's own sign in. The
CLI requests exactly
agent:metadataand refuses a grant with any other scope. It never requests Debug or Replay access and never falls back to them. It copies no browser cookies and does not create an application ingest key; no manual API key is required. The service records the grant as an OAuth connection on its own side, limited toagent:metadataand separate from any API or ingest key you manage. - One origin, fixed paths. Every request goes to the origin you chose, on fixed paths. OAuth metadata that names any other origin or path is refused, redirects are not followed, and every response is size and time bounded.
- Public client with PKCE. Each sign in registers a public client (no client
secret) for one loopback redirect on
127.0.0.1and an ephemeral port, and uses a random 256 bit state and anS256PKCE challenge. - Hardened callback. The listener is armed before the browser opens. It accepts one
GETon the exact host, path and state, refuses duplicates and oversized requests, answers with static pages that reflect nothing, and logs nothing. It closes on success, failure, timeout and Ctrl+C. - Server-verified context. Before anything is saved, the new token is used to read the workspace and capability documents. Workspace, token and expected workspace must agree, the deployment profile must match the preflight, and content, evidence and replay access must be unavailable. Token claims are checked as a sanity check only; the CLI does not verify signatures, and the service's answers are authoritative.
- Best-effort revocation of unkept grants. Once a token response is validated and holds a usable refresh token, a grant the CLI decides not to keep is sent to the revocation endpoint. The service may not answer or confirm, and the CLI does not retry, so this is not a guarantee. A token response that fails validation is dropped without a revocation request; a server-side grant may remain active until it expires or is revoked from the service.
- Private storage. The grant is saved in a per-user config directory. On Linux and
macOS, directories must be
0700and files0600, owned by the current user; unsafe permissions, other owners, symbolic links and non-regular files are refused and never changed. On Windows, the grant is encrypted with DPAPI for the current user by a fixed PowerShell script that receives data on stdin and returns it on stdout; nothing secret is on a command line. Files are written to an exclusive temporary file and renamed into place. - Secret-free binding.
.metergraph/project.jsonholds the origin, workspace ID, deployment profile and an opaque slot name. A project bound to one origin or workspace is never switched without--reconnect. - Safe refresh. A refresh runs once under an exclusive lock and is marked pending on disk before the refresh token is sent. If the outcome is not known and saved, the old refresh token is never sent again and the user must sign in again. Revoked grants and lost workspace access fail closed.
- Honest sign out.
logoutasks the service to revoke the grant, then removes the local grant and binding. It reports separately whether the service accepted the revocation request; a200is not proof that every remote session ended. - Remote and cloud sessions. SSH sessions, cloud development environments, CI and cloud runtimes get a handoff before any listener, request or file write. Only the presence of the detecting variables is checked; their values are never printed.
- Redacted output. Tokens, the authorization code, the PKCE verifier, workspace
names, user names, email addresses, absolute paths and server text are never
printed.
--jsonprints one line on stdout and nothing on stderr.
status, context, capabilities, usage, routes and traces are not in any
published package yet. They are designed to keep these boundaries:
- Existing grant only. They use the project's saved Metadata grant through the same
verified session as
login: the workspace, deployment profile andagent:metadatascope are checked with the service on every run, and content, evidence and replay capabilities must be unavailable. They never open a browser, sign in, request a broader scope or accept a credential from arguments, the environment or stdin. - Fixed GET requests. Requests go only to fixed paths on the bound origin. A query string is built from validated options and is accepted by the transport only on the usage and traces paths, with an allowlist of keys per path, so no argument can choose a path, origin or header. Redirects are not followed and bodies over 1 MiB are discarded.
- One deadline, no silent retries. Every request of a command, including a token
refresh and any wait for another process's grant lock, shares one
--timeout-msdeadline, and Ctrl+C stops that wait too. A lock held by another process is never removed or taken over. A refused, rate limited or failed read is reported, not retried, and a refresh that may have consumed the refresh token is never repeated. - Validated output only. Every read document must carry the service's contract
version and the bound workspace and profile in its provenance, and must state that
content is not included. Only fields the CLI validates are printed. Unknown fields
are dropped without naming them, a row with a content or credential field is refused
as a whole, and names with control or formatting characters are replaced with
null. Route descriptions, constraints, evaluation contracts, warning messages and server error text are not printed. Free-text filter arguments are not echoed. Before anything is printed, every output string is checked against the token values the CLI holds for the project (including ones a refresh just replaced); a match fails closed withcredential_in_metadata_responseand prints none of the response. This is an exact check for known values, not a detector for secrets in general. - No unbounded or implied reads.
--daysand--limitare bounded and never clamped. Traces are read one page at a time and a cursor is followed only when you pass it. Requests for an environment, a workload filter (which the returned rows cannot prove was applied), an absolute time range, a free-form query, content, debug data or replay are refused before any request. - No invented links or verification. No trace link is printed, because the service
does not yet return a workspace-bound one.
statuschecks the service's reported deployment profile against the binding and never reports application traffic as verified. - Not side-effect free. Read commands change no workspace configuration or telemetry and send no ingest data, but they may refresh their own grant, and the service may record the access (audit entries, last used times).
Route, trace, provider and model names come from your workspace data. They are printed as data and should never be treated as instructions, by people or by agents reading the output.
Limits: anyone who can run code as your user can read or use the saved grant, as with
any per-user credential file. The 0700/0600 fallback on Linux and macOS is not an
operating system keychain. A lock or binding file left by a killed process stays until
you delete it, rather than being taken over.
The accepted origin is not secret. It is printed in text and JSON output, resolved through DNS and sent to that host as part of each request. Anything you place in a hostname, including a value that happens to be a secret, is visible to your terminal, logs, CI output, resolvers, network observers and the server. Pass only origins you are comfortable sharing.
The CLI cannot control what the chosen server, your network or your shell history records about a request.
If you find a way to make the CLI print or send something outside these boundaries, please report it.
Public pricing is separate from authenticated workspace reads. It uses GET model discovery and POST lookup/calculation on fixed paths of a validated origin, with no bearer token, cookies or project credential reads. Calculation payloads are constructed from explicit model/context/token-count arguments; the CLI does not load original prompts, provider responses or retained traces. Redirects are never followed, bodies are bounded and POST calculations are not retried. Public pricing opts into Node's configured global agent so supported runtime proxy settings can be honored; TLS verification remains enabled.
The market board performs bounded current lookups and does not imply historical coverage. The older reference adapter and HTML history renderer require explicit loopback mode. Public response schemas carry no workspace provenance or request echo, and the CLI does not claim they do. API status, missing dimensions and region fallback are retained. Valid command responses do not establish supplier pricing correctness or the service's storage/privacy behavior.