Back to skill

Security audit

News Sentiment Scan

Security checks for vulnerabilities and agentic risk

Overview

The skill is not malicious, but its financial sentiment claims materially overstate what the script actually checks.

Install only if you are comfortable treating this as a narrow Yahoo Finance headline sentiment helper, not as comprehensive market, broker-report, or social-media monitoring. Do not rely on its scores or operation suggestions for investment decisions without independently checking sources and dates, and install dependencies in an isolated environment with pinned versions where possible.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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)

T08 · Insecure Dependencies

Warning
Location
scripts/sentiment_scan.py:13
Finding

Unpinned Third-Party Dependency Installation

Content
View full analysis

Vulnerability Details

File Location: scripts/sentiment_scan.py:13-18
Vulnerability Type: Insecure and unpinned third-party dependencies
Risk Level: Medium

python
try:
    import yfinance as yf
    import pandas as pd
except ImportError as e:
    print(json.dumps({"status": "error", "message": f"缺少依赖: {e},请运行: pip install yfinance pandas"}))
    sys.exit(1)

Technical Analysis

When an import fails, the script instructs users to install yfinance and pandas directly from the active pip package index. No version constraints, integrity hashes, lockfile, or trusted index configuration are provided.

Consequently, the installed package versions and transitive dependency graph can change after this Skill has been reviewed. Although the audited source contains no evidence that these packages are currently malicious, a compromised package release, dependency, package index, or local pip configuration could introduce unreviewed code. Python packages may execute code during installation or whenever the script imports them.

Attack Path

  1. A user invokes the Skill in an environment where one or both dependencies are unavailable.
  2. The script displays the command pip install yfinance pandas.
  3. The user executes that command without version or integrity constraints.
  4. Pip resolves mutable packages and transitive dependencies through the configured package index.
  5. If the index, package release, dependency chain, or pip configuration has been compromised, attacker-controlled package code is installed.
  6. Malicious code can execute during package installation or later when sentiment_scan.py imports the affected package.

Impact Assessment

Exploitation would execute code with the privileges of the user running pip or the Skill. Depending on those privileges, attacker-controlled dependency code could read or modify accessible files, access environment variables and credentials availab ...[truncated 250 chars]

Remediation
View remediation

Remediation Suggestions

  • Add a reviewed dependency manifest with exact versions, such as requirements.txt, or use a lockfile generated by a dependency-management tool.
  • Require package hashes where supported, for example with pip install --require-hashes -r requirements.txt.
  • Pin and review transitive dependencies in addition to direct dependencies.
  • Document the expected trusted package index and prevent untrusted extra indexes from being used.
  • Use python -m pip to ensure packages are installed into the intended interpreter.
  • Install dependencies inside an isolated virtual environment without elevated privileges.
  • Run automated dependency vulnerability and integrity checks as part of release review.
  • Replace the unrestricted installation message with instructions referencing the project's reviewed, version-pinned dependency file.
Vulnerability Patterns
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (6)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill advertises broad, multi-source sentiment monitoring across announcements, broker reports, and social platforms, but the described implementation appears to rely mainly on a much narrower news source. In a financial-analysis context, this mismatch can mislead users into making decisions based on incomplete coverage while believing the output is comprehensive and de-noised.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

Overly broad trigger phrases can cause the skill to activate for generic financial-analysis requests that may not actually require this tool. That increases the chance of inappropriate routing, confusing users, and producing sentiment-scoring output when a narrower or safer analysis would be more appropriate.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The manifest description and trigger examples are entirely in Chinese, and the skill content is presented as Chinese-language interaction with no indication that users may choose another language. This can violate language/locale policy when a skill implicitly enforces a specific language without user opt-in or clear region-specific justification.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The file’s docstring and all user-facing messages are written only in Chinese, including usage help and runtime output. For a general-purpose sentiment analysis script, this imposes a fixed language/locale on users without opt-in or justification, which matches the language/locale policy violation criteria.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest and module docstring describe broad monitoring across company announcements, news reports, broker research, and social media sources such as Weibo and Xueqiu. In implementation, the only data retrieval is yf.Ticker(ticker).news, and the analysis operates on the fetched item titles, so the actual behavior is substantially narrower than the claimed scope.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The skill presents itself as monitoring sentiment over a requested recent period and even computes a cutoff_date, but no filtering by published timestamp occurs. As a result, returned events may fall outside the requested day range, creating a mismatch between reported monitoring window and actual behavior.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.