Back to skill

Security audit

GitHub Latest Hot Repo Explorer

Security checks for vulnerabilities and agentic risk

Overview

This repository finder needs review because it silently reads a saved GitHub token despite promising anonymous access when no environment token is supplied.

Before installing, have the host credential-file fallback removed or block access to ~/.openclaw/.env. Leaving GITHUB_TOKEN unset does not guarantee anonymous operation. If authentication is needed, explicitly supply a token limited to public-repository reads. The skill also saves local history and reports, and its 100-result search limit can miss repositories. Static inspection covered every bundled file; live network behavior and host isolation were not tested.

Vulnerability Patterns
  • 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
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
Findings (10)

Tainted flow: 'url' from os.environ.get (line 106, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · scripts/fetch_repo.py (reported line 66)May include surrounding context.

python
if headers:
        request_headers.update(headers)
    try:
        with urllib.request.urlopen(urllib.request.Request(url, headers=request_headers), timeout=30) as response:
            body = response.read()
            return json.loads(body.decode("utf-8")) if "json" in response.headers.get("Content-Type", "") else body.decode("utf-8", errors="replace")
    except urllib.error.HTTPError as error:

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
91% confidence
Finding

The main workflow matches the description, and authentication, README retrieval, and local deduplication history support that workflow. However, search_repos requests only one page with per_page=100. If all 100 returned repositories have already been reported, eligible unreported repositories may remain on later pages. The code nevertheless expands the window, potentially selecting an older repository instead, or reports that no new repository exists. This materially contradicts the declared strict selection behavior.

Content

No source excerpt is available for this finding.

Credential Access

High
Category
Privilege Escalation
Confidence
98% confidence
Finding

Although this match is in a docstring, the surrounding implementation performs the described credential-file fallback. Its stated purpose is to circumvent token filtering, allowing the skill to obtain host credentials despite their omission from its environment.

Content

Scanner excerpt · scripts/fetch_repo.py (reported line 35)May include surrounding context.

python
def load_token() -> str:
    """优先读环境变量;读不到再从 ~/.openclaw/.env 读(OpenClaw exec 快照会过滤 token 类环境变量,故需文件回退)。"""
    token = os.environ.get("GITHUB_TOKEN", "")
    if token:
        return token

Credential Access

High
Category
Privilege Escalation
Confidence
99% confidence
Finding

The code opens ~/.openclaw/.env and extracts GITHUB_TOKEN when the process has not received that credential. This crosses the intended credential boundary and silently authenticates requests using a potentially more privileged host token, even though no attacker-controlled destination is shown.

Content

Scanner excerpt · scripts/fetch_repo.py (reported line 39)May include surrounding context.

python
token = os.environ.get("GITHUB_TOKEN", "")
    if token:
        return token
    env_file = os.path.expanduser("~/.openclaw/.env")
    try:
        with open(env_file, "r", encoding="utf-8") as f:
            for line in f:

Skill declares no tool scope ('permissions' or 'allowed-tools') but code capabilities were detected: env, file_read, file_write, network.

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

Whitespace Padding

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Content

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

md
## 五、参数

| 参数              | 说明                                                                                  |
| ----------------- | ------------------------------------------------------------------------------------- |
| `--stars N`       | star 下限(硬性条件,严格大于),默认 5000                                            |
| `--months N`      | 初始窗口(自然月),默认 1,后续档位为 1、2、3、6、12、24、36、48、60 中不小于 N 的值 |

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 · scripts/fetch_repo.py (reported line 15)May include surrounding context.

python
from pathlib import Path
from typing import Optional, Union

SEARCH_URL = "https://api.github.com/search/repositories"
README_URL_TMPL = "https://api.github.com/repos/{owner}/{repo}/readme"
PER_PAGE = 100
README_MAX_CHARS = 8000

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 · scripts/fetch_repo.py (reported line 16)May include surrounding context.

python
from typing import Optional, Union

SEARCH_URL = "https://api.github.com/search/repositories"
README_URL_TMPL = "https://api.github.com/repos/{owner}/{repo}/readme"
PER_PAGE = 100
README_MAX_CHARS = 8000
WINDOW_STEPS = [1, 2, 3, 6, 12, 24, 36, 48, 60]

The token fallback reads host credentials to bypass environment-token filtering.

Medium
Category
Excessive Agency
Confidence
99% confidence
Finding

The fallback explicitly reads a host credential file to work around execution-environment token filtering. This defeats credential isolation and silently uses a credential that was not passed to the process, contrary to the documented anonymous fallback.

Content

No source excerpt is available for this finding.

Fetching only the first 100 results prevents reliable selection of the highest-star repository not previously output.

Medium
Category
Excessive Agency
Confidence
98% confidence
Finding

The search requests one page of 100 repositories and never paginates, while lines L122-L127 exclude previously shown repositories only after that page is fetched. Once those 100 repositories have been shown, the skill expands the window or reports no new repository even if eligible unseen repositories remain on later pages, contrary to the manifest's strict selection promise.

Content

No source excerpt is available for this finding.