Back to plugin

Security audit

OpenViking

Security checks for vulnerabilities and agentic risk

Overview

ClawScan marked this plugin suspicious because scanners report risks involving retrieved content influencing instructions, broad local-file uploads, and conversation data being sent despite configured capture limits.

Review the plugin’s memory access, automatic capture, and skill-import behavior before installing. Consider whether you are comfortable with retrieved content influencing later turns, broader-than-configured conversation and tool data being sent to the memory service, and local files being uploaded through skill imports. The scan confirms code-level weaknesses but does not demonstrate model takeover or attacker access to uploaded data; its evidence supports a suspicious review verdict, not a claim of malicious intent.

Vulnerability Patterns
  • 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
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Findings (3)

MCP06

Error
Location
plugin/dist/services/context-lifecycle-service.js:277
Finding

Remote Memory Content Is Promoted into System Context ## Remediation Suggestions 1. Keep profiles and retrieved memories in explicitly untrusted data or tool-result messages rather than system instructions. 2. Establish a higher-priority policy stating that retrieved content cannot change permissions, authorize actions, request secret disclosure, or override current user instructions. 3. Preserve writer identity and provenance, and isolate shared contributions from private profiles and privileged operational rules. 4. Encode structural delimiters as defense in depth. Do not treat escaping as sufficient protection against semantic prompt injection. 5. Require independent, host-enforced authorization for sensitive tool actions. 6. Add regression tests containing instruction-bearing profiles, forged closing tags, and poisoned shared memories. Verify that they cannot authorize tool calls or change the instruction hierarchy.

Content
View full analysis

Vulnerability Details

File Location:

  • plugin/dist/services/context-lifecycle-service.js:217–237 — remote profile retrieval and wrapping.
  • plugin/dist/services/context-lifecycle-service.js:277–303 — profile and recall insertion into system context.
  • plugin/dist/auto-recall.js:123–132 — recall-content wrapper.

Vulnerability Type: Indirect prompt injection through persistent memory
Risk Level: High

Vulnerable Code

Remote profile content is inserted without escaping or an instruction-versus-data boundary:

js
const text = read.status === "fulfilled" && typeof read.value === "string" ? read.value.trim() : "";
if (!text)
    return "";
const capped = text.length > PROFILE_MAX_CHARS
    ? `${text.slice(0, PROFILE_MAX_CHARS).trimEnd()}\n... [profile truncated]`
    : text;
return `<user-profile uri="${uris[i]}">\n${capped}\n</user-profile>`;

The assembly path promotes profile and recall blocks into system context:

js
const baseTokens = estimateTextTokens(assembled.systemPromptAddition ?? "");
for (const blocks of [[profileBlock, recallBlock], [profileBlock], [recallBlock]]) {
    if (!blocks.some(Boolean))
        continue;
    const systemPromptAddition = [assembled.systemPromptAddition, ...blocks].filter(Boolean).join("\n\n");
    const estimatedTokens = assembled.estimatedTokens + estimateTextTokens(systemPromptAddition) - baseTokens;
    if (estimatedTokens <= params.tokenBudget)
        return { ...assembled, systemPromptAddition, estimatedTokens };
}

The recall wrapper likewise includes supplied content directly:

js
export function buildRecallContextBlock(memoryLines) {
    return [
        "<relevant-memories>",
        AUTO_RECALL_SOURCE_MARKER,
        "The following OpenViking memories may be relevant:",
        ...memoryLines,
        "</relevant-memories>",
    ].join("\n");
}

Technical Analysis

Profiles and recalled memories originate from the configured OpenViking service. Their contents may refl ...[truncated 2097 chars]

other

Warning
Location
plugin/dist/adapters/resource-packager.js:77
Finding

Skill Import Allows Arbitrary Gateway-Readable File Uploads ## Remediation Suggestions 1. Disable model-driven local-path skill imports by default, separately from resource imports. 2. Resolve canonical paths and enforce containment within administrator-approved import directories. 3. Reject symbolic-link escapes and validate the actual opened files to reduce path-resolution race risks. 4. Require a valid skill manifest before uploading any bytes. Permit only necessary skill assets rather than arbitrary directory contents. 5. Exclude credentials, gateway configuration, transcripts, hidden configuration directories, and unrelated files. 6. Enforce file-count, individual-file-size, and aggregate-upload limits. 7. Require host-enforced approval displaying the canonical source path, file inventory, destination service, and total upload size. 8. Test non-skill files, hidden files, directory traversal attempts, symlinks, and oversized directories.

Content
View full analysis

Vulnerability Details

File Location:

  • plugin/dist/plugin/openviking-import-tools.js:52–81 — model-controlled skill import.
  • plugin/dist/client.js:350–376 — local source preparation and upload.
  • plugin/dist/adapters/resource-packager.js:77–107 — unrestricted local-path handling and file reading.

Vulnerability Type: Excessive tool authority and sensitive-file disclosure
Risk Level: Medium

Vulnerable Code

The tool forwards a model-supplied local path:

js
const result = await client.addSkill({
    path: typeof params.source === "string" ? params.source : undefined,
    data: params.data,
    wait: typeof params.wait === "boolean" ? params.wait : undefined,
}, session.actorPeerId);

The client uploads the source before skill processing:

js
if (hasPath) {
    const skillPath = input.path.trim();
    packagedSource = await this.resourcePackager.prepareLocalUploadSource(skillPath);
    if (packagedSource.kind !== "upload") {
        throw new Error(`Path is not a file or directory: ${skillPath}`);
    }
    body.temp_file_id = await this.uploadTempFile(packagedSource.uploadPath, actorPeerId);
}
else {
    body.data = input.data;
}
return this.request("/api/v1/skills", { method: "POST", body: JSON.stringify(body) }, undefined, actorPeerId);

Local preparation accepts any regular file or directory:

js
async function prepareLocalUploadSource(path, includeSourceName = false) {
    const localStats = await stat(path);
    if (localStats.isDirectory()) {
        const uploadPath = await zipDirectoryForUpload(path);
        return {
            kind: "upload",
            uploadPath,
            cleanupPath: uploadPath,
            ...(includeSourceName ? { sourceName: basename(path) } : {}),
        };
    }
    if (!localStats.isFile()) {
        throw new Error(`Path is not a file or directory: ${path}`);
    }
    return { kind: "upload", uploadPath: path };
}

The prepared file is read into an upload body:

js
async
...[truncated 2323 chars]

MCP01

Warning
Location
plugin/dist/services/context-lifecycle-service.js:643
Finding

Automatic Capture Does Not Enforce Configured Selection and Length Restrictions ## Remediation Suggestions 1. Apply `captureMode` and `captureMaxLength` before any message data reaches the network transport. 2. Route eligible user text through a tested capture-decision function and define separate policies for assistant text and tool data. 3. Make tool-input and tool-output capture independent, conservative opt-in settings. 4. Redact credentials and other secrets before transmission, while documenting that pattern-based redaction is not comprehensive. 5. Enforce per-message and per-turn transmission limits locally. 6. Add transport-level regression tests proving that nonmatching text, over-limit text, and excluded tool data are never uploaded. 7. Correct documentation and configuration descriptions if broad transcript replication is intentional; do not retain controls that appear to constrain capture but are ineffective. 8. Review previously captured data and remove unintended records according to the deployment’s retention and incident-response policies.

Content
View full analysis

Vulnerability Details

File Location:

  • plugin/dist/config.js:447–448 — accepted capture restrictions.
  • plugin/dist/services/context-lifecycle-service.js:643–703 — extraction and remote transmission.
  • plugin/dist/text-utils.js:142 onward — capture-decision helper not called by the active capture path.

Vulnerability Type: Data-minimization control failure and unintended sensitive-data transmission
Risk Level: Medium

Vulnerable Code

Configuration accepts capture selection and length controls:

js
captureMode: captureMode ?? DEFAULT_CAPTURE_MODE,
captureMaxLength: Math.max(200, Math.min(200_000, Math.floor(toNumber(cfg.captureMaxLength, DEFAULT_CAPTURE_MAX_LENGTH)))),

The active lifecycle path extracts messages without applying either control:

js
const { messages: extractedMessagesRaw, newCount } = extractNewTurnMessages(messages, start);
const extractedMessages = coalesceConsecutiveToolMessages(extractedMessagesRaw);

The extracted data is converted and transmitted:

js
for (const msg of extractedMessages) {
    const ovParts = msg.parts.map((part) => {
        if (part.type === "text") {
            const cleaned = part.text
                .replace(/<relevant-memories>[\s\S]*?<\/relevant-memories>/gi, " ")
                .replace(/\s+/g, " ")
                .trim();
            return { type: "text", text: cleaned };
        }
        return {
            type: "tool",
            tool_id: part.toolCallId,
            tool_name: part.toolName,
            tool_input: part.toolInput,
            tool_output: part.toolOutput,
            tool_status: part.toolStatus,
        };
    });
    if (ovParts.length > 0) {
        await client.addSessionMessage(ovSessionId, msg.role, ovParts, undefined, createdAt, resolveOpenVikingMessagePeerId({
            peerRole: cfg.peer_role ?? "none",
            role: msg.role,
            senderPeerId: senderRoleId,
            assistantPeerId: agentId,
        }));
    }
}

...[truncated 2018 chars]

SkillSpector findings are pending for this release.

Endor dependency reachability

Checked Nov 26, 2026 · 11:12 AM UTC

No reachable vulnerabilities reported

Endor dependency scan completed.