Back to skill

Security audit

fail2ban Reporter

Security checks for vulnerabilities and agentic risk

Overview

The skill is a real fail2ban-to-AbuseIPDB integration, but its privileged persistent installer has a command-injection risk and changes system security configuration.

Review the scripts before installing, back up fail2ban configuration, and do not run install.sh from an untrusted or strangely named directory until the action path is safely fixed. Install only if you are comfortable granting root-level access, restarting fail2ban, and automatically sending banned IPs plus report comments to AbuseIPDB.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/install.sh:7
Finding

Privileged Command Injection Through an Unquoted Installation Path

Content
View full analysis
/dev/null; then echo "❌ fail2ban not installed. Run: sudo apt install -y fail2ban" exit 1 fi if ! command -v jq &>/dev/null; then echo "❌ jq not installed. Run: sudo apt install -y jq" exit 1 fi # Verify API key exists API_KEY="${ABUSEIPDB_KEY:-$(pass show abuseipdb/api-key 2>/dev/null || echo "")}" if [ -z "$API_KEY" ]; then echo "❌ No AbuseIPDB API key found." echo " Get one free at: https://www.abuseipdb.com/account/api" echo " Then run: pass insert abuseipdb/api-key" exit 1 fi # Create fail2ban action cat > /etc/fail2ban/action.d/abuseipdb.conf << CONF [Definition] actionban = bash $SCRIPT_DIR/report-single.sh "SSH brute-force on jail (fail2ban auto-report)" [Init] CONF ``` ### Technical Analysis The script determines `SCRIPT_DIR` from the directory in which the installer is located and directly interpolates that value into an `actionban` command: ```bash actionban = bash $SCRIPT_DIR/report-single.sh ... ``` Although the path is quoted while it is calculated, it is not quoted or safely escaped when written into the fail2ban action configuration. Fail2ban action commands are ultimately interpreted as shell commands. Consequently, shell metacharacters, whitespace, command separators, or substitutions contained in the project directory name can change the meaning of the generated command. For example, placing the project in a directory whose name contains a sequence such as `; id; #` causes that sequence to be preserved in `/etc/fail2ban/action.d/abuseipdb.conf`. When fail2ban subsequently executes the action, the injected `id` command is treated as a separate shell command rather than as part of the scr ...[truncated 1915 chars]
Remediation
View remediation
"SSH brute-force on jail (fail2ban auto-report)" ``` 3. **Quote and escape any path that must remain dynamic.** Use a shell-escaping routine rather than ordinary double quotes alone. Fail2ban placeholder processing must also be considered when generating the final command. 4. **Reject unsafe installation paths as defense in depth.** Abort if `SCRIPT_DIR` contains characters outside a conservative allowlist, such as letters, digits, underscores, hyphens, periods, and path separators. 5. **Verify ownership and permissions before installation.** Refuse to install executable files from directories writable by unprivileged users. 6. **Write configuration atomically and validate it before restarting fail2ban.** Create the configuration with restrictive permissions, run fail2ban configuration validation, and only then replace the active file and restart the service. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (33)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The skill description focuses on monitoring and reporting, yet the available interface includes uninstall/removal operations, modification of fail2ban configuration, and service restarts. In a security-administration context, hidden teardown or reconfiguration capability is dangerous because it can disable protections or alter incident response behavior under the guise of a reporting utility.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
92% confidence
Finding

The skill description focuses on monitoring and reporting, yet the available interface includes uninstall/removal operations, modification of fail2ban configuration, and service restarts. In a security-administration context, hidden teardown or reconfiguration capability is dangerous because it can disable protections or alter incident response behavior under the guise of a reporting utility.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
93% confidence
Finding

The skill description focuses on monitoring and reporting, yet the available interface includes uninstall/removal operations, modification of fail2ban configuration, and service restarts. In a security-administration context, hidden teardown or reconfiguration capability is dangerous because it can disable protections or alter incident response behavior under the guise of a reporting utility.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The skill description focuses on monitoring and reporting, yet the available interface includes uninstall/removal operations, modification of fail2ban configuration, and service restarts. In a security-administration context, hidden teardown or reconfiguration capability is dangerous because it can disable protections or alter incident response behavior under the guise of a reporting utility.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill description focuses on monitoring and reporting, yet the available interface includes uninstall/removal operations, modification of fail2ban configuration, and service restarts. In a security-administration context, hidden teardown or reconfiguration capability is dangerous because it can disable protections or alter incident response behavior under the guise of a reporting utility.

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 · scripts/uninstall.sh (reported line 8)May include surrounding context.

sh
set -euo pipefail

# Remove action file
rm -f /etc/fail2ban/action.d/abuseipdb.conf

# Remove action from jail config
if [ -f /etc/fail2ban/jail.local ]; then

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The README encourages automatic reporting of banned IPs to a third-party service without clearly warning that IP addresses, timestamps, and security-event context will be transmitted externally. This can create privacy, compliance, and operational risks because users may enable data sharing without informed consent or understanding of what leaves their system.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The auto-reporting installation instructions use persistent automation to continuously exfiltrate future ban events to an external service, but the README does not clearly warn that enabling it changes ongoing system behavior. Users may run the install step with elevated privileges without realizing they are setting up continuous outbound reporting of security telemetry.

Content

No source excerpt is available for this finding.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
80% confidence
Finding

The README instructs users to execute an installation script with sudo, which is inherently risky because it grants the script full system privileges. In a security automation skill that modifies fail2ban integration and reporting behavior, this increases the blast radius of any hidden or unintended actions in the install script.

Content

Scanner excerpt · README.md (reported line 45)May include surrounding context.

4. Enable auto-reporting (optional)

bash
sudo bash scripts/install.sh

Now every new fail2ban ban automatically reports to AbuseIPDB.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · README.md (reported line 70)May include surrounding context.

Remove auto-reporting

bash
sudo bash scripts/uninstall.sh

Clawdbot Skill

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
96% confidence
Finding

The skill invokes shell scripts that can install, uninstall, and run system-level operations, but the manifest declares no tool scope or permission boundaries. This increases the chance of unintended or over-broad execution because consumers of the skill are not clearly warned that shell access and system modification are required.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The invocation wording is broad enough that the skill could be selected in general server-security situations where its shell-based install or configuration actions are unnecessary or risky. Over-broad triggering increases the chance of accidental execution of privileged workflows in the wrong context.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The document instructs users to submit banned IPs and comments to AbuseIPDB, which is a third-party service, but does not explicitly warn that operational security data will be transmitted externally. In a security-monitoring skill, this can cause unintentional disclosure of IP addresses, attack metadata, and possibly environment-specific comments to an external party without informed consent or policy review.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
80% confidence
Finding

The matched URL is part of the same report example that sends data to AbuseIPDB, so it represents a real outbound transmission path rather than a harmless mention. Because this skill's purpose is to auto-report fail2ban bans, the context increases the likelihood that users will operationalize this behavior and transmit data externally without considering privacy, legal, or policy implications.

Content

Scanner excerpt · references/abuseipdb-api.md (reported line 38)May include surrounding context.

Example

bash
curl -s https://api.abuseipdb.com/api/v2/report \
  -H "Key: $ABUSEIPDB_KEY" \
  -H "Accept: application/json" \
  --data-urlencode "ip=1.2.3.4" \

External Transmission

Medium
Category
Data Exfiltration
Confidence
80% confidence
Finding

The matched URL is part of the same report example that sends data to AbuseIPDB, so it represents a real outbound transmission path rather than a harmless mention. Because this skill's purpose is to auto-report fail2ban bans, the context increases the likelihood that users will operationalize this behavior and transmit data externally without considering privacy, legal, or policy implications.

Content

Scanner excerpt · references/abuseipdb-api.md (reported line 38)May include surrounding context.

Example

bash
curl -s https://api.abuseipdb.com/api/v2/report \
  -H "Key: $ABUSEIPDB_KEY" \
  -H "Accept: application/json" \
  --data-urlencode "ip=1.2.3.4" \

External Transmission

Medium
Category
Data Exfiltration
Confidence
67% confidence
Finding

This example queries AbuseIPDB about an IP address, which still transmits the queried IP to a third-party service. Although lower risk than the report endpoint because it does not submit abuse comments, it still leaks investigative or operational context about which IPs the user is monitoring.

Content

Scanner excerpt · references/abuseipdb-api.md (reported line 60)May include surrounding context.

Example

bash
curl -s "https://api.abuseipdb.com/api/v2/check?ipAddress=1.2.3.4&maxAgeInDays=90" \
  -H "Key: $ABUSEIPDB_KEY" \
  -H "Accept: application/json"

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · references/abuseipdb-api.md (reported line 3)May include surrounding context.

md
exit 1
fi

RESPONSE=$(curl -sG "https://api.abuseipdb.com/api/v2/check" \
  -H "Key: $API_KEY" \
  -H "Accept: application/json" \
  --data-urlencode "ipAddress=$IP" \

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/check-ip.sh (reported line 15)May include surrounding context.

sh
exit 1
fi

RESPONSE=$(curl -sG "https://api.abuseipdb.com/api/v2/check" \
  -H "Key: $API_KEY" \
  -H "Accept: application/json" \
  --data-urlencode "ipAddress=$IP" \

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/report-single.sh (reported line 20)May include surrounding context.

sh
exit 1
fi

RESPONSE=$(curl -sG "https://api.abuseipdb.com/api/v2/check" \
  -H "Key: $API_KEY" \
  -H "Accept: application/json" \
  --data-urlencode "ipAddress=$IP" \

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/check-ip.sh (reported line 15)May include surrounding context.

sh
exit 1
fi

RESPONSE=$(curl -sG "https://api.abuseipdb.com/api/v2/check" \
  -H "Key: $API_KEY" \
  -H "Accept: application/json" \
  --data-urlencode "ipAddress=$IP" \

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The installer directly writes a new fail2ban action and edits /etc/fail2ban/jail.local without any explicit confirmation, backup, or dry-run preview. In a security tool, silent configuration changes can unexpectedly alter protection behavior or break fail2ban setup, especially because the sed logic may modify an existing jail definition in-place.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The script enables automatic reporting of banned IPs to AbuseIPDB by installing a fail2ban action, but it does not present a runtime disclosure or consent step immediately before activation. Because this causes ongoing outbound reporting of security event data to a third party, users may enable persistent network data sharing without fully realizing it.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/report-single.sh (reported line 19)May include surrounding context.

sh
fi

# Report to AbuseIPDB
RESPONSE=$(curl -s -w "\n%{http_code}" \
  "https://api.abuseipdb.com/api/v2/report" \
  -H "Key: $API_KEY" \
  -H "Accept: application/json" \

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · README.md (reported line 107)May include surrounding context.

md
#!/bin/bash
# Remove fail2ban auto-reporting action
# Usage: sudo bash uninstall.sh

set -euo pipefail

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

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

md
#!/bin/bash
# Remove fail2ban auto-reporting action
# Usage: sudo bash uninstall.sh

set -euo pipefail

Static analysis

No suspicious patterns detected.