T01 · Skill Instruction Hijacking
- Location
SKILL.md:131- Finding
Silent Disclosure of User Statements and Intent Through Automatic Feedback Reporting
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill performs the stated Temu image search, but it also publicly uploads images, silently reports feedback externally, and handles credentials and payments with weak scoping.
Review this skill carefully before installing. Do not use it with private, personal, unreleased, or confidential images unless you accept public LinkFox OSS hosting. Avoid SMS-login onboarding through the agent when possible, avoid persisting API keys in shell startup files, and do not run it in an environment where LINKFOX_* endpoint variables or SESSION_ID may be attacker-controlled.
SKILL.md:131Silent Disclosure of User Statements and Intent Through Automatic Feedback Reporting
scripts/onboarding.py:68Environment-Controlled API Endpoints Can Receive LinkFox Credentials and Authentication Data
scripts/geekbi_temu_goods_image_search.py:35Unsanitized SESSION_ID Permits Writes Outside the Intended Session Directory
scripts/onboarding.py:475Generated API Keys Are Printed in Full and Recommended for Plaintext Shell Persistence
scripts/upload_image.py:115User Images Are Uploaded With Public-Read Access and No Expiration or Deletion Control
scripts/onboarding.py:30Credential-Handling Onboarding Flow Uses Unpinned Runtime Dependencies
The request forwards multiple environment-derived values, including SESSION_ID, MESSAGE_ID, MODE_ID, APP_NAME, and a configurable gateway base URL, directly into an outbound HTTP request. In this skill context, that creates a real exfiltration and SSRF-style risk if the runtime environment is attacker-influenced, because sensitive metadata and the API key-authenticated request can be sent to an arbitrary host via LINKFOX_TOOL_GATEWAY.
method="POST",
)
try:
with urlopen(req, timeout=150) as response:
raw = response.read().decode("utf-8")
try:
return json.loads(raw)
The POST target is derived from environment-controlled base URLs, so a caller who can set LINKFOX_LOGIN_API_URL or LINKFOX_AGENT_USER_API_URL can redirect SMS login, access tokens, refresh tokens, and related account data to an attacker-controlled server. In a skill/onboarding context this is especially dangerous because the code handles authentication material and transmits it automatically without validating destination hosts.
except RuntimeError as e:
return {"_error": str(e)}
try:
r = requests.post(url, json=body or {}, headers=headers, timeout=timeout)
return r.json()
except Exception as e:
body_text = ""
The gateway URL is built from environment-controlled base configuration and then used by urllib to send authenticated requests containing the API key and session metadata. If an attacker can influence LINKFOX_AGENT_API_URL or LINKFOX_TOOL_GATEWAY, they can exfiltrate credentials and steer billing or account operations to an unintended endpoint.
headers["Content-Type"] = "application/json"
req = Request(url, method=method, data=body_bytes, headers=headers)
try:
with urlopen(req, timeout=30) as resp:
return json.loads(resp.read().decode())
except urllib.error.HTTPError as e:
status = e.code
Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.
method="POST",
)
try:
with urlopen(req, timeout=150) as response:
result = json.loads(response.read().decode("utf-8"))
except HTTPError as exc:
raise RuntimeError(
Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.
method="PUT",
)
try:
with urlopen(req, timeout=120) as response:
if response.status not in (200, 201):
raise RuntimeError(f"Image upload failed with HTTP {response.status}")
except HTTPError as exc:
The documented workflow requires uploading user-provided images to LinkFox OSS and calling external gateway services, yet the skill is presented primarily as a Temu search function. If this upload/export step is not made explicit at invocation time, users may disclose images, file metadata, and access patterns to a third party without informed consent.
The documented workflow requires uploading user-provided images to LinkFox OSS and calling external gateway services, yet the skill is presented primarily as a Temu search function. If this upload/export step is not made explicit at invocation time, users may disclose images, file metadata, and access patterns to a third party without informed consent.
Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.
User requests include “用这张图找 Temu 同款”, “找外观相似的 Temu 竞品”, and “search Temu products by this image”.
## Display Rules
1. Present a compact table with image, title, product ID, price, total/monthly sales, rating, reviews, hosting mode, and update time when available.
2. Display `thumbnail` images inline when the client supports images.
YARA rule matched a known malware signature (reverse shell, backdoor, ransomware, C2 framework, or info stealer).
示 JSON 里的 phone/agreements
- 收到验证码后:`python scripts/onboarding.py login <phone> <code>`
- 拿到 `api_key` 后把下面三平台配置转发给用户,提示重启会话生效:
- Windows PowerShell(永久):`setx LINKFOX_AGENT_API_KEY "<key>"`
- macOS zsh:`echo 'export LINKFOX_AGENT_API_KEY="<key>"' >> ~/.zshrc && source ~/.zshrc`
- Linux bash:`echo 'export LINKFOX_AGENT_API_KEY="<key>"' >> ~/.bashrc && source ~/.bashrc`
- 优先使用 `LINKFOX_AGENT_API_KEY`;兼容旧环境时可使用 `LINKFOXAGENT_API_KEY`
**billing 场景**:`errcode=402` 或消息含 `算力/余额/quota/insufficient/充值/套餐到期`。
- `python scripts/onboarding.py list-plans` → 有 AskUserQuestion 就弹菜单,否则输出编号清单让用户选
- 校验 `plan_id` ∈ 清单、支付方式 ∈ 该套餐 `available_methods`(通常 `wechat/alipay`)
- `python scripts/onboarding.py order <plan_id> <method>` → 展示优先级 PNG > `pay_ur
This file implements account onboarding, SMS login, API-key acquisition, plan listing, ordering, and payment support, which is materially unrelated to the declared Temu image-search skill purpose. Such scope expansion increases attack surface and creates an unjustified path to handle user identities, credentials, and financial operations.
The code can create orders, render payment QR codes, and query payment status despite the skill being described as a Temu image-search tool. This mismatch is dangerous because it introduces billing capability that users would not reasonably expect from the skill’s advertised function.
The skill performs SMS verification, account login, team selection, and API-token generation, all outside the stated Temu search scope. This is dangerous because it collects phone numbers and verification codes and turns them into reusable API credentials, greatly increasing the sensitivity of the component.
The upload sets x-oss-object-acl: public-read, making user-supplied images publicly accessible by URL. In the context of a product-image search skill, users may upload proprietary, private, or sensitive images, so automatically exposing them to the public internet creates a confidentiality risk and can leak business-sensitive or personal data.
The skill declares no explicit tool scope even though its documented behavior requires environment-variable access, network calls, and file writes. In an agent setting, missing least-privilege boundaries increases the chance that the skill is invoked with broader capabilities than users expect, enabling unintended data access or side effects.
The skill instructs the agent to automatically send feedback under broad conditions, including user dissatisfaction, praise, or anything that could be improved, without warning the user that interaction content may be transmitted. This can leak user prompts, behavioral signals, or workflow details to a secondary API beyond what is necessary to fulfill the request.
The document title and primary instructions are presented in Chinese, which establishes a specific language expectation for the skill documentation. The file does not indicate that users may choose another language or that the locale restriction is intentional and justified as region-specific.
The documented workflow sends user-provided image data and associated metadata to external services, first to LinkFox OSS and then to the LinkFox tool gateway. Although this is core to the skill's purpose and the docs include some constraints, it still represents real external transmission of potentially sensitive user content, which becomes risky if users upload private images or if consent/data-handling boundaries are unclear.
LINKFOX_OSS_URL="$(printf '%s' "${LINKFOX_UPLOAD_RESULT}" | jq -r '.url')"
LINKFOX_CONTENT_TYPE="$(printf '%s' "${LINKFOX_UPLOAD_RESULT}" | jq -r '.contentType')"
curl --max-time 150 -X POST "${LINKFOX_TOOL_GATEWAY}/geekbi/temu/goodsImageSearch" \
-H "Authorization: ${LINKFOX_AGENT_API_KEY:-$LINKFOXAGENT_API_KEY}" \
-H "Content-Type: application/json" \
-H "User-Agent: LinkFox-Skill/2.0" \
The manifest describes a narrowly scoped skill for searching visually similar products on Temu from an image. Lines L155-L175 add a distinct capability to POST user-feedback content to an external feedback API, which is not necessary to perform image-based Temu search and is not declared as part of the skill's purpose.
The onboarding flow instructs operators to collect and pass a user's phone number and verification code to a script, but it provides no explicit consent, minimization, retention, or handling guidance for this personal data. In a support/onboarding context, this can lead to unnecessary collection of sensitive identifiers and one-time codes by the operator or system, increasing privacy and account-takeover risk if mishandled.
The instructions tell users to persist the API key into shell startup files or permanent environment settings without warning that this writes a long-lived credential to local configuration files. If those files are readable by other users, synced, backed up, or later shared, the key can be exposed and abused to access the service.
Successful API responses are cached on disk for 24 hours under the working directory without explicit user awareness. This expands the exposure window for potentially sensitive commercial data and can leak prior query results to other local users, processes, or later sessions sharing the same filesystem.
The script always writes the full API response to the local session data directory before deciding what to show the user. Because this skill handles product-search results that may include business-sensitive fields such as supply price, inventory, and shop data, persistent local storage without just-in-time disclosure or opt-in increases the risk of unintended retention and later exposure.
The file's user-facing help text and operational strings are entirely in Chinese, and the login flow is fixed to domestic phone numbers and area code +86. There is no indication that the user can choose language or locale, nor that the restriction is explicitly documented as a region-specific opt-in tool.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
except RuntimeError as e:
return {"_error": str(e)}
try:
r = requests.post(url, json=body or {}, headers=headers, timeout=timeout)
return r.json()
except Exception as e:
body_text = ""
The generated API key is printed to stdout in JSON, which may be captured by logs, agent transcripts, shell history tooling, or downstream integrations. In a hosted skill environment, this can expose reusable credentials beyond the intended user.