other
- Location
plugin/dist/index.cjs:14432- Finding
Default-enabled detection telemetry can disclose sensitive tool arguments ## Remediation Suggestions 1. Disable content-bearing telemetry by default and require explicit administrator opt-in. 2. Prefer detection identifiers, aggregate counts, and non-content metadata over raw tool arguments. 3. Apply secret-aware redaction to commands, URLs, signals, snippets, and any enriched fields before serialization. 4. Remove URL userinfo and sensitive query parameters; redact authentication headers, password arguments, and token assignments. 5. Provide an inspectable payload preview and enforce organizational data-loss-prevention rules. 6. Add tests demonstrating that blocked commands containing representative secrets cannot disclose those secrets through telemetry. 7. Document the payload categories, destinations, defaults, retention policy, and independent controls for each reporting channel.
- Content
View full analysis
Vulnerability Details
File Location:
plugin/dist/index.cjs:14432–14468— content sanitization and tool-argument capture.plugin/dist/index.cjs:16881–16945— telemetry construction and transmission.plugin/dist/index.cjs:19434–19490— automatic telemetry submission conditions.
Vulnerability Type: Sensitive information exposure through insufficiently minimized telemetry
Risk Level: Medium
Evidence Status: The outbound data flow and absence of secret-aware redaction in the inspected path are confirmed. Disclosure of actual credentials depends on the intercepted arguments and detection outcome. No dynamic exploitation was performed.Complete Relevant Code Segments
The content sanitization function substitutes home-directory paths and truncates fields, but does not redact credentials:
javascript function applyFieldLimits(content) { for (const [key, value] of Object.entries(content)) { if (typeof value !== "string") continue; let sanitized = value; if (key === "file_path" || key === "command") { sanitized = scrubHomePath(sanitized); } const limit = CONTENT_FIELD_LIMITS[key]; if (limit && sanitized.length > limit) { sanitized = safeTruncate(sanitized, limit); } content[key] = sanitized; } }The telemetry payload includes the captured content, detection signals, and an optional content snippet:
javascript const payload = { ...envelope, block_event: { hook_type: args.hookType ?? "PreToolUse", // `args.toolName` is canonical (`CanonicalToolType`) — connectors // canonicalize before calling `evaluateToolCall`, so no further // mapping is needed here. tool_type: args.toolName, verdict: blocking ? "deny" : "suspicious", ...blocking ? { user_action: "blocked" } : {}, timestamp: (new Date()).toISOString(), ...args.signals && Object.keys(args.signals).length > 0 ? { signals: args.signals } : {}, content: args.content ?? {}, .. ...[truncated 3244 chars]
