T09 · Insecure Skill Coding Practices
- Location
scripts/p002_applicant_search.py:59- Finding
Bearer Token Exposure Through Command-Line Argument
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This skill is a disclosed PatSnap patent-data workflow with expected API use, though users should handle the PatSnap API key carefully.
Install only if you intend to use PatSnap services for patent dashboard data. Use a narrowly scoped PatSnap API key, prefer PATSNAP_API_KEY or a secret manager instead of --api-key, avoid untrusted applicant-name input unless it is validated or escaped, and verify PatSnap endpoint availability before relying on generated counts.
scripts/p002_applicant_search.py:59Bearer Token Exposure Through Command-Line Argument
scripts/p002_applicant_search.py:20PatSnap Query Injection Through Unescaped Applicant Name
The declared description promises substantial patent-data retrieval and analytics functionality tied to PatSnap APIs. The actual code chunk contains only a minimal script entry point that prints a static message when run. There is no evidence of API calls, data-layer construction, analytics computation, or dashboard-oriented processing. This is a material description-to-behavior mismatch because the implemented behavior does not meaningfully realize the declared purpose.
Without declared permissions the skill's intent is opaque and cannot be validated.
Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
## MCP and API configuration
This source package is primarily a PatSnap REST API workflow. It does not contain a README and no new setup file may be added without approval.
- Authenticate REST calls with a PatSnap Open Platform API key.
- Verify each endpoint in the current [PatSnap Developer Center](https://open.patsnap.com/devportal) before execution.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
"page": page,
"page_size": page_size
}
resp = requests.post(API_URL, headers=headers, json=payload, timeout=30)
resp.raise_for_status()
data = resp.json()
if not data.get("status"):
The instruction says to default to lang: en for the global dashboard and use other languages only in limited cases. This imposes a language preference in natural-language guidance rather than offering a neutral user choice, which can conflict with language/locale policy expectations unless the user has opted in.