Back to skill

Security audit

Lark

Security checks for vulnerabilities and agentic risk

Overview

This appears to be a real Feishu/Lark integration, but it needs Review because setup runs mutable npm code with app secrets and the instructions enable broad workplace read, write, and delete actions without strong guardrails.

Install only if you trust the Lark MCP package and need broad Feishu/Lark automation. Pin and review the MCP package version before use, avoid putting app secrets on the command line, grant only the Lark scopes needed for your workflow, and require explicit user confirmation before destructive actions or access to recordings, transcripts, approvals, and private documents.

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

T08 · Insecure Dependencies

Error
Location
SKILL.md:23
Finding

Unpinned npm Package Is Downloaded and Executed Automatically

Content
View full analysis
Remediation
View remediation
mcp ``` 2. Prefer installing through a project manifest and lockfile rather than resolving the package dynamically during every invocation. 3. Verify package integrity using the package manager's integrity metadata or a separately published cryptographic checksum. 4. Document the expected npm publisher, repository, version, and release checksum so users can verify provenance. 5. Remove automatic confirmation where practical and explain that the command downloads and executes third-party code. 6. Run the MCP server under a dedicated, minimally privileged operating-system account or container. 7. Restrict the Lark application to only the API scopes required for the intended deployment. 8. Review new package versions before updating the pinned version. ]]>

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:32
Finding

Lark Application Secret Is Passed Through Process Command-Line Arguments

Content
View full analysis
Setup: `npx -y @larksuiteoapi/lark-mcp mcp -a -s ` > For user-identity APIs (useUAT): first run `npx -y @larksuiteoapi/lark-mcp login -a -s ` ``` An environment-variable variant that still expands the secret into the process argument vector also appears at `SKILL.md:26`: ```text npx -y @larksuiteoapi/lark-mcp mcp -a $LARK_APP_ID -s $LARK_APP_SECRET ``` ### Technical Analysis The instructions supply the application secret through the `-s` command-line option. Shell expansion of `$LARK_APP_SECRET` does not prevent exposure: the expanded value is placed in the child process's argument vector. Depending on the operating system and deployment environment, process arguments may be observable through process-listing utilities, process inspection interfaces, monitoring agents, crash reports, audit logs, orchestration metadata, or diagnostic tooling. Entering a literal secret can additionally expose it through shell history. This exposure is not an unrelated exfiltration channel—the secret is required to authenticate the Lark MCP integration—but the documented transport mechanism unnecessarily increases local disclosure risk. ### Attack Path 1. An administrator starts the MCP server or login flow using the documented command. 2. The shell expands the secret into the command's argument vector, or a literal secret is recorded in shell history. 3. Another local user, monitoring component, support bundle, audit system, or diagnostic tool records or reads the process arguments or command history. 4. The observer extracts the Lark application secret. 5. The observer uses the application identifier and secret to authenticate as the Lark application. 6. The observer accesses APIs and organizational data allowed by th ...[truncated 733 chars]
Remediation
View remediation
mcp ``` The application itself must read these variables; the command must not pass `$LARK_APP_SECRET` as an argument. 3. Warn users never to substitute a literal secret into commands that may be retained in shell history. 4. Restrict secret-containing files to the service account, such as mode `0600` on Unix-like systems. 5. Configure monitoring, audit, and diagnostic systems to redact Lark credentials. 6. Rotate the application secret if it has previously appeared in process captures, logs, support bundles, or command history. 7. Apply least-privilege Lark scopes so credential compromise does not expose the complete set of capabilities documented by the Skill. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (9)

Rp1

Medium
Category
MCP Rug Pull
Confidence
97% confidence
Finding

The skill instructs users to launch the MCP server via an unpinned npm package using npx -y @larksuiteoapi/lark-mcp, which fetches the latest published code at runtime. Because this command is paired with app credentials (-a and -s), a compromised or malicious upstream release could immediately gain access to sensitive secrets and the user's Feishu/Lark environment.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
97% confidence
Finding

This line again tells the user to execute an unpinned npx package directly from the npm registry. In this context the command is used for authentication/login, so a supply-chain compromise could capture app credentials or user access tokens and enable unauthorized access to messages, docs, calendars, and other enterprise data.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
97% confidence
Finding

The skill recommends enabling additional VC and Minutes scopes through the same unpinned npx package invocation, expanding the reachable privilege set while still trusting whatever version is latest. If the package or dependency chain were hijacked, the attacker would gain access not only to chat and docs but also meeting reservations, recordings, and transcripts.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

Several examples assume Chinese locale conventions, including zh_cn content structures, Asia/Shanghai timezone values, and approval locale parameters set to zh-CN. Because the file does not explicitly offer language or locale choice in those examples, it risks forcing a specific locale contrary to the policy on user opt-in.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The skill encourages reading messages, user profiles, calendars, documents, approvals, meeting recordings, and minutes transcripts without prominent privacy or data-minimization guidance. In a workplace integration, this can normalize broad access to sensitive organizational and personal data and increase the chance of over-collection or inappropriate disclosure.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill documents many destructive operations—deleting chats, files, records, tasks, reservations, and ending meetings—without requiring confirmation language or warning about irreversibility. In an agentic context, that omission raises the risk of accidental or prompt-induced destructive actions against real organizational resources.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
80% 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 · SKILL.md (reported line 1085)May include surrounding context.

useUAT: true

text

### Add Task to a Task List
**Tool**: `mcp__lark-mcp__task.v2.task.addTasklist`
```yaml
path:

Rp1

Medium
Category
MCP Rug Pull
Confidence
96% confidence
Finding

The troubleshooting guidance repeats an unpinned npx execution path, reinforcing insecure operational practice. Repetition increases the chance users will copy-paste the command during setup or incident response, potentially exposing credentials to a compromised upstream package when they are under pressure and less likely to verify provenance.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
96% confidence
Finding

This login refresh instruction again invokes an unpinned package while handling user access tokens, creating a direct supply-chain path to token theft or session abuse. Because the skill targets broad enterprise collaboration data, stolen tokens could enable significant lateral access across chats, drive files, tasks, approvals, and meeting content.

Content

No source excerpt is available for this finding.