Back to skill

Security audit

Sentinal Redis

Security checks for vulnerabilities and agentic risk

Overview

This Redis diagnostic skill is purpose-aligned and read-only, but users should treat its Redis credentials and diagnostic output as sensitive.

Install only for Redis environments where the agent is allowed to run read-only diagnostics. Prefer a least-privilege Redis user, avoid sharing full REDIS_URL values or passwords in chat/logs/history, and review slow-log or BullMQ job output before pasting reports elsewhere because it may contain application data or secrets.

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 (2)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/redis-health.sh:6
Finding

Redis Credentials Exposed Through Process Command-Line Arguments

Content
View full analysis
``` ```bash redis-cli -h -p -a ``` ### Technical Analysis The Redis connection URL may contain a username and password, such as `redis://user:password@host:6379`. The script places this entire URL in the arguments passed to `redis-cli`. The documented alternative similarly passes a password through the `-a` command-line option. Command-line arguments may be recorded or exposed through operating-system process inspection, process-monitoring agents, debugging tools, audit logs, shell history when commands are entered manually, or diagnostic collection systems. The script's `SAFE_URL` masking protects only its displayed report; it does not mask the arguments of the running `redis-cli` process. The `CLI` variable is also a plain command string rather than a Bash array. Expanding `$CLI` causes word splitting and pathname expansion. A URL containing whitespace can therefore be split into additional `redis-cli` arguments. This makes argument handling unreliable and increases risk if the URL or script argument originates from an untrusted source. ### Attack Path 1. A Redis URL containing valid credentials is supplied as the first script argument or through the documented invocation pattern. 2. The script constructs a command such as `redis-cli -u redis://user:password@host:6379 ping`. 3. While the process is running, a local account, monitoring agent, audit facility, or process-inspection tool captures its command-line arguments. 4. The observer extracts the Redis usernam ...[truncated 1247 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/redis-health.sh:100
Finding

Raw Redis Slow-Log Output Can Disclose Sensitive Application Data

Content
View full analysis
/dev/null | tr -d '\r') echo " Total slow queries recorded: $slowlog_len" if [ "${slowlog_len:-0}" -gt 0 ] 2>/dev/null; then echo " Last 3 slow queries:" $CLI slowlog get 3 2>/dev/null | head -20 | sed 's/^/ /' fi ``` ### Technical Analysis The health-check script retrieves complete entries from the Redis slow log and writes the first 20 output lines directly into its report. Redis slow-log entries can contain command arguments in addition to timing and command-name information. Depending on application behavior and Redis version, those arguments may include: - Key names containing tenant IDs, email addresses, or other identifiers - Values supplied to write commands - Session identifiers and access tokens - Serialized application objects - BullMQ payload fragments - Lua script text or arguments - Authentication or connection-related information The output is not inspected or redacted before being printed. Health reports are commonly copied into chat sessions, support tickets, CI logs, observability systems, and incident reports. These destinations may have a much broader audience and a longer retention period than the Redis instance itself. The use of `head -20` limits the number of lines but does not provide confidentiality protection. A sensitive argument may occur in any returned line. ### Attack Path 1. An application issues a Redis command containing sensitive data. 2. The command exceeds the configured slow-log threshold and is retained by Redis. 3. An operator or Agent invokes `scripts/redis-health.sh`. 4. The script executes `SLOWLOG GET 3` and emits raw entry contents without redaction. 5. The resulting health report is stored in an Agent transcript, terminal log ...[truncated 1241 chars]
Remediation
View remediation
Vulnerability Patterns
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • 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
Findings (3)

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill claims to be strictly read-only, but it includes an EVAL-based key-counting example and latency-monitoring commands that impose server-side work. While these commands do not directly mutate Redis data, they violate the stated safety model and can create operational risk on production systems by consuming CPU and adding load, especially if run against large keyspaces or busy instances.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill warns not to expose the full REDIS_URL because it may contain credentials, yet many example commands interpolate the full URL directly. In a chat-driven or logged execution environment, showing or echoing those commands can leak passwords or tokens via terminal history, logs, transcripts, or agent output.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

This code connects to the target Redis instance and enumerates keyspace information, slow log contents, and BullMQ queue metadata, which can reveal operational or potentially sensitive system data. Although the script prints results, it does not disclose up front that it will inspect and display database internals beyond a basic connectivity check.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.