T09 · Insecure Skill Coding Practices
- Location
test-alpha.js:9- Finding
Hardcoded Alpha Vantage API Credential
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill mostly matches its finance-data purpose, but it needs review because it ships a hardcoded Alpha Vantage API key and has weak input controls around outbound market-data requests.
Review before installing. Rotate or remove the embedded Alpha Vantage key, prefer environment-provided credentials only, validate and encode ticker/indicator parameters, set batch and news limits, and present technical/sentiment outputs as informational rather than investment advice.
test-alpha.js:9Hardcoded Alpha Vantage API Credential
src/api/AlphaVantage.js:30Query-Parameter Injection in Alpha Vantage Requests
src/modules/Quote.js:58Unbounded Concurrent Quote Requests
src/modules/News.js:18Unbounded News Result Limit
src/api/APIManager.js:101Request Timeout Does Not Cancel Underlying Network Operations
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
chmod 755 src/ chmod 644 src/*.js chmod 600 .env # If exists
### 5. Network Security
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
chmod 755 src/ chmod 644 src/*.js chmod 600 .env # If exists
### 5. Network Security
Undeclared news aggregation, sentiment analysis, telemetry, caching statistics, and technical indicator testing indicate a broader operational footprint than the skill description suggests. In this context, the finance domain does not make the mismatch harmless; instead it increases risk because users may rely on the skill for data provenance and narrowly scoped market-data access.
Undeclared news aggregation, sentiment analysis, telemetry, caching statistics, and technical indicator testing indicate a broader operational footprint than the skill description suggests. In this context, the finance domain does not make the mismatch harmless; instead it increases risk because users may rely on the skill for data provenance and narrowly scoped market-data access.
Undeclared news aggregation, sentiment analysis, telemetry, caching statistics, and technical indicator testing indicate a broader operational footprint than the skill description suggests. In this context, the finance domain does not make the mismatch harmless; instead it increases risk because users may rely on the skill for data provenance and narrowly scoped market-data access.
Undeclared news aggregation, sentiment analysis, telemetry, caching statistics, and technical indicator testing indicate a broader operational footprint than the skill description suggests. In this context, the finance domain does not make the mismatch harmless; instead it increases risk because users may rely on the skill for data provenance and narrowly scoped market-data access.
Undeclared news aggregation, sentiment analysis, telemetry, caching statistics, and technical indicator testing indicate a broader operational footprint than the skill description suggests. In this context, the finance domain does not make the mismatch harmless; instead it increases risk because users may rely on the skill for data provenance and narrowly scoped market-data access.
Undeclared news aggregation, sentiment analysis, telemetry, caching statistics, and technical indicator testing indicate a broader operational footprint than the skill description suggests. In this context, the finance domain does not make the mismatch harmless; instead it increases risk because users may rely on the skill for data provenance and narrowly scoped market-data access.
Undeclared news aggregation, sentiment analysis, telemetry, caching statistics, and technical indicator testing indicate a broader operational footprint than the skill description suggests. In this context, the finance domain does not make the mismatch harmless; instead it increases risk because users may rely on the skill for data provenance and narrowly scoped market-data access.
The manifest narrowly describes the skill as a Yahoo Finance API integration, but this file is explicitly an Alpha Vantage API module and all requests are sent to alphavantage.co. That is a semantic mismatch in provider behavior, not just an implementation detail, because the skill claims one external data source while actually using another.
The README explicitly documents technical indicators that produce BUY/SELL-style recommendations with confidence scores, but it does not prominently warn users that these outputs are not financial advice and may be inaccurate or unsuitable for trading decisions. In an agent skill context, this increases the chance that users treat generated signals as authoritative, which can lead to harmful financial decisions.
The README presents sentiment analysis as bullish/bearish market signals and labels like POSITIVE, NEGATIVE, and BULLISH without a clear warning that sentiment models can be noisy, biased, or wrong. Because this is packaged as an OpenClaw skill for conversational use, users may over-trust these labels as actionable investment guidance rather than heuristic summaries.
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
# Recommended permissions
chmod 755 src/
chmod 644 src/*.js
chmod 600 .env # If exists
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
# Recommended permissions
chmod 755 src/
chmod 644 src/*.js
chmod 600 .env # If exists
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
chmod 755 src/ chmod 644 src/*.js chmod 600 .env # If exists
### 5. Network Security
The skill declares network access and environment-variable usage in prose, but it does not define a formal tool scope such as explicit permissions or allowed-tools in the metadata. That creates an authorization gap where the runtime or reviewer cannot reliably enforce or verify what capabilities the skill should have, increasing the risk of unnoticed outbound requests or secret access.
The file's docstring, comments, and console messages are entirely in Chinese, which imposes a specific language on users running the script. Under the policy, locale or language restrictions should either provide user opt-in or be clearly documented as region-specific and justified.
The documentation states that requests automatically fail over to Alpha Vantage and that successful responses are cached, but it does not clearly warn users that ticker queries and related market-request metadata may be transmitted to a third-party provider and stored locally or in memory. In a finance-related skill, query content can reveal user interests, trading research, or proprietary watchlists, so silent provider switching and caching can create privacy, compliance, and data-handling risks.
The documentation states that the system will automatically fail over to Alpha Vantage and that the user will be unaware of the switch, but it does not disclose that user requests and queried symbols may be sent to a different third-party provider. This creates a transparency and privacy issue because operators or end users may assume data stays with Yahoo Finance when in fact requests may be routed elsewhere under failure or rate-limit conditions.
This code includes natural-language documentation and runtime log/error strings in Chinese, which effectively imposes a specific language on users and maintainers. The file does not indicate that the skill is region-specific or provide any opt-in or localization mechanism, so it may violate language/locale policy expectations.
This JavaScript file contains natural-language comments and returned message strings exclusively in Chinese, such as the module description and success/error messages. Under the policy, forcing a specific language without opt-in is a locale/language policy violation unless the constraint is explicitly documented and justified, which is not present here.
The manifest describes a Yahoo Finance integration for retrieving market data, but this file implements a separate Alpha Vantage provider and pulls credentials from process environment state. Accessing environment variables for third-party credentials is a broader capability than the stated user-facing purpose and is not implied by the manifest description alone.
The constructor sets lang to zh-CN by default, which imposes a specific language/locale choice when the caller does not explicitly provide one. This is a natural-language policy concern because the file does not indicate user opt-in or a documented region-specific justification for forcing Chinese as the default language.
Comments and the returned success message are written in Chinese, including the user-facing string at L061. The file does not indicate that the user can choose a language or that the locale restriction is intentional and justified, which can violate language/locale policy expectations.
The constructor sets lang to zh-CN by default, which imposes a specific language preference in the skill behavior. This is a natural-language/locale policy concern because the file does not show an explicit user choice, opt-in, or justification for forcing Chinese as the default locale.
Detected: suspicious.env_credential_access, suspicious.exposed_secret_literal