Scan your whole stack
From OX Research Newsroom
Are you using @hcmai/cli?
Find out what’s in your code.
Scan your apps free in minutes (opens in a new tab)Latest version: v0.37.9
@hcmai/cli was last scanned on 29 Nov 2026 at version 0.37.9. Risk score 0 of 100. High-severity rules fired.
| Version | Published | Status |
|---|---|---|
| 0.37.9 LATEST | 29 Nov 2026 | 1 rule fired |
| 0.37.8 | 28 Nov 2026 | 1 rule fired |
| 0.37.7 | 28 Nov 2026 | 1 rule fired |
| 0.37.6 | 28 Nov 2026 | Not shown |
| 0.37.5 | 28 Nov 2026 | Not shown |
Findings for v0.37.9. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.
Several behaviors that are each common on their own, such as reading registry credentials, contacting a variable host or running shell commands, appear together in this package in a combination associated with attacks. The finding message lists the behaviors that were combined.
HIGHThe score describes 0.37.9; other versions have their own rules, not their own score.
The publisher’s own README, as collected from the registry.
@hcmai/cliThe official HCM Next command-line interface for business APIs, tenant delivery, workspaces, and AI agents.
npm install --global @hcmai/cli
hcm --version
Node.js 22 or newer is required.
hcm env add production --endpoint https://hcm.example.com
hcm login https://hcm.example.com --code <one-time-pairing-code>
hcm env current
hcm identity show <identity-alias> --output json
The npm package is public. Application credentials are not included in the
package and are stored locally through the HCM login flow.
identity show uses that alias's stored token to return the live userId, username,
tenantId, and roles without printing the token.
Source, merge requests, CI, and version tags are maintained in GitLab. Public npm installation does not require GitLab access. The team GitLab NPM registry receives the same release tarballs.
hcm action 支持 --params '<JSON>' 或 --params-file <path>;
hcm create/update 对应使用 --data 或 --data-file。两种来源互斥,顶层必须是 JSON 对象。
密钥这类不该出现在命令行、文件和输出里的字段,用 --field-from-env <字段>=<环境变量名> 从环境变量取(可重复),
JSON 里不写这个字段:
hcm create TenantLLMConfigModel --env <环境> \
--data '{"provider":"dashscope","modelType":"qwen","tier":"FAST", ...}' \
--field-from-env apiKey=HCM_DASHSCOPE_API_KEY
CLI 只按名字读值、不打印值:服务端回包和报错先按结构遮掉这个值再输出,stdout / stderr 里原样或 JSON 转义后出现的再兜一层。
变量没设或为空时不发请求,只报名字;有只差一个字母的变量名时列出来,拿不准是不是同一把密钥就停下问,不要换着试。
只给 --field-from-env 时 --data 可省(显式给了空的 --data '' 仍报必填)。局限:短于 8 个字符的值只按整段相等遮;值仍在你的环境里,CLI 管不到你自己看环境。
不要为了确认值去 printenv / env / echo,也不要把值写进文件或命令。
只有确认动作无参数时,才省略 --params/--params-file 或使用 --params '{}'。
合法的 {} 与空文件不同:空文件、纯空白和截断 JSON 都会报 INVALID_JSON,不会补成 {}。
CLI 只读取调用方指定的文件,不自建参数临时文件。并发调用时,每个任务须使用独立文件, 并等待文件写入完成、关闭后再调用 CLI;不要让多个任务共用一个仍在写入的路径。 文件解析失败时,诊断会显示实际读取的绝对路径、字节数和下一步,不输出 JSON 原文。 此错误发生在鉴权和业务请求之前,不代表服务端 Action 已执行或失败;CLI 不会自动重读文件、 重试或重发写动作。先修正参数文件,再明确决定是否执行一次调用。
hcm package pack ./my-package/v1.0.0 --out ./my-package.hcmpkg
hcm package install ./my-package.hcmpkg --env sandbox --output json
hcm package status <runId> --env sandbox --output json
安装包 = extensions: 扩展资产 + models: 数据。hcm datapackage 为同义,旧名。
离线打包校验路径、文本类型、UTF-8、4MB 单文件与 32MB 扩展总量;只从制品副本剥离
metas 的 fields[].definitionId。数据 UUID 仅允许本包显式行 id 或 opaque_uuid_fields
声明的非引用字段;扩展 UUID 一律拒绝,轻应用按编码取数。
安装等锁事实写 stderr;本机等待超时退出 3,JSON 保留 timedOut: true,服务端继续执行。
客户私有化模型出问题时,用后端实际调用路径探测能力与故障归属;会调用模型并计入租户预算。
hcm llm probe --output table
hcm llm probe --config <id> --items tool.single,tool.result_roundtrip --budget-ms 90000 --repeats 3 --output json
hcm llm probe --config <id> --no-control-leg --deep
不给 --config 时,按 purpose=LLM AND isDefault=true 查询,必须恰好一行;否则列出候选
id / modelName 与选择命令。仅发送显式给出的参数,缺省预算、重复次数和对照腿由 Core 决定
(默认预算 90000ms、对照腿开启)。--deep 加测上下文声明窗口的 80%。
表格一项一行,显示「找谁」与对照腿,末尾显示 summary 全部计数、evaluated/expected 和 ownersOfFailures;
JSON 输出 ActionResponse.data 中的探针结果,保留原字段与顺序(含 summary.digest),提示走 stderr。
PASS / FAIL / INCOMPLETE 分别退出 0 / 1 / 3;未知 verdict 报原值并退出 1。
老 Core 没有 Action 时返回 LLM_PROBE_UNAVAILABLE、退出 3,按提示升级 Core。
hcm workspace pull downloads workspace files and records a local snapshot. It
does not reset the server's baseline against active. A mini app's target contains existing files error protects local files: keep the original directory and pull
into a new empty directory, or use --force only after confirming those local
files may be overwritten.
For a confirmed workspace/active revision conflict:
hcm workspace rebase --workspace <key> --dry-run --output json
hcm workspace rebase --workspace <key> --dry-run --plan /tmp/rebase-plan.json
# Edit reason and each path's resolution before applying.
hcm workspace rebase --workspace <key> --plan /tmp/rebase-plan.json --output json
Keep the same --env / --as; --dir can supply the local workspace binding.
Without --plan, rebase only previews. --dry-run --plan creates a new draft and
never overwrites an existing plan or submits a remote write. Base content is
unavailable (baseContentAvailable: false); the preview includes hashes and the
active/workspace contents for manual comparison.
Fill a nonempty reason, remove paths you will handle later, and replace every
remaining UNRESOLVED with TAKE_ACTIVE, KEEP_WORKSPACE, MERGED, or DELETE.
Only MERGED submits content, which must be a string (an empty string is valid).
The server rejects a stale planDigest; preview again and review a new plan.
Check resolvedPaths, baselineHash, and remainingConflicts in the receipt.
Rebase does not rewrite local files or release/deploy. Do not delete and recreate
files or the whole workspace to refresh the baseline.
A project env.yaml can declare default and named environments, each with
endpoint, frontend, tenant, optional roles, and danger. Legacy three-line
files remain supported. --env first matches a project name, then a local slot.
Connection provenance is printed to stderr (skipped when --output json|yaml or
--raw is given explicitly; check the target with hcm env current); writes to danger: true environments
require --allow-danger. Credentials stay in the local identity store.
hcm chiron init scaffolds a consultant project: env.yaml, the working
directories, and the managed block in AGENTS.md / CLAUDE.md. Skills come from
hcm chiron skills sync (targets: codex, claude); the repo-local codex target
maintains the skill index in AGENTS.md and mirrors it to an existing CLAUDE.md,
so a dual-agent project shares one locked skill tree. Since 0.14.0 the codex
target splits that tree by ownership: hcm-skills/sync/ is mirrored from the
product (the CLI owns it outright, lockfile included) and hcm-skills/local/
holds the consultant's own skills, which the CLI never writes. Same id on both
sides: local/ shadows sync/. The claude target stays flat
(.claude/skills/) because Claude Code only discovers one level deep.
A skill-resource HTTP 404 reports the requested path (including deployment
prefixes) and the server trace ID when available. Check hcm skills list and
whether the serving instances have the same catalog and resources; a missing
reference does not mean the whole skill is absent. The command still fails and
does not automatically retry.
Page acceptance is hcm chiron page. It mints the same short-lived
hcm open ticket, drives a headless Chromium through Playwright (the
chromium_headless_shell-* build in your Playwright cache — the one Playwright
MCP installs — works inside sandboxes such as Claude Code's macOS Seatbelt; run
npx playwright install chromium-headless-shell if there is none), and writes a
non-overwriting PNG under the project's evidence/ directory. --eval '<js>'
runs an async function body in the page before the capture (click "regenerate",
wait, type a follow-up question…) and its return value lands in the receipt.
--cdp http://127.0.0.1:9222 attaches to a Chrome started outside the sandbox
with --remote-debugging-port when even the headless shell cannot start. At least one
--expect-text is mandatory — a login page, an error page and a blank page all
produce a screenshot, so "a screenshot exists" is not evidence:
hcm chiron page /dashboard/<id> --env acme-dev --as consultant-acme-dev \
--expect-text '<dashboard title>' --reject-text '未知组件类型' \
--out evidence/acme-dev/<date>-dashboard/page.png
Both --expect-text and --reject-text are matched against the page's visible
text (document.body.innerText), not the page source: words that only appear in
<head> (<meta name="description"> mentions "AI 数字员工"), attributes, scripts
or hidden elements do not count. The receipt carries textLength; an empty visible
text (blank: true) always fails with "页面正文为空" and a next step — the path
probably does not exist (list pages are /model_list/<Model>, e.g.
/model_list/Employee), the page has not finished rendering (raise --wait-ms),
or the identity is not logged in / not allowed; when navigation never reached the
load event the next step points at the frontend address instead. A failing run
ends with one line carrying the verdict and the next step (hcm chiron test
quotes that line). Failing to read the visible text is an error, not a blank
page. The legacy spawn driver only gets
--dump-dom HTML; it strips <head>, scripts, styles, comments and tags before
matching and marks textSource: dump-dom (CSS-hidden text still counts there).
Exit code is 0 when the page carries every --expect-text and none of the
--reject-text, and 3 when it does not; the screenshot is kept either way so a
human can see whether it was a login page, an error page, or a real gap.
Raw workspace push requires Core workspace delivery protocol 1 and conditionalRawWrite.
It hashes only locally added, modified or deleted candidates, checks existence for all
baseline/local paths, and checkpoints normalized commit receipts per file. Exact desired
remote values are marked observed; an unprovable normalized result stays UNKNOWN.
The overall deadline remains 300 seconds. Mini apps currently have complete-list guards,
but do not provide conditional writes, complete pagination or full workspace resume.
hcm workspace inspect --entries --output json
mkdir -p /tmp/hcm-delivery-review
hcm workspace cleanup-plan .tools/ --purpose 'temporary logs' --reason 'external backup retained' --owner-declaration --plan /tmp/hcm-delivery-review/cleanup-001.json
hcm workspace cleanup --plan /tmp/hcm-delivery-review/cleanup-001.json --output json
hcm workspace release-plan 1.2.3 --plan /tmp/hcm-delivery-review/release-001.json --output json
hcm workspace release --plan /tmp/hcm-delivery-review/release-001.json --output json
Review plans outside the workspace. Cleanup sends only the original exact execution
paths and digest, and reports each committed, failed, notExecuted or UNKNOWN outcome.
Owner declaration and known-consumer checks do not prove absence of every possible use.
Release plans show the actual patch; unrecognized files still follow the current all-file
policy. Controlled delivery retains the existing R3 restriction on release.
Run these commands from the bound local workspace. Plan files require an existing parent outside its real physical root and are created exclusively; use a new filename each time. For API boundaries, field-policy failures and recovery, see the workspace workflow.
These commands require a Core build that implements ADR-464. They are standard product capabilities.
hcm workspace release-plan 2.0.0 --policy-version RUNTIME_ASSETS_V2 --plan /tmp/release-2.json
hcm workspace release --plan /tmp/release-2.json
hcm workspace cancel-release <releaseId> --reason 'Unused candidate'
New previews default to RUNTIME_ASSETS_V2. Unknown paths block publication. Choose
ALL_WORKSPACE_PATCH_FILES_V1 explicitly to retain the previous all-patch behavior.
The selected policy is saved with the reviewed digest and sent unchanged for checked creation;
an older Core ignoring V2 is rejected before saving an executable plan. Existing V1 plans remain compatible.
Cancellation requires both workspace ownership and configuration administrator authorization. Any deployment/MR history, package installation/recovery dependency or unknown evidence blocks it. Release bytes, audit and version reservation remain; cancelled releases cannot be deployed, merged, or used for a new workspace. Cancellation disables automatic retries. A lost response remains UNKNOWN; read the original release and its cancellation audit before deciding whether to retry that exact ID.
Find threats in your stack.
OX Radar can check high-priority threats, like critical package CVEs, against your context.
Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.
The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).
The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.