Back to skill

Security audit

Playwright Scraper CN

Security checks for vulnerabilities and agentic risk

Overview

This scraping skill mostly matches its purpose, but it includes undocumented login/SMS automation and unsafe browser settings that need review before use.

Install only if you trust the publisher and will run it in a restricted environment. Use it only on sites you are authorized to access, avoid scraping sensitive pages unless needed, treat screenshots/HTML/cookies as secrets, and do not run the Xianyu login script unless the phone number is yours and you explicitly intend to request an SMS code. Prefer container or network isolation for browser runs, and pin or review any external skill or dependency before installing.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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
Findings (5)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/xianyu-login.js:3
Finding

Undocumented Hard-Coded Phone Number Submitted Through an SMS Authentication Flow

Content
View full analysis
Remediation
View remediation

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/xianyu-stealth.js:12
Finding

Chromium Sandbox and Web Security Boundaries Are Disabled for Untrusted Pages

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/playwright-simple.js:11
Finding

Unrestricted URL Navigation Enables Server-Side Request Forgery and Internal Network Access

Content
View full analysis
'); process.exit(1); } // ... const browser = await chromium.launch({ headless: process.env.HEADLESS !== 'false' }); const page = await browser.newPage(); console.log(`📱 導航到: ${url}`); await page.goto(url, { waitUntil: 'domcontentloaded' }); ``` Equivalent unrestricted navigation also occurs in: ```javascript // scripts/playwright-stealth.js const url = process.argv[2]; const response = await page.goto(url, { waitUntil: 'domcontentloaded', timeout: 30000, }); ``` ### Technical Analysis The scripts accept an arbitrary URL and navigate to it without validating: - The URL scheme. - The initial hostname and resolved IP addresses. - Loopback, private, link-local, multicast, or reserved address ranges. - Cloud instance metadata endpoints. - Redirect destinations. - DNS rebinding or resolution changes. When this Skill runs inside an Agent, server, CI environment, or workstation, the browser may reach services that are inaccessible to the external requester. The scraper then returns page text to standard output or stores screenshots and HTML, creating an SSRF-style read channel. Browser navigation can also generate secondary requests for scripts, images, frames, and other resources. Consequently, checking only the initial URL string would not fully address the issue. ### Attack Path 1. An attacker supplies a URL targeting a local service, private network host, or cloud metadata endpoint. 2. The Agent invokes the scraper with that URL. 3. Chromium sends the request from the trusted host's network context. 4. The internal service returns information unavailable to the attacker directly. 5. The script extracts bod ...[truncated 819 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
package-lock.json:18
Finding

Dependency Archive Is Retrieved Through a Cleartext HTTP Registry Mirror

Content
View full analysis
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
SKILL.md:87
Finding

Documentation Instructs Users to Install and Execute an Unpinned External Skill

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (54)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The declared description emphasizes anti-bot protection and suitability for complex sites with scraping defenses. The code does not implement any anti-bot evasion measures such as stealth plugins, header/cookie management, proxy rotation, challenge solving, session handling, or browser fingerprint masking. In fact, the code comments explicitly describe it as a 'simple' scraper for general dynamic sites with no anti-scraping protection. It only performs basic navigation, a fixed delay, content extraction, and optional screenshot capture. Therefore the description materially overstates the capability and intended use compared with the actual behavior.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The declared description says this is a Playwright-based web scraping skill with anti-bot protection. While the code does use Playwright and includes anti-detection measures, its primary behavior is not scraping content. Instead, it automates a login process on Xianyu/Goofish: visiting the site, clicking a login button, filling a phone number, attempting to send an SMS verification code, taking screenshots, and displaying page text. These are materially different capabilities from scraping and involve account-authentication actions that were not declared. Therefore the description does not accurately represent the code's actual behavior.

Content

No source excerpt is available for this finding.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
| **Cloudflare Protected** | High | **Playwright Stealth** ⭐ | `scripts/playwright-stealth.js` |

Missing User Warnings

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

The README suggests manually logging in and exporting cookies without any safety guidance for handling authentication material. Exported cookies can enable session hijacking or unauthorized account access if copied, logged, shared, or stored insecurely, and this risk is especially relevant in a scraping skill that may target authenticated sessions.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

This script goes beyond ordinary scraping and automates an account login flow, including entering a hardcoded phone number and triggering SMS verification. In a scraping skill, that creates credential-handling and account-access capabilities that can be misused for unauthorized access attempts, account takeover workflows, or deceptive collection of one-time codes.

Content

No source excerpt is available for this finding.

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
95% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · test.sh (reported line 43)May include surrounding context.

sh
echo ""

# 清理
rm -f /tmp/test-*.json screenshot-*.png

echo "✅ 所有測試通過!"

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The README explicitly promotes anti-bot evasion techniques and page data capture without any warning about authorization, terms-of-service, privacy, or sensitive-data handling. In a scraping skill, that omission increases the chance of misuse against protected sites and unsafe retention of scraped HTML or screenshots that may contain personal or confidential information.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The README explicitly promotes stealth scraping, hiding automation fingerprints, screenshot capture, and HTML saving, but provides no warning about authorization, privacy, or lawful data handling. In a scraping skill, that omission increases the likelihood of misuse against protected sites or collection of sensitive content, especially because the text frames bypassing anti-bot controls as a recommended workflow.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
87% confidence
Finding

The skill documents executable commands that use network access and environment variables, but it does not declare any explicit tool scope or permissions metadata. In a skill ecosystem, missing scope declarations weakens reviewability and can let users or orchestration systems invoke higher-risk behaviors without clear consent boundaries.

Content

No source excerpt is available for this finding.