fix(deps): exclude agentic-flow <= 2.0.13 (GHSA-vcv2-r9jh-99m5) from v3 manifests

agentic-flow <= 2.0.13 has an OS command injection in its MCP server tools,
fixed in 2.0.14. Several v3 manifests still admitted the vulnerable versions:

- plugin-agent-federation peer `>=2.0.12-fix.8 <4.0.0` -> `^2.0.14 || ^3.0.0`
  (devDependency 2.0.12-fix.8 -> ^3.4.1 so the suite runs against 3.x);
  ws ^8.20.0 -> ^8.21.0 (GHSA-96hv-2xvq-fx4p). Version 1.0.7.
- browser dependency ^2.0.13 -> ^2.0.14 (lockfile resolves 2.1.5)
- embeddings peer ^2.0.0 -> ^2.0.14
- integration peer ^2.0.0-alpha -> ^2.0.14

pnpm-lock.yaml regenerated with pnpm 8 (--lockfile-only). The cli keeps its
exact `@claude-flow/plugin-agent-federation: 1.0.6` pin, so the lockfile now
resolves that one from the registry; the cli release lane bumps the pin.

Adds a manifest regression test asserting the federation ranges reject the
vulnerable versions and admit the patched ones.

Co-Authored-By: claude-flow <ruv@ruv.net>
This commit is contained in:
ruv committed 2026-11-08 18:03:11 -05:00
1 parent b56da1f084
commit 1e481c6a4b
7 files changed
+581 -2750

No files matched your search

+1 -1
View File
@@ -11,7 +11,7 @@
"license": "MIT",
"dependencies": {
"agent-browser": "^0.41.0",
"agentic-flow": "^2.0.13",
"agentic-flow": "^2.0.14",
"zod": "^4.6.7"
},
"devDependencies": {
+1 -1
View File
@@ -27,7 +27,7 @@
},
"dependencies": {
"agent-browser": "^0.41.0",
"agentic-flow": "^2.0.13",
"agentic-flow": "^2.0.14",
"zod": "^4.6.7"
},
"overrides": {
+1 -1
View File
@@ -49,7 +49,7 @@
},
"peerDependencies": {
"@claude-flow/shared": "^3.0.0-alpha.1",
"agentic-flow": "^2.0.0",
"agentic-flow": "^2.0.14",
"@huggingface/transformers": "^4.0.0"
},
"peerDependenciesMeta": {
+1 -1
View File
@@ -24,7 +24,7 @@
"swarm"
],
"peerDependencies": {
"agentic-flow": "^2.0.0-alpha"
"agentic-flow": "^2.0.14"
},
"devDependencies": {
"vitest": "^4.1.0"
@@ -0,0 +1,78 @@
/**
* Regression guard: the published peer/dependency ranges must not admit
* versions with known advisories.
*
* - agentic-flow <= 2.0.13: GHSA-vcv2-r9jh-99m5 (OS command injection in
* MCP server tools), first patched in 2.0.14. 1.0.6 declared
* `>=2.0.12-fix.8 <4.0.0`, which admitted 2.0.12-fix.8, 2.0.12 and 2.0.13.
* - ws >= 8.0.0 < 8.21.0: GHSA-96hv-2xvq-fx4p (memory exhaustion DoS).
*
* The ranges are restricted to `^X.Y.Z` alternatives joined by `||`, so the
* check below is exact without pulling semver into the plugin.
*/
import { readFileSync } from 'node:fs';
import { dirname, join } from 'node:path';
import { fileURLToPath } from 'node:url';
import { describe, it, expect } from 'vitest';
const here = dirname(fileURLToPath(import.meta.url));
const manifest = JSON.parse(
readFileSync(join(here, '..', '..', 'package.json'), 'utf8'),
) as {
dependencies: Record<string, string>;
peerDependencies: Record<string, string>;
};
type Version = { major: number; minor: number; patch: number; pre: boolean };
function parse(v: string): Version {
const m = /^(\d+)\.(\d+)\.(\d+)(-.+)?$/.exec(v);
if (!m) throw new Error(`not a version: ${v}`);
return { major: +m[1], minor: +m[2], patch: +m[3], pre: m[4] !== undefined };
}
function cmp(a: Version, b: Version): number {
return a.major - b.major || a.minor - b.minor || a.patch - b.patch;
}
/** Caret semantics for X >= 1: same major, >= floor, no prereleases. */
function satisfies(version: string, range: string): boolean {
const v = parse(version);
return range.split('||').some((part) => {
const m = /^\s*\^(\d+\.\d+\.\d+)\s*$/.exec(part);
if (!m) throw new Error(`unsupported range form: ${part.trim()}`);
const floor = parse(m[1]);
return !v.pre && v.major === floor.major && floor.major >= 1 && cmp(v, floor) >= 0;
});
}
describe('advisory-free dependency ranges', () => {
const agenticFlow = manifest.peerDependencies['agentic-flow'];
it.each(['2.0.12-fix.8', '2.0.12', '2.0.13', '2.0.11', '1.10.2'])(
'agentic-flow peer rejects vulnerable %s (GHSA-vcv2-r9jh-99m5)',
(v) => {
expect(satisfies(v, agenticFlow)).toBe(false);
},
);
it.each(['2.0.14', '2.1.5', '3.0.0', '3.4.1'])(
'agentic-flow peer admits patched %s',
(v) => {
expect(satisfies(v, agenticFlow)).toBe(true);
},
);
it('agentic-flow peer does not reach the next major', () => {
expect(satisfies('4.0.0', agenticFlow)).toBe(false);
});
it.each(['8.20.0', '8.20.1'])('ws rejects vulnerable %s (GHSA-96hv-2xvq-fx4p)', (v) => {
expect(satisfies(v, manifest.dependencies.ws)).toBe(false);
});
it('ws admits 8.21.0', () => {
expect(satisfies('8.21.0', manifest.dependencies.ws)).toBe(true);
});
});
@@ -1,6 +1,6 @@
{
"name": "@claude-flow/plugin-agent-federation",
"version": "1.0.6",
"version": "1.0.7",
"description": "Cross-installation agent federation with zero-trust security, PII-gated data flow, and compliance-grade audit trails.",
"homepage": "https://github.com/ruvnet/ruflo",
"type": "module",
@@ -24,10 +24,10 @@
},
"dependencies": {
"@noble/ed25519": "^2.0.0",
"ws": "^8.20.0"
"ws": "^8.21.0"
},
"peerDependencies": {
"agentic-flow": ">=2.0.12-fix.8 <4.0.0",
"agentic-flow": "^2.0.14 || ^3.0.0",
"midstreamer": "^0.3.2"
},
"peerDependenciesMeta": {
@@ -42,7 +42,7 @@
"@claude-flow/shared": "^3.0.0",
"@claude-flow/security": "^3.0.0",
"@types/ws": "^8.18.1",
"agentic-flow": "2.0.12-fix.8",
"agentic-flow": "^3.4.1",
"typescript": "^5.4.0",
"vitest": "^4.1.0"
},
+495 -2742
View File
File diff suppressed because it is too large. Load diff