Back to skill

Security audit

Fb Page Publisher

Security checks for vulnerabilities and agentic risk

Overview

This skill does what it says for Facebook Page management, but it handles a powerful long-lived token and live publish/delete actions with too few safeguards.

Install only for a Page where you are comfortable letting an AI agent perform live public actions. Use a least-privilege Page token, keep it out of shared config files and version control, rotate it if exposed, and require human confirmation outside the skill before publish, reply, schedule, or delete actions. Prefer a reviewed lockfile and pinned npx/package versions before production use.

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)

T09 · Insecure Skill Coding Practices

Error
Location
src/fb_client.py:61
Finding
Long-Lived Facebook Access Token Transmitted in URL Query Parameters<![CDATA[ ## Vulnerability Details **File Location**: `src/fb_client.py`, lines 61–78 **Vulnerability Type**: Sensitive credential exposure through URL query parameters **Risk Level**: High ### Vulnerable Code ```python def _auth_params(self) -> dict[str, str]: return {"access_token": self.access_token} async def _request( self, method: str, endpoint: str, *, params: dict[str, Any] | None = None, data: dict[str, Any] | None = None, ) -> dict[str, Any]: merged_params = {**self._auth_params(), **(params or {})} response = await self._client.request( method, endpoint, params=merged_params, data=data, ) ``` ### Technical Analysis Every Facebook Graph API request adds the long-lived Page access token to the URL query string through the `params` argument. Sending a credential to Facebook is necessary for the declared functionality, but placing it in the query string is not the minimum-risk authentication mechanism. Although HTTPS protects the URL while it is in transit, query strings are frequently captured by HTTP client diagnostics, reverse proxies, network monitoring products, exception reports, tracing platforms, and access logs. Anyone with access to such records may recover the complete token. The destination is the official Facebook Graph API, and no covert exfiltration destination was identified. The vulnerability is the avoidable exposure surface created by the authentication mechanism. ### Attack Path 1. An operator configures the Skill with a long-lived `FB_ACCESS_TOKEN`. 2. The Skill invokes any exposed Facebook tool. 3. `_auth_params()` returns the token and `_request()` includes it in `merged_params`. 4. `httpx` constructs a request URL containing `access_token=<secret>`. 5. A proxy, diagnostic hook, tracing system, exception collector, or URL logger records the complete request URL. 6. An attacker or unauthorized log reader extracts the token. 7. The attacker submits dir ...[truncated 910 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Remove `_auth_params()` and do not place access tokens in query parameters. 2. Send the credential through an authorization header: ```python self._client = httpx.AsyncClient( base_url=BASE_URL, timeout=httpx.Timeout(30.0, connect=10.0), headers={ "User-Agent": "fb-page-publisher/1.0.0", "Authorization": f"Bearer {self.access_token}", }, ) ``` 3. Ensure HTTP debug logging, exception telemetry, and tracing systems redact `Authorization`, `access_token`, and other credential fields. 4. Store the token in a dedicated secret manager where possible, rather than a plaintext `.env` file. 5. Use a Page-scoped token with only the permissions required by enabled tools. 6. Separate read-only and write/destructive credentials if the deployment model supports doing so. 7. Rotate the current token if request URLs may already have been logged. 8. Establish periodic token rotation and immediate revocation procedures for suspected disclosure. ]]>

T08 · Insecure Dependencies

Warning
Location
pyproject.toml:9
Finding
Mutable and Unpinned Third-Party Dependency Resolution<![CDATA[ ## Vulnerability Details **File Location**: `pyproject.toml`, lines 9–13 **Additional Locations**: `README.md`, lines 21–25, 45–49, and 92–96 **Vulnerability Type**: Software supply-chain exposure through open-ended dependencies and unpinned package execution **Risk Level**: Medium ### Vulnerable Configuration ```toml dependencies = [ "mcp[cli]>=1.2.0", "httpx>=0.27.0", "python-dotenv>=1.0.0", ] ``` The documented workflows also execute packages without specifying reviewed versions: ```bash uv sync ``` ```bash npx @modelcontextprotocol/inspector uv run src/server.py ``` ```bash clawhub login clawhub validate . npx clawhub publish "D:\My_Work\Open-Claw\fb-page-publisher" --slug "fb-page-publisher" --version "1.0.0" ``` ### Technical Analysis The Python dependencies use open-ended minimum-version constraints. No dependency lockfile was present in the audited directory. Consequently, installations performed at different times can resolve to different direct and transitive dependency versions that were not represented by the audited source. The documented `npx` commands likewise omit explicit package versions. Depending on the local npm cache and package-manager behavior, they may retrieve and execute a current registry release rather than a reviewed version. This is a supply-chain hardening issue rather than evidence that any currently named dependency is malicious. The packages are not apparent typosquats, and the audit found no proof of an existing dependency compromise. The risk arises because future or compromised registry artifacts can enter the execution path without a source change to this project. ### Attack Path 1. An attacker compromises the publishing account, distribution channel, or release process of a direct or transitive dependency. 2. A malicious version is published while still satisfying an open-ended constraint, or under an unversioned package invoked through `npx`. 3. A user follows the documented setup, in ...[truncated 1161 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Generate, review, and commit a `uv.lock` file containing fully resolved direct and transitive dependency versions. 2. Require synchronized installation from the lockfile in deployment and CI workflows, using a frozen or locked mode that fails rather than updating resolution. 3. Constrain direct dependencies to reviewed release ranges or exact versions and update them through an explicit review process. 4. Pin documented `npx` packages to reviewed versions, for example: ```bash npx @modelcontextprotocol/inspector@<reviewed-version> uv run src/server.py npx clawhub@<reviewed-version> publish ... ``` 5. Prefer locally installed, lockfile-controlled JavaScript tools over dynamically resolved `npx` packages. 6. Enable automated vulnerability and dependency integrity scanning for Python and npm dependency graphs. 7. Review dependency changes, checksums, maintainers, release provenance, and transitive dependency modifications before updating lockfiles. 8. Run setup and inspection tools in an isolated environment without production Facebook credentials. 9. Where supported, disable unnecessary package lifecycle scripts and restrict outbound network access during builds. ]]>
Vulnerability Patterns
  • 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
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (21)

Credential Access

High
Category
Privilege Escalation
Content
### 2. Configure environment

```bash
cp .env.example .env
# Edit .env with your FB_PAGE_ID and FB_ACCESS_TOKEN
```
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
```bash
cp .env.example .env
# Edit .env with your FB_PAGE_ID and FB_ACCESS_TOKEN
```

### 3. Get your Facebook credentials
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding
The description says the skill manages publishing, uploads, scheduling, insights, and comments, but it also supports irreversible post deletion. This mismatch is dangerous because users and reviewers may authorize the skill expecting content management, not destructive actions that can remove public posts from a Facebook Page.

Credential Access

High
Category
Privilege Escalation
Content
## Required Environment Variables

- `FB_PAGE_ID` — The numeric ID of your Facebook Page
- `FB_ACCESS_TOKEN` — A long-lived (non-expiring) Facebook Page Access Token with permissions: pages_manage_posts, pages_read_engagement, pages_manage_engagement

## create_post
Create and immediately publish a text post to the Facebook Page.
Confidence
70% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
## Required Environment Variables

- `FB_PAGE_ID` — The numeric ID of your Facebook Page
- `FB_ACCESS_TOKEN` — A long-lived (non-expiring) Facebook Page Access Token with permissions: pages_manage_posts, pages_read_engagement, pages_manage_engagement

## create_post
Create and immediately publish a text post to the Facebook Page.
Confidence
70% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
## Required Environment Variables

- `FB_PAGE_ID` — The numeric ID of your Facebook Page
- `FB_ACCESS_TOKEN` — A long-lived (non-expiring) Facebook Page Access Token with permissions: pages_manage_posts, pages_read_engagement, pages_manage_engagement

## create_post
Create and immediately publish a text post to the Facebook Page.
Confidence
70% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Missing User Warnings

Medium
Confidence
90% confidence
Finding
The README advertises account-affecting capabilities such as publishing, deleting posts, and replying to comments without any caution about authorization scope, review, or operational safeguards. In an AI-agent context, this increases the risk of accidental or unauthorized destructive actions because users are not warned that natural-language requests can directly modify a public Facebook Page.

Missing User Warnings

Medium
Confidence
96% confidence
Finding
The README instructs users to copy secrets into `.env` and set `FB_ACCESS_TOKEN` without warning that the token is sensitive and grants page-management privileges. In this skill's context, the token can enable posting, deleting content, and moderating comments on a real Facebook Page, so careless handling materially raises account compromise risk.

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.

Missing User Warnings

Medium
Confidence
97% confidence
Finding
The Claude Desktop configuration example includes `FB_ACCESS_TOKEN` directly in local config without a warning about plaintext secret exposure. Because this token enables management of a Facebook Page, storing it in an easily copied config file can lead to credential theft, unauthorized posting/deletion, and abuse by other local tools or users with access to the machine.

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.

Lp3

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding
The skill declares access to environment variables and external network use but does not define an explicit tool scope such as permissions or allowed-tools. That omission weakens reviewability and policy enforcement, making it easier for a skill with write access to a Facebook Page and a page access token to perform sensitive actions without clear user-facing guardrails.

Missing User Warnings

Medium
Confidence
90% confidence
Finding
The skill documentation does not clearly warn that actions like create_post, upload_photo_post, reply_to_comment, schedule_post, and delete_post trigger immediate external network operations against a live Facebook Page. In this context, that increases the risk of unintended real-world actions, accidental publication, or reputation damage caused by ambiguous prompts or mistaken agent behavior.

Description-Behavior Mismatch

Medium
Confidence
95% confidence
Finding
The client exposes a post deletion capability even though the declared skill description only mentions publishing, uploading, scheduling, reading insights, and managing comments. This creates a scope mismatch that can enable unexpected destructive actions by downstream agents or users who rely on the manifest to understand the skill's permissions and behavior.

Missing User Warnings

Medium
Confidence
92% confidence
Finding
delete_post performs an irreversible destructive action with no built-in confirmation, soft-delete, or additional safety control. In an agent setting, prompt mistakes, ambiguous instructions, or tool misuse could directly delete Facebook content without the operator realizing the action is final.

Description-Behavior Mismatch

Medium
Confidence
97% confidence
Finding
The server exposes a destructive delete_post tool even though the stated skill description only covers publishing, scheduling, insights, and comment management. This creates a capability/expectation mismatch that can lead users or downstream agents to invoke irreversible deletion without realizing the skill has broader privileges, increasing the risk of accidental or unauthorized content removal.

Description-Behavior Mismatch

Medium
Confidence
91% confidence
Finding
The manifest description lists publishing posts, uploading photos, scheduling content, reading insights, and managing comments, but does not mention deleting page posts. The code exposes a delete_post tool that removes existing content, which is a materially different destructive capability beyond the described behavior.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The delete_post tool performs an irreversible destructive action immediately with no confirmation, safeguard, or requirement for an explicit second step. In an agent setting, ambiguous prompts, prompt injection, or operator error could cause unintended deletion of live Facebook Page content.

Unverifiable Dependency: mcp has 12 known advisory(ies) (CVE-2025-53366 (MCP Python SDK vulnerability in the FastMCP Server causes validation error, lead); CVE-2025-66416 (Model Context Protocol (MCP) Python SDK does not enable DNS rebinding protection); CVE-2026-52870 (MCP Python SDK: Experimental task handlers allow any client to access and cancel) +9 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
95% confidence
Finding
The dependency on `mcp[cli]` is only lower-bounded (`>=1.2.0`) rather than pinned to a known-safe version, so builds may resolve to releases with known vulnerabilities or future vulnerable releases. This is more concerning in this skill because `mcp` is the core server framework, and flaws there could affect network exposure, request validation, or client authorization across the whole skill.

Unverifiable Dependency: httpx has 2 known advisory(ies) (CVE-2021-41945 (Improper Input Validation in httpx); CVE-2021-41945 (Encode OSS httpx <=1.0.0.beta0 is affected by improper input validation in `http)), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
88% confidence
Finding
The `httpx` dependency is not pinned to an exact version, making it impossible to verify from the manifest alone whether an affected release could be installed. In this skill, `httpx` will likely handle outbound Graph API requests, so input-validation or protocol-handling issues in the HTTP client could expose request integrity or reliability risks, though the impact is somewhat limited by its client-side role.

Unverifiable Dependency: python-dotenv has 2 known advisory(ies) (CVE-2026-28684 (python-dotenv: Symlink following in set_key allows arbitrary file overwrite via ); CVE-2026-28684 (python-dotenv reads key-value pairs from a .env file and can set them as environ)), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
84% confidence
Finding
The `python-dotenv` package is also only minimally constrained, so an install may select a version affected by known file-handling issues. In this context the danger depends on whether the skill writes `.env` files or processes attacker-influenced paths; from this manifest alone the exposure appears limited, but using an unverifiable version still creates unnecessary supply-chain risk.

Static analysis

No suspicious patterns detected.