Back to skill

Security audit

daily-news-brief

Security checks for vulnerabilities and agentic risk

Overview

The skill is a real news-briefing tool, but it accepts unvalidated custom news URLs and can schedule and push fetched content externally, which needs careful review before installation.

Install only if you trust the configured news sources and OpenClaw push targets. Avoid adding arbitrary or untrusted URLs, review any cron entry before enabling it, pin dependencies yourself before running npm install, and do not run the rm cleanup or uninstall commands until you have verified the exact directories to be deleted.

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

T09 · Insecure Skill Coding Practices

Error
Location
tools/NewsFetcher.ts:35
Finding
Arbitrary News Source URLs Permit Server-Side Request Forgery<![CDATA[ ## Vulnerability Details **File Location**: `tools/Configure.ts:95-110`; `tools/NewsFetcher.ts:35-53` **Vulnerability Type**: Server-Side Request Forgery through unvalidated configurable URLs **Risk Level**: High ### Vulnerable Code `tools/Configure.ts:95-110` accepts a source URL without validating its protocol, hostname, resolved address, or destination: ```ts function parseSource(input: string): NewsSource { const parts = input.split(',').map(p => p.trim()); if (parts.length !== 4) { throw new Error('参数格式错误,示例:"新智元,https://xinzhiyuan.ai/feed,rss,AI"'); } const [name, url, type, category] = parts; if (!name || !url) { throw new Error('新闻源 name 与 url 不能为空'); } if (type !== 'rss' && type !== 'web') { throw new Error('type 只能为 rss 或 web'); } ``` `tools/NewsFetcher.ts:35-53` subsequently requests the configured URL: ```ts private async fetchFromRSS(source: NewsSource): Promise<NewsItem[]> { const feed = await parser.parseURL(source.url); return feed.items.map(item => ({ title: item.title || '', link: item.link || '', pubDate: new Date(item.pubDate || Date.now()), description: item.contentSnippet || item.content, source: source.name, category: source.category, })); } private async fetchFromWeb(source: NewsSource): Promise<NewsItem[]> { const response = await fetch(source.url); const html = await response.text(); ``` ### Technical Analysis The news-source URL is configuration-controlled and reaches network request functions without destination validation. There is no enforcement of HTTPS, no hostname allowlist, no rejection of loopback or private network ranges, no DNS rebinding defense, and no redirect validation. Although `workflows/FetchNews.md` describes a trusted-domain filter, the executable implementation does not apply such a filter. An attacker who can influence the configuration or persuade a user or Agent to add a source can therefore make the pr ...[truncated 1796 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Permit only `https:` URLs unless a documented source specifically requires another secure scheme. 2. Maintain an explicit allowlist of approved news-source hostnames and compare normalized hostnames exactly; do not use substring matching. 3. Resolve the hostname before connecting and reject loopback, link-local, private, multicast, unspecified, and reserved IPv4 and IPv6 addresses. 4. Repeat destination validation after every redirect and restrict the number of redirects. 5. Protect against DNS rebinding by connecting only to the validated resolved address while preserving correct TLS hostname verification. 6. Add strict connection and response timeouts, response-size limits, and content-type checks. 7. Disable arbitrary custom sources by default. If custom sources are necessary, require explicit user confirmation that clearly displays the final hostname. 8. Apply the same validator to both RSS and web source paths. 9. Add tests covering localhost, private IPv4 ranges, IPv6 loopback, encoded IP forms, redirects to private hosts, and DNS rebinding scenarios. ]]>

T09 · Insecure Skill Coding Practices

Note
Location
tools/MarkdownGenerator.ts:91
Finding
Absolute Local Filesystem Path Is Disclosed to External Push Channels<![CDATA[ ## Vulnerability Details **File Location**: `tools/MarkdownGenerator.ts:91-93`; `tools/FetchNews.ts:91-103,155` **Vulnerability Type**: Local environment information disclosure **Risk Level**: Low ### Vulnerable Code `tools/MarkdownGenerator.ts:91-93` appends the locally resolved file path to the summary: ```ts if (options.filePath) { summary += `本地文档:${options.filePath}\n`; } ``` `tools/FetchNews.ts:91-103` sends that summary to external OpenClaw channels: ```ts function sendViaOpenClaw(summary: string, config: Config) { if (!config.push || !config.push.enabled || config.push.channels.length === 0) { return; } for (const channel of config.push.channels) { const args = ['message', 'send', '--channel', channel, '--message', summary]; const target = config.push.targets?.[channel]; if (target) { args.push('--target', target); } const result = spawnSync('openclaw', args, { encoding: 'utf-8' }); ``` The send operation is reached at `tools/FetchNews.ts:155`: ```ts sendViaOpenClaw(summary, config); ``` ### Technical Analysis `saveLocal()` expands `~` to the current user's home directory and returns the resulting absolute path. That path is passed to `generateSummary()`, appended to the same summary used for external delivery, and sent to every configured Telegram, Feishu, WhatsApp, Slack, Discord, or other OpenClaw channel. This unnecessarily combines local diagnostic information with externally transmitted content. The disclosure is not required to deliver a news summary and exceeds the minimum information necessary for the push feature. ### Attack Path 1. Local document saving is enabled. 2. OpenClaw push delivery is enabled and at least one external channel is configured. 3. `FetchNews.ts` generates and saves the Markdown document. 4. `saveLocal()` returns an absolute path containing the host's home-directory structure. 5. `generateSummary()` embeds the path in the outgoing message. 6. ` ...[truncated 629 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Create separate local-console and external-message representations. 2. Never include an absolute local path in externally delivered summaries. 3. Replace the path with a generic statement such as `A local copy was saved`. 4. If a file reference is necessary, include only the basename, such as `2026-03-17.md`. 5. Add an explicit configuration option for path disclosure and keep it disabled by default. 6. Validate push targets and display them to the user before enabling delivery. 7. Add a test asserting that outgoing OpenClaw messages do not contain the user's home directory or other absolute paths. ]]>

T08 · Insecure Dependencies

Warning
Location
QuickStartGuide.md:82
Finding
Unpinned Third-Party Dependency Installation Creates Supply-Chain Risk<![CDATA[ ## Vulnerability Details **File Location**: `QuickStartGuide.md:82-85` **Vulnerability Type**: Unpinned and non-reproducible dependency installation **Risk Level**: Medium ### Vulnerable Code ```bash ### 步骤 3:安装依赖 ```bash cd /path/to/daily-news-brief/tools npm install rss-parser cheerio ``` ``` ### Technical Analysis The installation instructions request package names without reviewed version constraints. The project also lacks a committed `package.json` and lockfile in the audited directory structure. Consequently, installation resolves mutable registry versions at the time the command is run. This prevents reproducible builds and means future users may execute dependency code that was not part of the audited artifact. npm packages can execute lifecycle scripts during installation, and their runtime dependency trees can change independently. No evidence was found that `rss-parser` or `cheerio` is currently malicious. The finding concerns the unsafe dependency acquisition process rather than a confirmed malicious package. ### Attack Path 1. A dependency account, release process, registry entry, or transitive dependency is compromised, or a future release introduces malicious behavior. 2. A user follows the Quick Start instructions at a later date. 3. `npm install rss-parser cheerio` resolves the then-current package and transitive dependency versions. 4. npm downloads packages that were not pinned or represented in the reviewed project. 5. Malicious code may run through an installation lifecycle script or when the Skill imports and uses the dependency. ### Impact Assessment Dependency code executes with the privileges of the user installing or running the Skill. A compromised dependency could read user-accessible files, access environment variables, make network requests, modify local data, or establish persistence within that user's permission boundary. The potential impact is broad, but exploitation is conditional on compromise or unsafe ...[truncated 43 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Add a project-level `package.json` containing exact, reviewed dependency versions. 2. Generate and commit `package-lock.json`. 3. In deployment documentation, replace ad hoc installation with `npm ci`. 4. Review and pin transitive dependencies through the lockfile. 5. Run dependency auditing and software composition analysis in continuous integration. 6. Review dependency lifecycle scripts and consider installation with `--ignore-scripts` where compatible. 7. Use automated update tooling that creates reviewable pull requests rather than silently consuming latest releases. 8. Document the supported Node.js version and test the locked dependency set against it. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Rogue AgentSelf-Modification, Session Persistence
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (47)

Tool Parameter Abuse

High
Category
Tool Misuse
Content
```bash
# 删除所有历史文档
rm ~/daily-news-brief/每日新闻/*

# 禁用本地文档保存
# 编辑 config.json,设置 saveLocalDoc: false
Confidence
94% confidence
Finding
The guide provides a direct wildcard deletion command that removes all historical news documents in one step. In a quickstart context, users may paste it without understanding the scope, and shell expansion mistakes or unexpected symlinks can turn routine cleanup into significant data loss.

Missing User Warnings

High
Confidence
97% confidence
Finding
The uninstall section tells users to recursively delete configuration and data directories with `rm -rf` but gives no strong warning about permanent deletion. Because these commands remove whole directories under the user's home path and the skill path, accidental execution, path mistakes, or copy/paste errors can cause substantial data loss.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
crontab -e  # 删除相关行

# 删除配置和数据
rm -rf ~/.daily-news-brief
rm -rf ~/daily-news-brief

# 可选:删除 Skill
Confidence
92% confidence
Finding
`rm -rf ~/.daily-news-brief` recursively deletes the skill's configuration, logs, and related local state without confirmation. Even though it is framed as uninstall guidance, publishing force-delete commands in a quickstart-style document makes accidental copy/paste destruction more likely and can erase data users may wish to retain.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
crontab -e  # 删除相关行

# 删除配置和数据
rm -rf ~/.daily-news-brief
rm -rf ~/daily-news-brief

# 可选:删除 Skill
Confidence
92% confidence
Finding
`rm -rf ~/.daily-news-brief` recursively deletes the skill's configuration, logs, and related local state without confirmation. Even though it is framed as uninstall guidance, publishing force-delete commands in a quickstart-style document makes accidental copy/paste destruction more likely and can erase data users may wish to retain.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
# 删除配置和数据
rm -rf ~/.daily-news-brief
rm -rf ~/daily-news-brief

# 可选:删除 Skill
rm -rf /path/to/daily-news-brief
Confidence
94% confidence
Finding
`rm -rf ~/daily-news-brief` recursively removes the saved news archive directory from the user's home path with no confirmation. Because the skill explicitly stores generated documents there, this command can wipe the entire history of outputs and any manually added files in that tree.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
# 删除配置和数据
rm -rf ~/.daily-news-brief
rm -rf ~/daily-news-brief

# 可选:删除 Skill
rm -rf /path/to/daily-news-brief
Confidence
94% confidence
Finding
`rm -rf ~/daily-news-brief` recursively removes the saved news archive directory from the user's home path with no confirmation. Because the skill explicitly stores generated documents there, this command can wipe the entire history of outputs and any manually added files in that tree.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
rm -rf ~/daily-news-brief

# 可选:删除 Skill
rm -rf /path/to/daily-news-brief
```

## 进阶功能
Confidence
90% confidence
Finding
`rm -rf /path/to/daily-news-brief` is a destructive recursive deletion example using a placeholder absolute path. Although intended for uninstall, placeholder path commands are error-prone: users may substitute the wrong directory or execute from documentation without careful verification, causing unintended deletion of unrelated files.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
rm -rf ~/daily-news-brief

# 可选:删除 Skill
rm -rf /path/to/daily-news-brief
```

## 进阶功能
Confidence
90% confidence
Finding
`rm -rf /path/to/daily-news-brief` is a destructive recursive deletion example using a placeholder absolute path. Although intended for uninstall, placeholder path commands are error-prone: users may substitute the wrong directory or execute from documentation without careful verification, causing unintended deletion of unrelated files.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding
The declared behavior promises news aggregation, summarization, and scheduling, while the detected behavior includes local config reads/writes in the user's home directory, config backup, and push-setting changes, but apparently does not implement the core promised functionality. This mismatch is dangerous because users may authorize the skill expecting low-risk summarization while it modifies local state and messaging configuration outside that expectation.

Ae1

High
Category
analysis-evasion
Content
| **FetchNews** | 手动获取新闻、执行定时任务时 | `workflows/FetchNews.md` |
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
node tools/FetchNews.ts --test
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
node tools/FetchNews.ts --test
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Context-Inappropriate Capability

High
Confidence
97% confidence
Finding
The workflow directly edits the user's system crontab, which is a host-level persistence mechanism beyond ordinary news summarization. This can overwrite unrelated scheduled tasks, introduce lasting changes to the system, and create a persistence foothold that remains after the skill stops being used.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
read confirm

if [ "$confirm" = "yes" ]; then
  rm -rf ~/daily-news-brief/每日新闻/*
  echo "✅ 历史文档已清空"
fi
```
Confidence
99% confidence
Finding
The exact command `rm -rf ~/daily-news-brief/每日新闻/*` is destructive and relies on shell expansion against a path that may vary by environment, symlink state, or prior configuration changes. In a configuration skill, giving an agent a one-shot deletion primitive increases the chance of accidental or overbroad erasure of user data beyond what is necessary for normal operation.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
read confirm

if [ "$confirm" = "yes" ]; then
  rm -rf ~/daily-news-brief/每日新闻/*
  echo "✅ 历史文档已清空"
fi
```
Confidence
99% confidence
Finding
The exact command `rm -rf ~/daily-news-brief/每日新闻/*` is destructive and relies on shell expansion against a path that may vary by environment, symlink state, or prior configuration changes. In a configuration skill, giving an agent a one-shot deletion primitive increases the chance of accidental or overbroad erasure of user data beyond what is necessary for normal operation.

Session Persistence

Medium
Category
Rogue Agent
Content
### 步骤 1:创建配置目录

```bash
mkdir -p ~/.daily-news-brief/logs
```

### 步骤 2:创建配置文件
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.

Session Persistence

Medium
Category
Rogue Agent
Content
### 步骤 1:创建配置目录

```bash
mkdir -p ~/.daily-news-brief/logs
```

### 步骤 2:创建配置文件
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.

Session Persistence

Medium
Category
Rogue Agent
Content
编辑 crontab:

```bash
crontab -e
```

添加以下内容(每天晚上 9 点执行):
Confidence
85% 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.

Session Persistence

Medium
Category
Rogue Agent
Content
编辑 crontab:

```bash
crontab -e
```

添加以下内容(每天晚上 9 点执行):
Confidence
85% 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.

Session Persistence

Medium
Category
Rogue Agent
Content
编辑 crontab:

```bash
crontab -e
```

添加以下内容(每天晚上 9 点执行):
Confidence
85% 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.

File System Enumeration

Medium
Category
Data Exfiltration
Content
cat ~/daily-news-brief/每日新闻/$(date +%Y-%m-%d).md

# 列出所有历史文档
ls -la ~/daily-news-brief/每日新闻/
```

### 在 AI 聊天中使用
Confidence
60% confidence
Finding
Code scans file system directories looking for sensitive files. This could be reconnaissance for credential theft.

File System Enumeration

Medium
Category
Data Exfiltration
Content
cat ~/daily-news-brief/每日新闻/$(date +%Y-%m-%d).md

# 列出所有历史文档
ls -la ~/daily-news-brief/每日新闻/
```

### 在 AI 聊天中使用
Confidence
60% confidence
Finding
Code scans file system directories looking for sensitive files. This could be reconnaissance for credential theft.

Natural-Language Policy Violations

Medium
Confidence
74% confidence
Finding
The natural-language usage examples show the skill being invoked and used entirely in Chinese, while the document does not state that Chinese is optional or that the skill is intentionally limited to a Chinese-language context. Under the policy, forcing or implicitly constraining language/locale without user opt-in can be a violation unless the locale restriction is clearly documented and justified.

Missing User Warnings

Medium
Confidence
93% confidence
Finding
The guide instructs users to run a wildcard deletion command that removes all saved news documents, but it does not clearly warn that the action is destructive and irreversible. In a user-facing quickstart, omission of such warning increases the chance of accidental data loss, especially because the path is under the user's home directory and may contain accumulated history.

Lp3

Medium
Category
MCP Least Privilege
Confidence
90% confidence
Finding
The skill describes network-based news aggregation and external push delivery, but it does not declare any tool scope such as permissions or allowed-tools. That makes the skill's execution boundary unclear, increasing the chance of unintended network access or broader-than-expected capability use by the agent runtime.

Static analysis

Detected: suspicious.dangerous_exec

Shell command execution detected (child_process).

Critical
Code
suspicious.dangerous_exec
Location
tools/FetchNews.ts:103