Back to skill

Security audit

jike-publisher

Security checks for vulnerabilities and agentic risk

Overview

The skill is for posting to Jike and mostly stays within that purpose, but it needs review because it can publish publicly, stores full post content locally, and ships an optional script that reports posting success without actually posting.

Install only if you are comfortable giving the agent access to an already logged-in Jike browser session. Before posting, require the agent to show the exact account and content and wait for explicit approval. Avoid using scripts/post_jike.py as proof of publication, and delete or minimize memory/jike-state.json if the post text is sensitive.

Vulnerability Patterns
  • Tool Hijacking and SpoofingModifies or replaces tools so legitimate-looking calls execute attacker logic
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T07 · Tool Hijacking and Spoofing

Warning
Location
scripts/post_jike.py:78
Finding
False Publication Success and Fabricated Publishing State## Vulnerability Details **File Location**: `scripts/post_jike.py:78-107` and `scripts/post_jike.py:165-170` **Vulnerability Type**: False tool-operation success reporting **Risk Level**: Medium ### Vulnerable Code ```python def post_to_jike(content): """ Post content to Jike using browser automation. This is a reference implementation showing the workflow. In practice, you would use OpenClaw's browser tool directly. Args: content: Text content to post Returns: bool: True if successful, False otherwise """ print(f"📝 Posting to Jike...") print(f"Content: {content[:50]}{'...' if len(content) > 50 else ''}") print(f"Length: {len(content)} characters") steps = [ f"1. Open {JIKE_URL}", "2. Take snapshot to get element refs", "3. Click textbox", "4. Type content", "5. Click send button", "6. Verify post appeared" ] print("\nSteps:") for step in steps: print(f" {step}") print("\n✅ Post workflow defined. Use OpenClaw browser tool to execute.") return True ``` ```python # Post success = post_to_jike(content) if success: write_state(content) print("\n✅ Success! State updated.") return 0 ``` ### Technical Analysis The `post_to_jike()` function performs no browser automation, API request, or network communication with Jike. It only prints a proposed workflow and explicitly states that the OpenClaw browser tool must be used separately. Despite performing no publication, the function unconditionally returns `True`. The caller interprets this value as evidence that publication succeeded, writes the supplied content and current timestamp to `jike-state.json`, prints a success message, and exits with status code zero. No verification is performed to confirm that the content appeared on Jike. This creates a s ...[truncated 1569 chars]
Remediation
## Remediation Suggestions 1. Implement the browser automation represented by the script before returning success. 2. Verify publication through a reliable postcondition, such as locating the submitted content or a unique post identifier in the authenticated Jike session. 3. Return `True` only after this verification succeeds; return `False` for navigation, authentication, submission, timeout, and verification failures. 4. Update `jike-state.json` only after confirmed publication. 5. If the file is intentionally only a workflow demonstration, rename it accordingly and return a nonzero or explicit “not implemented” result instead of success. 6. Distinguish result states such as `submitted`, `verified`, `failed`, and `not_implemented` rather than using an unconditional Boolean. 7. Add tests that assert state is not modified when no browser action occurs or when publication verification fails.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (12)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding
The skill description says it only publishes to Jike via browser automation, but the content also introduces undeclared persistent state handling and references extra script behavior not reflected in the declared purpose. This mismatch is dangerous because users and policy systems may approve the skill based on a narrower trust boundary than the behavior actually requires.

Missing User Warnings

Medium
Confidence
90% confidence
Finding
The quick-start workflow directly automates publishing to a public social platform and later updates a local state file, but it does not instruct the agent to warn the user or obtain explicit confirmation immediately before the irreversible publish action. In an agent setting, this increases the risk of accidental disclosure, posting the wrong content/account, or creating an unintended audit trail in local state without informed user consent.

Natural-Language Policy Violations

Medium
Confidence
82% confidence
Finding
The instructions explicitly say "ALWAYS Use Unicode Escape for Chinese" and the examples assume Chinese content as mandatory behavior. This is a natural-language locale constraint without any user opt-in or documented region-specific justification, which can violate language/locale policy requirements.

Lp3

Medium
Category
MCP Least Privilege
Confidence
90% confidence
Finding
The skill documents reading and writing `memory/jike-state.json` but does not declare any tool scope or permissions for file access. Undeclared file capabilities weaken least-privilege controls and can enable unexpected persistence of user data or future expansion into broader local file access without clear user awareness.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The skill proposes storing `lastContent` and publication timestamps in a local state file without warning the user that their post history will be retained. This creates a privacy risk because sensitive drafts, personal updates, or confidential text intended only for posting may remain accessible on disk after use.

Missing User Warnings

Medium
Confidence
87% confidence
Finding
The examples automate a real publish action to a social platform and also persist posting metadata, including the last posted content, to local disk without any explicit warning about side effects. In a skill whose purpose is browser-driven posting, this increases the chance of unintended public posting and unnecessary retention of potentially sensitive user content.

Natural-Language Policy Violations

Medium
Confidence
83% confidence
Finding
The file states that Chinese quotation marks/content require special handling and instructs users to use Unicode escapes for all Chinese content. This is a locale-specific constraint presented as a blanket requirement, but the document does not explain why Chinese-language input is required or offer any user choice around language/locale behavior.

Natural-Language Policy Violations

Medium
Confidence
88% confidence
Finding
The guide states 'Use Unicode escape (`\uXXXX`) for all Chinese characters,' which prescribes special handling specifically for Chinese content rather than presenting it as an optional workaround. This is a natural-language locale policy concern because it enforces a language-specific constraint without documenting user choice or a justified regional limitation.

Description-Behavior Mismatch

Medium
Confidence
98% confidence
Finding
The script presents itself as a publisher for Jike, but the core posting function only prints a workflow and always returns success without performing any browser automation or verifying that a post was created. This is dangerous because downstream agents or users may believe content was published when it was not, causing silent failure, workflow integrity issues, and false state tracking via the persisted success record.

Intent-Code Divergence

Medium
Confidence
96% confidence
Finding
The docstring and interface explicitly claim that the function posts content to Jike, but the implementation only logs a reference workflow. In an agent skill context, this mismatch is especially risky because other components may trust the function contract and take follow-up actions based on a publication that never happened.

Natural-Language Policy Violations

Low
Confidence
76% confidence
Finding
SQP-3 applies to all file types and covers language/locale policy violations. Large portions of the operational instructions and examples are Chinese-only, and the skill emphasizes Chinese text handling, but it does not state that the skill is region-specific or offer users a language/locale choice.

Natural-Language Policy Violations

Low
Confidence
77% confidence
Finding
The natural-language examples and UI expectations assume Chinese content and Chinese interface labels such as "发布" and "登录". Because the file does not state that the skill is China/Chinese-specific or offer an alternative language/locale path, it may impose a locale preference without user opt-in.

Static analysis

No suspicious patterns detected.