Back to skill

Security audit

YTLong Daily Report

Security checks for vulnerabilities and agentic risk

Overview

This work-report skill mostly does what it says, but its command construction can let a hostile config or argument run unintended shell commands.

Review this before installing. It has no evidence of intentional theft or persistence, but it should not be run in untrusted repositories or with untrusted .reportrc.json files until the shell command construction is fixed. Expect it to generate git-based markdown reports only, not calendar or task reports, and review report contents before sharing because commit messages may contain confidential work details.

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 (1)

T09 · Insecure Skill Coding Practices

Error
Location
index.js:17
Finding

Shell Command Injection Through Repository Paths and Date Arguments

Content
View full analysis
/dev/null || echo ""`; const output = execSync(cmd, { encoding: 'utf-8' }).trim(); if (output) { output.split('\n').forEach(line => { const [hash, message, author, date] = line.split('|'); if (hash && message) { commits.push({ hash, message, author, date, repo }); } }); } } catch (e) { // 忽略错误 } } } ``` The command-line date values are accepted without validation: ```js case 'range': const fromIdx = args.indexOf('--from'); const toIdx = args.indexOf('--to'); since = fromIdx !== -1 ? args[fromIdx + 1] : today.toISOString().split('T')[0]; until = toIdx !== -1 ? args[toIdx + 1] : new Date(today.getTime() + 86400000).toISOString().split('T')[0]; break; ``` Repository paths are loaded from a working-directory configuration file and passed to the vulnerable function: ```js let config = { git: { repos: ['.'] }, output: { language: 'zh-CN' } }; const configPath = path.join(process.cwd(), '.reportrc.json'); if (fs.existsSync(configPath)) { try { config = { ...config, ...JSON.parse(fs.readFileSync(configPath, 'utf-8')) }; } catch (e) {} } // 获取提交并生成报告 const commits = getGitLogs(since, until, config.git.repos); ``` ### Technical Analysis The application constructs a shell command by directly interpolating `repo`, `since`, and `until`, then executes it through `execSync()`. These values originate from `.reportrc.json` ...[truncated 2261 chars]
Remediation
View remediation
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 (8)

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The skill declares broad report generation from git, calendar, and tasks, but the documented behavior and static finding indicate undeclared file reads and writes plus a mismatch between advertised and actual data sources. This is dangerous because users may grant trust expecting one scope of access while the skill silently accesses sensitive local repositories/configuration and stores derived reports on disk without explicit disclosure or permission expectations.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The skill handles potentially sensitive workplace data such as git history, calendar entries, and task lists, but the description does not warn users about that sensitivity. This increases the risk of unintentional exposure of confidential project names, commit contents, meeting details, and personal productivity data in generated reports or downstream storage/sharing.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The manifest describes a broader reporting skill that incorporates git commits, calendar events, and task lists. In this file, all data collection is limited to git log extraction and report formatting from commits, with no code for reading calendars or task systems.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The code builds a shell command with untrusted values from .reportrc.json (repo, since, until) and passes it to execSync. Even though repo is wrapped in double quotes, shell metacharacters such as command substitution can still be interpreted, allowing command injection and arbitrary code execution if a malicious config or arguments are supplied.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The report generator defaults language to zh-CN, and the configuration fallback later also defaults output language to zh-CN, which effectively forces a specific locale unless the user edits configuration. The policy requires offering language or locale choice or clearly justified constraints, neither of which is present here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The default configuration sets output.language to zh-CN, creating a hard-coded locale preference in natural-language behavior. Since the file does not present this as an optional user choice or a justified region-specific limitation, it falls under the language/locale policy violation category.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

This manifest file describes the skill as 'Automatically generate daily/weekly work reports from git commits' but does not specify any explicit invocation phrases, boundaries, or exclusion conditions. In a manifest context, this broad automation description could overlap with common requests about reports and lacks specificity about when the skill should activate versus not activate.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
78% confidence
Finding

The module comment says this is a 'Daily Report Generator' without qualification, which in the context of the manifest suggests broader work-report generation. The actual code only builds reports from git commit history and does not implement other expected report inputs like calendar events or task lists.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.dangerous_exec

Shell command execution detected (child_process).

Critical
Code
suspicious.dangerous_exec
Location
index.js:19