Back to skill

Security audit

Companies House API - UK Company Search, Officers, Filings

Security checks for vulnerabilities and agentic risk

Overview

This skill is a straightforward guide for using Scavio's Companies House API, with expected API-key and network use plus a modest caution around optional SDK installation.

Install only if you are comfortable sending queries through Scavio using your SCAVIO_API_KEY and spending Scavio credits. For SDK use, prefer an isolated virtual environment or container, verify the package source where practical, and keep the API key out of source control.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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)

T08 · Insecure Dependencies

Warning
Location
SKILL.md:222
Finding
Third-Party SDK Installation Without Integrity Verification## Vulnerability Details **File Location**: `SKILL.md`, lines 222-237 **Vulnerability Type**: `T08: Insecure Dependencies` **Risk Level**: Medium ### Vulnerable Code ```bash pip install scavio==0.15.0 ``` ```bash npm install scavio@0.15.0 ``` ### Technical Analysis The Skill recommends installing third-party Scavio SDK packages directly from public package registries. Although both dependencies are pinned to version `0.15.0`, the instructions provide no cryptographic hashes, lockfiles, package signatures, verified source references, or other integrity controls. Version pinning prevents unintended upgrades but does not protect users if the specified release, package registry, publisher account, or distribution artifact is compromised. The npm installation process may also execute package lifecycle scripts. A malicious installation script could run before the package is used or reviewed. No evidence in the audited file establishes that these packages are currently malicious. The risk arises from executing externally maintained software without sufficient integrity verification. ### Attack Path 1. An attacker compromises the package publisher account, registry infrastructure, or the referenced package release. 2. The attacker places malicious code or installation hooks in the distributed package. 3. A user or agent follows the installation command from `SKILL.md`. 4. The package manager downloads and installs the unverified artifact. 5. Malicious installation or runtime code executes with the permissions of the user running the package manager. 6. The code could inspect environment variables, including `SCAVIO_API_KEY`, access user-readable files, alter the project environment, or initiate unauthorized network connections. ### Impact Assessment Exploitation could provide arbitrary code execution with the privileges of the installing user. The accessible scope may include the project workspace, user-readable f ...[truncated 495 chars]
Remediation
## Remediation Suggestions - Publish and verify cryptographic hashes for the exact Python distribution artifacts, and require hash checking during installation, such as with `pip --require-hashes`. - Supply reviewed lockfiles that pin all direct and transitive dependencies. - Document the authoritative source repositories and package publisher identities so users can verify package provenance. - Use package signatures or trusted provenance attestations where supported. - For npm, review lifecycle scripts and use `npm install --ignore-scripts` when installation scripts are not required. - Install dependencies inside an isolated virtual environment, container, or sandbox running with least privilege. - Avoid exposing unrelated secrets to the installation environment. Provide `SCAVIO_API_KEY` only at runtime and only to the process that requires it. - Add dependency scanning and software-composition analysis to detect known vulnerabilities or unexpected package changes. - Consider documenting a direct HTTPS request workflow as the default and presenting SDK installation only as an optional, separately reviewed integration.
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep

Static analysis

Detected: suspicious.exposed_secret_literal

File appears to expose a hardcoded API secret or token.

Critical
Code
suspicious.exposed_secret_literal
Location
SKILL.md:38