Back to skill

Security audit

Who Is Undercover Publish

Security checks for vulnerabilities and agentic risk

Overview

The skill is a playable local game, but bundled integration scripts include an exposed InStreet API credential, under-disclosed external network behavior, and state-changing status code.

Review before installing. The core game appears purpose-aligned, but the package should remove and rotate the exposed InStreet credential, disclose or remove external network integration, declare dependencies, and prevent status scripts from mutating or exporting hidden game state unexpectedly.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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 (2)

T09 · Insecure Skill Coding Practices

Error
Location
instreet_game_controller.js:150
Finding

Hard-Coded InStreet API Bearer Credential

Content
View full analysis

Vulnerability Details

File Location: instreet_game_controller.js:150-152
Vulnerability Type: Hard-coded authentication secret
Risk Level: High

The controller embeds a complete InStreet API key directly in distributed source code. The credential value is intentionally redacted below to avoid further disclosure:

js
async function main() {
  const apiKey = 'sk_inst_[REDACTED_EXPOSED_CREDENTIAL]';
  const controller = new InStreetGameController(apiKey);

The credential is passed to the adapter and used as a bearer token in instreet_adapter.js:5-11:

js
constructor(apiKey) {
  this.apiKey = apiKey;
  this.baseURL = 'https://instreet.coze.site/api/v1/games';
  this.headers = {
    'Authorization': `Bearer ${apiKey}`,
    'Content-Type': 'application/json'
  };
}

Technical Analysis

Secrets embedded in source code are available to every person or system that can download, install, inspect, archive, or mirror the package. The token is not protected by runtime access controls and can be extracted without executing the Skill.

The adapter places the credential in the Authorization header for room creation, activity polling, game moves, and room joining. An attacker can therefore copy the token into an independent HTTP client and attempt authenticated operations against the InStreet API.

Removing the credential only from the latest file would not be sufficient if the package or repository has already been published, because it may remain in caches, mirrors, downloaded archives, and version-control history.

Attack Path

  1. An attacker downloads or inspects the distributed Skill package.
  2. The attacker reads the hard-coded token from instreet_game_controller.js.
  3. The attacker identifies the API base URL and supported endpoints from instreet_adapter.js.
  4. The attacker submits requests using Authorization: Bearer <extracted-token>.
  5. If the credential re ...[truncated 652 chars]
Remediation
View remediation

Remediation Suggestions

  1. Revoke and rotate the exposed credential immediately.
  2. Remove the credential from the current source and all version-control history.
  3. Load the API key from an approved secret manager or protected runtime environment variable.
  4. Refuse to start the remote integration when no credential has been explicitly configured.
  5. Never include secret values in logs, errors, generated files, examples, or test fixtures.
  6. Scope replacement credentials to the minimum required API permissions and apply usage limits where supported.
  7. Add automated secret scanning to local commits, continuous integration, and publication validation.
  8. Review remote API logs for unauthorized activity involving the exposed credential.

T09 · Insecure Skill Coding Practices

Warning
Location
instreet_adapter.js:5
Finding

Undisclosed External Transmission of Game Data

Content
View full analysis

Vulnerability Details

File Location: instreet_adapter.js:5-10, 58-64, 79-85; conflicting permission documentation at INSTALL.md:44-53
Vulnerability Type: Misrepresented network behavior and external data disclosure
Risk Level: Medium

The adapter configures an external API destination and attaches bearer authentication:

js
constructor(apiKey) {
  this.apiKey = apiKey;
  this.baseURL = 'https://instreet.coze.site/api/v1/games';
  this.headers = {
    'Authorization': `Bearer ${apiKey}`,
    'Content-Type': 'application/json'
  };
}

User or game-generated descriptions and reasoning are transmitted to that service:

js
async submitDescription(roomId, description, reasoning = '') {
  try {
    const response = await axios.post(`${this.baseURL}/rooms/${roomId}/move`, {
      description: description,
      reasoning: reasoning
    }, { headers: this.headers });

Votes and associated reasoning are also transmitted:

js
async submitVote(roomId, targetSeat, reasoning = '') {
  try {
    const response = await axios.post(`${this.baseURL}/rooms/${roomId}/move`, {
      target_seat: targetSeat,
      reasoning: reasoning
    }, { headers: this.headers });

The installation guide at INSTALL.md:44-53 states that the Skill requires no additional dependency packages and makes no external network requests because all logic runs locally. Those statements conflict with the bundled adapter, which requires axios and communicates with instreet.coze.site.

Technical Analysis

The primary OpenClaw entry point, index.js, does not directly invoke the adapter. However, the networked controller is executable bundled functionality. When instreet_game_controller.js is run directly, its main() function creates a remote room and enters a continuous polling loop.

During that loop, the controller can transmit room metadata, descriptions, votes, generated reasoning, ...[truncated 1518 chars]

Remediation
View remediation

Remediation Suggestions

  1. Correct the installation and permission documentation to disclose all external network behavior.
  2. Require explicit user opt-in before enabling the InStreet integration or transmitting game content.
  3. Clearly identify the destination host, transmitted fields, purpose, retention expectations, and authentication requirements.
  4. Separate remote integration code from the local-only Skill package if it is not required for normal operation.
  5. Make the endpoint configurable through trusted configuration while enforcing HTTPS and an approved-host allowlist.
  6. Minimize transmitted data and omit reasoning unless it is necessary and the user has consented.
  7. Declare and pin axios in package.json, include a lockfile, and subject the dependency to supply-chain review; alternatively, use an approved built-in HTTP client.
  8. Add request timeouts, payload-size limits, controlled retry behavior, and sanitized error logging.
  9. Document how users can disable the integration and delete remotely stored game data.
  10. Add publication checks that compare declared permissions and dependencies against actual network imports and destinations.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Memory PoisoningPersistent Context Injection, Context Window Stuffing, Memory Manipulation
  • 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 (24)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

Undeclared local file read/write behavior combined with status reporting that exposes full game progress, player descriptions, votes, and undercover role information directly undermines confidentiality of the game and can leak sensitive conversation/state data to local storage. In the context of a deception game, revealing hidden roles breaks game integrity entirely, and persistent logs may expose private user inputs beyond the session.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

Undeclared local file read/write behavior combined with status reporting that exposes full game progress, player descriptions, votes, and undercover role information directly undermines confidentiality of the game and can leak sensitive conversation/state data to local storage. In the context of a deception game, revealing hidden roles breaks game integrity entirely, and persistent logs may expose private user inputs beyond the session.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Undeclared local file read/write behavior combined with status reporting that exposes full game progress, player descriptions, votes, and undercover role information directly undermines confidentiality of the game and can leak sensitive conversation/state data to local storage. In the context of a deception game, revealing hidden roles breaks game integrity entirely, and persistent logs may expose private user inputs beyond the session.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

Undeclared local file read/write behavior combined with status reporting that exposes full game progress, player descriptions, votes, and undercover role information directly undermines confidentiality of the game and can leak sensitive conversation/state data to local storage. In the context of a deception game, revealing hidden roles breaks game integrity entirely, and persistent logs may expose private user inputs beyond the session.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

Undeclared local file read/write behavior combined with status reporting that exposes full game progress, player descriptions, votes, and undercover role information directly undermines confidentiality of the game and can leak sensitive conversation/state data to local storage. In the context of a deception game, revealing hidden roles breaks game integrity entirely, and persistent logs may expose private user inputs beyond the session.

Content

No source excerpt is available for this finding.

Memory Manipulation

High
Category
Memory Poisoning
Confidence
80% confidence
Finding

Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.

Content

Scanner excerpt · index.js (reported line 376)May include surrounding context.

js
}
  
  currentGames.delete(gameId);
  delete context.gameId;
  
  return {
    success: true,

Missing User Warnings

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The file contains a hardcoded API key directly in source code, which is a real credential exposure issue. If this code is shared, committed to version control, logged, or reused in other environments, an attacker can extract the key and invoke the external service as the owner, potentially causing account abuse, data exposure, or billing loss.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The file is presented as a real-time status monitor, but it also mutates persistent game state, advances phases, and simulates an AI player's move. This hidden side effect violates least surprise and can trigger unauthorized state changes whenever the script is run, which is especially risky for multi-user or agent-driven workflows that may invoke it assuming read-only behavior.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The documentation states '无外部依赖,纯JavaScript' and '本地计算,无网络延迟' at L082-L085, which implies a self-contained local implementation. However, the same README claims '飞书集成(支持群聊游戏)', 'ClawHub集成', '支持自动更新', and 'InStreet社区认证' at L049 and L089-L090, which are network-dependent capabilities and contradict the 'no network latency'/'no external dependencies' characterization.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

This markdown file presents the skill description and usage entirely in Chinese, while the surrounding repository context is not documented as China-only or Chinese-only. Under the policy rule, forcing a specific language without user opt-in or clear justification is a natural-language policy violation.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
79% confidence
Finding

The README states the skill is a '无外部依赖,纯JavaScript' and '本地计算,无网络延迟' implementation, which conveys a purely local/offline design. In the same document it advertises Feishu group-chat support, InStreet community certification, ClawHub integration, and a persisted 'room_link.txt', which indicate external platform/network involvement and therefore contradict the local/no-network characterization.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file hard-codes game content and user-facing text in Chinese, including word pairs and gameplay messages, without offering a language option or documenting that the skill is intentionally Chinese-only. This can violate language/locale policy when users are not given an opt-in choice.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

AI-generated descriptions and category hints are emitted only in Chinese, and the code does not indicate any user-selectable locale behavior. This creates a consistent forced-language experience rather than an opt-in or documented regional constraint.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This code defines the skill description, command descriptions, usage strings, and runtime messages in Chinese only. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale restriction is explicitly documented and justified, which is not present here.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

This code accepts an API key and sends it in the Authorization header on every axios request, which is access to sensitive credentials plus network transmission. While the file has brief comments and error logging, it does not include any user-facing warning, confirmation, or explanatory note that credentials will be transmitted to an external service.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

Comments, status messages, and fixed gameplay content are entirely in Chinese, including room/game text and user-facing logs. The file does not offer any language selection or explain that the skill is intentionally limited to a Chinese-speaking context, which is a natural-language locale policy concern.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The comments and naming describe a monitoring/read-status utility, but the implementation writes files and progresses gameplay. This mismatch is dangerous because reviewers, operators, or other agents may trust the file as observational tooling and invoke it in contexts where state changes are not expected.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file's comments, console messages, and generated report content are all in Chinese, which imposes a specific language on users. There is no opt-in, fallback, or documented justification that this skill is intended only for a Chinese-language environment.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

The status report writes full game details, including player descriptions, votes, alive players, and even undercover-role indicators, to a plaintext file without access controls or user confirmation. In this game context, leaking hidden-role information or in-progress votes can completely compromise fairness and reveal sensitive state to unintended readers.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

The title and all instructional content are written in Chinese, which effectively forces a specific language for users of this skill documentation. The policy requires flagging language or locale constraints unless the file offers user choice or clearly documents a justified regional limitation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

Line L033 states that Chinese and English documentation must be complete, which imposes specific language requirements in natural language. The file does not explain that this is optional, user-selected, or justified by a region-specific constraint, so it may conflict with language/locale choice policy.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

The skill description is primarily written in Chinese, while the final promotional line is in English. This presents a language/locale inconsistency and does not give users an explicit option to choose their preferred language, which can conflict with organizational language-choice expectations.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
96% confidence
Finding

The comment at L164 says the code will find the next available human player slot, implying some form of participant-to-slot assignment. In reality, the implementation at L173 simply selects humanPlayers[0], so the documented intent contradicts the actual behavior and does not truly support joining distinct human players.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

The file's natural-language comments, default room name, and user-visible error/message strings are all hard-coded in Chinese, with no indication that users can choose another language. This creates a locale/language policy concern because the skill appears to force a specific language without documented opt-in or justification.

Content

No source excerpt is available for this finding.