Back to skill

Security audit

Weather Checker

Security checks for vulnerabilities and agentic risk

Overview

The weather tool itself is straightforward, but its install instructions download mutable remote code and optionally install it system-wide with sudo, so it needs review before installation.

Install only after replacing the remote curl step with the bundled reviewed script or a pinned, checksummed release. Prefer a virtual environment and a user-local command path over sudo, and understand that city searches and coordinates are sent to Open-Meteo APIs.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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
Findings (3)

T03 · Remote Payload Retrieval and Execution

Error
Location
SKILL.md:30
Finding

Mutable Remote Executable Downloaded Without Integrity Verification

Content
View full analysis
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
SKILL.md:25
Finding

Unpinned Third-Party Dependency Installation

Content
View full analysis
Remediation
View remediation
`. 2. Generate and verify package hashes, such as by using `pip install --require-hashes -r requirements.txt`. 3. Maintain a lock file so dependency resolution is reproducible. 4. Install dependencies in a dedicated virtual environment instead of the general user site-packages directory. 5. Explicitly document the trusted package index and avoid untrusted additional indexes. 6. Periodically update the pinned version after reviewing security advisories and testing compatibility. ]]>

T05 · Unauthorized Access and Privilege Escalation

Warning
Location
SKILL.md:35
Finding

Unnecessary System-Wide Command Installation Using Elevated Privileges

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Rogue AgentSelf-Modification, Session Persistence
  • YARA SignaturesMalware Match, Webshell Match, Cryptominer Match
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (13)

YARA rule 'backdoor_persistence': Backdoor persistence with malicious payloads (shell commands, SSH key injection, hidden root users) [malware]

High
Category
YARA Match
Confidence
75% confidence
Finding

YARA rule matched a known malware signature (reverse shell, backdoor, ransomware, C2 framework, or info stealer).

Content

Scanner excerpt · README.md (reported line 44)May include surrounding context.

install requests --user

2. 使脚本可执行

chmod +x weather_checker.py

3. 创建符号链接(选择一种方式)

方式A:系统级安装(需要sudo)

sudo ln -sf $(pwd)/weather_checker.py /usr/local/bin/weather-checker

方式B:用户级安装

mkdir -p ~/.local/bin ln -sf $(pwd)/weather_checker.py ~/.local/bin/weather-checker

将 ~/.local/bin 添加到 PATH 环境变量

echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc # 或 ~/.zshrc source ~/.bashrc

text

## 使用方法

### 基本用法

```bash
# 查询北京明天的天气(默认)
weather-checker

# 查询上海明天的天气
weather-checker -c shanghai

# 查询广州后天的天气
weather-checker -c guangzhou -d 2

# 查询今天天气
weather-checker -d 0

高级用法

bash
# 使用简单格式输出
weather-checker -f simple

# 使用JSON格式输出
weather-checker -f json

# 查询英文城市名
weather-checker -c "new york"
weather-checker -c "london"
weather-checker -c "

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · README.md (reported line 38)May include surrounding context.

md
# 3. 创建符号链接(选择一种方式)
# 方式A:系统级安装(需要sudo)
sudo ln -sf $(pwd)/weather_checker.py /usr/local/bin/weather-checker

# 方式B:用户级安装
mkdir -p ~/.local/bin

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · README.md (reported line 41)May include surrounding context.

md
sudo ln -sf $(pwd)/weather_checker.py /usr/local/bin/weather-checker

# 方式B:用户级安装
mkdir -p ~/.local/bin
ln -sf $(pwd)/weather_checker.py ~/.local/bin/weather-checker
# 将 ~/.local/bin 添加到 PATH 环境变量
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc  # 或 ~/.zshrc

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
96% confidence
Finding

The skill documents network-dependent behavior and installation of a script that fetches weather data from external services, but it does not declare any tool scope or permissions for network access. This weakens transparency and policy enforcement, making it easier for users or hosting frameworks to invoke external communication without an explicit trust decision.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The natural-language documentation is entirely in Chinese, including the title, instructions, examples, and descriptive text, with no indication that language selection is optional or that the skill is intentionally limited to a Chinese-speaking audience. Under the policy provided, forcing a specific language without user opt-in is a locale-policy violation.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
94% confidence
Finding

The installation instructions tell users to download and execute code directly from a remote GitHub URL using curl, without pinning a commit, verifying a checksum, or using a signed release. If the remote content or repository is compromised, users could install and run attacker-controlled code.

Content

Scanner excerpt · SKILL.md (reported line 30)May include surrounding context.

2. 下载脚本

bash
curl -O https://raw.githubusercontent.com/yourusername/weather-checker/main/weather_checker.py
chmod +x weather_checker.py

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
93% confidence
Finding

The documentation recommends using sudo to create a symlink in /usr/local/bin for a script downloaded from the network. Combining remote code retrieval with privileged filesystem modification increases the blast radius of mistakes or compromise, and can lead to persistence of malicious or tampered code in a trusted execution path.

Content

Scanner excerpt · SKILL.md (reported line 36)May include surrounding context.

3. 创建全局命令(可选)

bash
sudo ln -sf $(pwd)/weather_checker.py /usr/local/bin/weather-checker

使用方法

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The natural-language strings throughout the file are in Chinese, the geocoding request hard-codes language="zh", and the forecast request hard-codes timezone="Asia/Shanghai". There is no indication that the tool is intentionally region-specific or that users can opt into other language/locale settings.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · weather_checker.py (reported line 104)May include surrounding context.

python
# 调用Open-Meteo API - 获取更多天气参数
        response = requests.get(
            "https://api.open-meteo.com/v1/forecast",
            params={
                "latitude": latitude,
                "longitude": longitude,

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

This markdown file describes a tool that fetches weather data from Open-Meteo and later notes use of a geocoding API, which means user query data is transmitted over the network. The README does not include any privacy or network-disclosure warning about external API requests or what query data is sent.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
85% confidence
Finding

The README instructs users to append a PATH export line to ~/.bashrc or ~/.zshrc and reload the shell configuration. This changes persistent user environment settings, but the documentation provides no warning that these commands modify shell startup files.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The documentation describes a weather query tool but does not clearly warn that user-supplied city queries and request metadata will be sent to external services over the network. This is a privacy and transparency issue because users may unknowingly disclose their interests or locations to third parties.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

This code transmits the user's requested city name to the Open-Meteo geocoding service, and later sends location coordinates to the forecast API. Although network access is central to the tool's purpose, the file contains no explicit user-facing warning or disclosure that input data will be sent to third-party services.

Content

No source excerpt is available for this finding.