T03 · Remote Payload Retrieval and Execution
- Location
scripts/publish.sh:50- Finding
Unpinned Remote Script Execution Recommended Through curl-to-shell Pipeline
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This publishing skill is legitimate in purpose, but it can publicly upload broad local directories and handles account credentials in ways users should review before installing.
Install only if you are comfortable with an agent uploading selected files to a public hosting service and managing on.qutke.cn account credentials. Before use, publish only a clean export directory, not a whole repository; check for secrets and hidden files; avoid the agent-mediated email-code login if possible; store or revoke API keys yourself; and require explicit confirmation before deleting sites, domains, handles, or links.
scripts/publish.sh:50Unpinned Remote Script Execution Recommended Through curl-to-shell Pipeline
scripts/publish.sh:150Recursive Publication Includes Hidden and Credential-Bearing Files by Default
scripts/publish.sh:298Claim Tokens Are Stored Without Explicitly Restrictive File Permissions
scripts/publish.sh:231Bearer API Key Is Forwarded to an Unvalidated Finalization URL
The skill tells the agent to ask for a one-time login code, exchange it for an API key, and store that key locally on the user's behalf. Collecting authentication codes through the agent and converting them into persistent credentials creates a strong credential-theft and account-takeover risk if the skill, environment, or logs are compromised.
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
### 删除站点
`DELETE /api/v1/publish/:slug`(别名:`DELETE /api/v1/artifact/:slug`)
硬删除站点、所有版本和 slug 索引记录。
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
### 删除站点
`DELETE /api/v1/publish/:slug`(别名:`DELETE /api/v1/artifact/:slug`)
硬删除站点、所有版本和 slug 索引记录。
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
### 删除 Handle
`DELETE /api/v1/handle`
删除您的 Handle 及其下的所有链接。
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
### 删除自定义域名
`DELETE /api/v1/domains/:domain`
删除自定义域名及其下的所有链接。
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
### 删除单个链接
`DELETE /api/v1/links/:location`
按位置删除链接。根位置使用 `__root__`。
The script includes a recommendation to install a dependency using 'curl ... | bash', which is an unsafe pattern that executes remote code without verification. Even though it appears only in an error message, users may copy and run it verbatim, making this a real supply-chain risk if the remote host is compromised, intercepted, or serves unexpected content.
elif command -v jq >/dev/null 2>&1; then
JQ_BIN="$(command -v jq)"
else
die "requires jq (run: curl -fsSL https://on.qutke.cn/install.sh | bash)"
fi
for cmd in curl file; do
The skill invokes shell commands and performs network operations but does not declare any explicit tool scope or allowed-tools boundary. That increases the chance of overbroad execution in host environments, especially because the skill can upload local content and handle credentials.
The skill description emphasizes ease of publishing but does not prominently warn that files are uploaded to a public URL and may expose sensitive data. Because the primary action is external publication, omission of this warning materially raises the risk of inadvertent data disclosure.
The trigger phrases are broad and overlap with common user requests like 'share this', 'put this online', or 'make a website'. In context, accidental invocation is dangerous because the skill's main action is public internet publication of local files.
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
保存 Key,将其写入凭据文件:
mkdir -p ~/.onqutke && echo "{API_KEY}" > ~/.onqutke/credentials && chmod 600 ~/.onqutke/credentials
重要:收到 API Key 后请立即保存——自行执行上述命令。不要让用户手动运行。避免在交互会话中通过 CLI 参数(如 --api-key)传递 Key;凭据文件是推荐的存储方式。
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
保存 Key,将其写入凭据文件:
mkdir -p ~/.onqutke && echo "{API_KEY}" > ~/.onqutke/credentials && chmod 600 ~/.onqutke/credentials
重要:收到 API Key 后请立即保存——自行执行上述命令。不要让用户手动运行。避免在交互会话中通过 CLI 参数(如 --api-key)传递 Key;凭据文件是推荐的存储方式。
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
保存 Key,将其写入凭据文件:
mkdir -p ~/.onqutke && echo "{API_KEY}" > ~/.onqutke/credentials && chmod 600 ~/.onqutke/credentials
重要:收到 API Key 后请立即保存——自行执行上述命令。不要让用户手动运行。避免在交互会话中通过 CLI 参数(如 --api-key)传递 Key;凭据文件是推荐的存储方式。
The duplicated finding still reflects a real issue: the skill directs the agent to save a persistent credential in the user's home directory. Given the skill's public-upload behavior and expanded account-management scope, storing reusable secrets locally makes misuse and unintended future actions more likely.
保存 Key,将其写入凭据文件:
mkdir -p ~/.onqutke && echo "{API_KEY}" > ~/.onqutke/credentials && chmod 600 ~/.onqutke/credentials
重要:收到 API Key 后请立即保存——自行执行上述命令。不要让用户手动运行。避免在交互会话中通过 CLI 参数(如 --api-key)传递 Key;凭据文件是推荐的存储方式。
The duplicated finding still reflects a real issue: the skill directs the agent to save a persistent credential in the user's home directory. Given the skill's public-upload behavior and expanded account-management scope, storing reusable secrets locally makes misuse and unintended future actions more likely.
保存 Key,将其写入凭据文件:
mkdir -p ~/.onqutke && echo "{API_KEY}" > ~/.onqutke/credentials && chmod 600 ~/.onqutke/credentials
重要:收到 API Key 后请立即保存——自行执行上述命令。不要让用户手动运行。避免在交互会话中通过 CLI 参数(如 --api-key)传递 Key;凭据文件是推荐的存储方式。
The instruction to immediately save any received API key without user intervention normalizes autonomous credential handling by the agent. This is dangerous because it bypasses informed consent and can leave long-lived secrets on disk where other processes, logs, or future runs may access them.
The advertised purpose is simple file publishing, but the skill additionally instructs the agent to request a user's email, collect a one-time login code, exchange it for an API key, and persist that credential locally. This materially expands the trust boundary from content publishing to account access and credential management, which is far more sensitive.
This command transmits the user's email address to an external service to initiate authentication. While expected for the feature, it is still an external data transfer and becomes risky because the skill does not pair it with strong consent language or isolation from the broader credential collection flow.
curl -sS https://on.qutke.cn/api/auth/agent/request-code \
-H "content-type: application/json" \
-d '{"email": "user@example.com"}'
This repeats the same pattern of locally persisting the returned apiKey after agent-mediated authentication. In context, the skill is turning a transient verification step into durable account access retained on the machine.
apiKey(不要让用户操作):mkdir -p ~/.onqutke && echo "{API_KEY}" > ~/.onqutke/credentials && chmod 600 ~/.onqutke/credentials
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
curl -sS -X POST https://on.qutke.cn/api/v1/publish/{slug}/duplicate \
-H "Authorization: Bearer {API_KEY}" \
-H "Content-Type: application/json" \
-d '{}'
The skill includes domain management, handle management, link routing, deletion, and duplication capabilities that go well beyond generating a {slug}.on.qutke.cn publishing URL. These extra powers can alter a user's web presence or destroy mappings if invoked without narrowly scoped authorization.
The documentation describes deletion of custom domains and associated links without an explicit destructive-action warning or confirmation requirement. In context, these operations can break live sites and remove user configurations beyond the core publishing task.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
1. 通过邮箱请求一次性验证码:
curl -sS https://on.qutke.cn/api/auth/agent/request-code \
-H "content-type: application/json" \
-d '{"email": "user@example.com"}'
这是一个 markdown 文件,因此应检查是否缺少会影响用户数据、隐私或系统完整性的警示。L076-L080 提供了将 <API_KEY> 写入 ~/.onqutke/credentials 的具体命令,但除了权限设置外,没有明确提醒该操作会在本机持久保存敏感凭据、应避免在共享环境执行或注意 shell 历史/替换风险。
This duplicate finding refers to the same plaintext credential persistence behavior. In the context of a publishing skill with account-level APIs, a stolen API key could allow unauthorized site changes, deletion, metadata changes, and domain/link operations.
4. 将 API Key 保存到凭据文件:
mkdir -p ~/.onqutke && echo "<API_KEY>" > ~/.onqutke/credentials && chmod 600 ~/.onqutke/credentials
No suspicious patterns detected.